Giter Club home page Giter Club logo

latexslides's Introduction

LaTeX Slides

Here I store my LaTeX template for beamer slides. It is loosely based on the corporate design of the University of Science and Technology of China (USTC) [**科学技术大学].

1. Usage

  1. download the template
  2. edit slides.tex
  3. in order to produce a pdf of your slides, under Linux run
  4. ./scripts/latex.sh slides evince if you are using eps figures
  5. ./scripts/pdflatex.sh slides evince if you are using pdf figures
  6. ./scripts/xelatex.sh slides evince if you have Chinese text

2. Available Commands

2.1. Structural Commands

The following structural commands should be used in exactly this order (while \appendices and \printSectionOutlines are optional).

  1. \startPresentation{optional} start the presentation and put the optional content on the outline slides, if any. After this, your slides should come.
  2. \printSectionOutlines optional: a section outline should be printed at the beginning of each section
  3. \endPresentation ends the presentation by putting a goodbye screen and the references
  4. \appendices starts appendix sections. Maybe you want to have some more slides in store if someone asks questions. Can be left away if there are no appendices.

2.2. Put Objects at Specific Locations

Sometimes we want to locate stuff at specific positions on a slide. For this purpose, the following commands are used, which all operate on a x-y coordinate system where x=0, y=0 is the top-left corner of the slide and x=1, y=1 is the bottom-right corner.

  1. \locate{when}{what}{x}{y} position the content (what) at the specified x-y coordinates. If when is not empty, wrap everything in an \only<when>{...}, i.e., only display something at the specified sub-slide id range. You may put an \includegraphics as contents.
  2. \locateWithCaption{when}{what}{caption}{x}{y}{width} locate the content of what at the specified x-y coordinates. Put a figure-like caption below it. Reserve the given width (between 0 and 1, relative to slide width) for everything. The width is reserved to know how to break the caption if it is longer than the contents (what).
  3. \locateGraphic{when}{arg}{path}{x}{y} locate an \includegraphics[arg]{path} via locate{when}{\includegraphics[arg]{path}}{x}{y}. Arguments are passed forward as indicated.
  4. \locateFramedGraphic{when}{arg}{path}{x}{y} same as \locateGraphic, but puts a frame around the graphic.
  5. \locateFramedBox{when}{width}{what}{x}{y}{background}{foreground} locate a framed box of the given width (relative to the slide width) at coordinates x-y at sub-slides when (or always, if when is empty). The contents of the box are what. The box will use background as fill color (or white, if background is empty). The frame will be in color foreground (or blueish, if foreground is empty).
  6. \begin{lobateBox}{when}{x}{y}...\end{locateBox} locate the contents of the environment at the specified x-y coordinates. If when is not empty, only display at the specified sub-slides.
  7. \begin{scaledBox}{width}{height} ... \end{scaledBox} an environment which scales its contents to the given width and height. If width==!, then we scale proportionally according to height. If height=!, then we scale proportionally to width.

2.3. Listings

  1. You can use all the normal commands from package listings.
  2. \begin{listingBlock}[width]{caption}...\end{listingBlock} place a block with the specified caption which is supposed to contain a listing. The width can be specified relative to the paper width, if omitted, we use 0.95\paperwidth as block width.

2.4. Citations

  1. \citep{ref} cite reference ref by number
  2. \scitep{ref} cite reference ref by number, pre-pend non-breakable space. For use in text, like bla bla blablabla\scitep{ref}
  3. \citet{ref} cite reference ref by author names followed by number
  4. \Citet{ref} cite reference ref by author names followed by number at beginning of sections (make first character uppercase)
  5. \citete{authorRef}{refs} cite references refs by number, but pre-pend the author names of reference authorRef. This is useful if a group of authors has produced several works, but the author order changes in these works.
  6. \Citete{authorRef}{refs} like \citete{authorRef}{refs}, but capitalize first character.

2.5. Chinese

Include Chinese text with the command \zh{chinese text}. You then need to use the XeLaTeX script for compiling.

latexslides's People

Contributors

thomasweise avatar

Watchers

李震 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.