diff options
author | Norbert Preining <norbert@preining.info> | 2019-09-02 13:46:59 +0900 |
---|---|---|
committer | Norbert Preining <norbert@preining.info> | 2019-09-02 13:46:59 +0900 |
commit | e0c6872cf40896c7be36b11dcc744620f10adf1d (patch) | |
tree | 60335e10d2f4354b0674ec22d7b53f0f8abee672 /macros/plain/contrib/present |
Initial commit
Diffstat (limited to 'macros/plain/contrib/present')
-rw-r--r-- | macros/plain/contrib/present/HowToTalkTeX.lp | 1 | ||||
-rw-r--r-- | macros/plain/contrib/present/HowToTalkTeX.pdf | bin | 0 -> 1347999 bytes | |||
-rw-r--r-- | macros/plain/contrib/present/HowToTalkTeX.tex | 482 | ||||
-rw-r--r-- | macros/plain/contrib/present/Pfeil1.pdf | bin | 0 -> 686 bytes | |||
-rw-r--r-- | macros/plain/contrib/present/Pfeil2.pdf | bin | 0 -> 686 bytes | |||
-rw-r--r-- | macros/plain/contrib/present/Pfeil3.pdf | bin | 0 -> 738 bytes | |||
-rw-r--r-- | macros/plain/contrib/present/Pfeil4.pdf | bin | 0 -> 736 bytes | |||
-rw-r--r-- | macros/plain/contrib/present/README | 69 | ||||
-rw-r--r-- | macros/plain/contrib/present/Sagnac.pdf | bin | 0 -> 5180 bytes | |||
-rw-r--r-- | macros/plain/contrib/present/Stern.png | bin | 0 -> 81822 bytes | |||
-rw-r--r-- | macros/plain/contrib/present/background.png | bin | 0 -> 201894 bytes | |||
-rw-r--r-- | macros/plain/contrib/present/present-transitions.tex | 53 | ||||
-rw-r--r-- | macros/plain/contrib/present/present.tex | 297 |
13 files changed, 902 insertions, 0 deletions
diff --git a/macros/plain/contrib/present/HowToTalkTeX.lp b/macros/plain/contrib/present/HowToTalkTeX.lp new file mode 100644 index 0000000000..209e3ef4b6 --- /dev/null +++ b/macros/plain/contrib/present/HowToTalkTeX.lp @@ -0,0 +1 @@ +20 diff --git a/macros/plain/contrib/present/HowToTalkTeX.pdf b/macros/plain/contrib/present/HowToTalkTeX.pdf Binary files differnew file mode 100644 index 0000000000..9378058099 --- /dev/null +++ b/macros/plain/contrib/present/HowToTalkTeX.pdf diff --git a/macros/plain/contrib/present/HowToTalkTeX.tex b/macros/plain/contrib/present/HowToTalkTeX.tex new file mode 100644 index 0000000000..06619702df --- /dev/null +++ b/macros/plain/contrib/present/HowToTalkTeX.tex @@ -0,0 +1,482 @@ +% +% +% HOW TO DO A TALK IN TeX +% +% Author: Matthias Meister +% Version 2.2.1, February 2019 +% +% This file is part of a work distributed under the LaTeX Project Public License +% + +\input present % Load presentation specific macros +\input present-transitions % Load macros for transitions. + +\setcolour\textcolour +\setbgcolour\backgroundcolour +\overfullrule=0pt +%\WideAspect +\vskip20mm plus 5mm minus 5mm +\line{\pagelink{NextPage}{\hfil\titlefont How To Do A Talk In \TeX\hfil}} +\vskip 5mm plus 2mm minus 1mm +\line{\hfil\font\subtitlefont=cmssbx10 at 15pt\subtitlefont One Of Many Solutions\hfil} +\vskip 5mm plus 2mm minus 1mm +\line{\hfil\linkbarfont Version 2.2.1\hfil} +\vskip 20mm plus 2mm minus 1mm +\line{\hfil\normalfont Matthias Meister\hfil}\target{title} +\vskip 5mm plus 2mm minus 1mm +\line{\hfil\normalfont February 2019\hfil} +\NewSlide +\pageno=1% Don't want to count the titlepage +\normalfont +\def\LinkBar{} % LinkBar is left part of the footline, and currently is empty +%% +%% +%% +\SlideTitle{\hfill Motivation}% +\SlideFoot % "Activates" the footline, titlepage had an empty footline +\vglue7mm +\leftskip5mm +\item{$\bullet$}Make it possible to prepare presentations in \TeX +\vskip3mm +\item{$\bullet$}Without having to learn lots of extra syntax +\vskip3mm +\item{$\bullet$}By using simple macros that can easily be adapted to one's needs, maybe for each presentation prepared +\vskip3mm +\item{$\bullet$}Without restricting the possibilities that \TeX\ offers +\NewSlide +\SlideTitle{\hfil Requirements} +\font\cdfo=cmtt12 +\def\codecolour{1.0 0.0 1.0} +\def\cf{\setcolour\codecolour\cdfo} +\leftskip0pt +You need the program {\cf pdftex}, which probably is included in your \TeX-distribution. +\vskip3mm +You need the file {\cf present.tex}, which is to be {\cf\char'134input} at the beginning of your source code. +The file can for example be obtained from \weblink{http://www.ctan.org}{ctan.org}. +\vskip3mm +You furthermore need a pdf-viewer with fullscreen display capabilities, e.g. {\cf xpdf}. +\vskip5pt +\att{Warning: Some pdf-viewers do not handle links in a document properly.} +%% +%% +%% +\NewSlide +\SlideTitle{\hfil Basic Examples} +You can type text as usual, inline equations $a^2+b^2=c^2$, displayed equations +$$ +\exp(z)=\sum_{n=0}^\infty {z^n\over n!}=\lim_{n\to\infty}\Big(1+{z\over n}\Big)^n +$$ +and tables +\vskip0.5\baselineskip +\moveright2cm\vbox{\offinterlineskip +\halign{\vrule width 0pt height12pt depth3pt\kern5pt # &\vrule\hfil\kern5pt #\kern5pt\hfil +&\vrule\hfil\kern5pt #\kern5pt\hfil\cr +& $x$ & $\Delta x$\cr +\noalign{\hrule} +A & 1.03 & 0.07 \cr +\noalign{\hrule} +B & 2.05 & 0.06 \cr +}}\vskip5pt +So you probably can use \TeX\ in the ordinary fashion; just run {\cf pdftex} on your source instead of {\cf tex}. +\NewSlide +You can include images easily:\vskip20pt plus 3pt minus 10pt +\hbox{\image[width3cm]{Stern.png}\hskip5mm plus 2mm minus 2mm A pixel image (png)} +\vskip10pt\hrule +\hbox{A vector image (pdf)\hskip5mm plus 2mm minus 2mm\image[width3cm]{Sagnac.pdf}} +\NewSlide +%%% +%%% +%%% +\SlideTitle{\hfil Ordinary stuff} +You type text, equations, and so on as usual in \TeX. Keep in mind, though, that the effective paper size is +rather small (12cm wide, 9cm high in standard configuration). +\vskip10pt plus 5pt minus 10pt +The paper size is small, because you rely on the fullscreen mode of your pdf-viewer to blow the slide up to full +screen size, thus also automatically enlarging the fonts. +\vskip10pt plus 5pt minus 10pt +Your macros should work (unless there is a collision of names), because what you are doing is creating an ordinary +pdf-file with {\cf pdftex}, for viewing it with a pdf-viewer. +\vskip10pt plus 5pt minus 10pt +You start a new slide with {\cf\char'134 NewSlide}. If you use {\cf\char'134 NewFrame}, it has almost the same effect, only +the slide number doesn't get increased. +\NewSlide +%%% +%%% +%%% +\SlideTitle{\hfil Fonts} +{\cf present.tex} defines the following fonts:\vskip5pt +{\openup2pt +\halign{#\hfil\kern5pt&#\hfil\kern5pt&#\hfil\cr +Font Command & Purpose & Default Value\cr +{\cf\char'134 titlefont} & presentation title & {\cf cmssbx10 at 20pt}\cr +{\cf\char'134 slidetitlefont} & title of a slide & {\cf cmssbx10}\cr +{\cf\char'134 normalfont} & ordinary text & {\cf cmss12}\cr +{\cf\char'134 linkbarfont} & text in {\cf\char'134 LinkBar} & {\cf cmss8}\cr +{\cf\char'134 it} & italic text & {\cf cmti12}\cr +{\cf\char'134 rm} & roman text in math & {\cf cmr}\cr +}} +\vskip10pt +Of course you can define further font commands or redefine the existing ones. +The default fonts are used in this presentation, so you see what they look like. +\NewSlide +%%% +%%% +%%% +\SlideTitle{\hfil Colours} +Colours are defined as control sequences, e.g. +\vskip5pt +{\cf\char'134def\char'134mycolour\char'173}{\it R G B\/}{\cf\char'175} +\vskip5pt +where {\it R G B} are the red, green, and blue values of the colour defined, with +$0\leq R, G, B\leq 1$. +\vskip5pt +Colours are used in these ways: +\vskip5pt +{\cf\char'134setcolour\char'134mycolour} + +to set the colour of following text, grouping is respected +\vskip5pt +{\cf\char'134coloured\char'134mycolour\char'173}{\it Stuff\/}{\cf\char'175} + +to set {\it Stuff} in colour {\cf\char'134mycolour} +\vskip5pt +{\cf\char'134setbgcolour\char'134mycolour} + +to set the colour of the background +\NewSlide +%%% +%%% +%%% +The following colours are +defined in {\cf present.tex}: +\vskip5pt +{\cf \char'134backgroundcolour}, for the slide background +\vskip5pt +{\cf \char'134textcolour}, for the text, and +\vskip5pt +{\cf \char'134attentioncolour}, an \att{attention} colour. + +You draw attention to \att{Stuff} by saying +{\cf\char'134att\char'173}{\it Stuff\/}{\cf\char'175}. +\vskip5pt +If a predefined colour is redefined, {\cf\char'134setcolour} +must also be used for the change to take effect for text. +\NewSlide +%%% +%%% +%%% +\SlideTitle{\hfil Paper Size} +The paper size is determined by the dimensions +\vskip3pt {\cf\char'134 pdfpagewidth} and +{\cf\char'134 pdfpageheight}. +\vskip10pt +If you say {\cf\char'134 StandardAspect}, you get a page 120mm wide and 90mm high. +\vskip10pt +If you say {\cf\char'134 WideAspect}, you get a page 144mm wide and 90mm high. +\NewSlide +%%% +%%% +%%% +\SlideTitle{\vbox to 0pt{\kern-5mm\image[width10mm]{Stern.png}\vss}\hfil Images} +Images can be included with +\vskip5pt +{\cf\char'134 image[}{\it dimensions}{\cf]\char'173}{\it filename}{\cf\char'175} +\vskip5pt +where {\it dimensions} are {\cf height}, {\cf depth}, and {\cf width}, familiar from \TeX. +\vskip5pt +\hbox{% +\image[width3mm]{Stern.png} +\image[width6mm]{Stern.png} +\image[width9mm]{Stern.png} +\image[height9mm]{Stern.png} +\image[height3mm depth6mm]{Stern.png} +\image[height9mm width4mm]{Stern.png} +\image[width5mm]{Sagnac.pdf}\image[width10mm height4mm]{Sagnac.pdf} +\image[width15mm depth 5mm]{Sagnac.pdf} +} +\vskip5pt +If only {\cf width} is given, the image is scaled with the aspect ratio preserved.\target{Images} + +Image files need to be in a format that can be handled by the pdf-viewer and by {\cf pdftex}. +E.g. pdf, png, jpg should work. +\NewSlide +%%% +%%% +%%% +\SlideTitle{\hfil Slide Structure} +Each slide has a headline, a body, and a footline. +\vskip5pt +The headline holds the slide title, which is set by +\vskip5pt +{\cf\char'134 SlideTitle\char'173}{\it TITLE\/}{\cf\char'175} +\vskip5pt +The footline is defined by +{\cf\char'134 SlideFoot}, of which several versions are contained in {\cf present.tex}. Uncomment the one you want, +or define further ones. +\vskip5pt +The version used here shows the number of the current slide and the total number of slides in the centre (the latter is +provided by the {\cf\char'134 LP} macro), and the {\cf\char'134 PageBar} on the right. +\vskip5pt +The {\cf\char'134 PageBar}-symbols \PageBar move to the previous or following page, or move back and forth in the +page history. +\NewSlide +%%% +%%% +%%% +The page history is relevant if cross-references are used in the presentation. These will be discussed later. +\vskip5pt +\phantom{With cross-references or links, also the {\cf\char'134 LinkBar} can be useful. In the {\cf\char'134 SlideFoot}-version +used, it is shown on the left side of the footline, but currently is defined to be empty.} +\vskip5pt +\phantom{The {\cf\char'134 LinkBar} is intended to hold links to various places in the presentation you might want to jump to.} +\vskip5pt +\phantom{This slide has been shown incrementally by a copy-paste procedure when writing the source (have a look at it). +It is straightforward, very flexible, one might occasionally lose track, and it may be tedious to introduce +changes later. A further possibility is shown on the next slides.} +\NewFrame +The page history is relevant if cross-references are used in the presentation. These will be discussed later. +\vskip5pt +With cross-references or links, also the {\cf\char'134 LinkBar} can be useful. In the {\cf\char'134 SlideFoot}-version +used, it is shown on the left side of the footline, but currently is defined to be empty. +\vskip5pt +\phantom{The {\cf\char'134 LinkBar} is intended to hold links to various places in the presentation you might want to jump to.} +\vskip5pt +\phantom{This slide has been shown incrementally by a copy-paste procedure when writing the source (have a look at it). +It is straightforward, very flexible, one might occasionally lose track, and it may be tedious to introduce +changes later. A further possibility is shown on the next slides.} +\NewFrame +The page history is relevant if cross-references are used in the presentation. These will be discussed later. +\vskip5pt +With cross-references or links, also the {\cf\char'134 LinkBar} can be useful. In the {\cf\char'134 SlideFoot}-version +used, it is shown on the left side of the footline, but currently is defined to be empty. +\vskip5pt +The {\cf\char'134 LinkBar} is intended to hold links to various places in the presentation you might want to jump to. +\vskip5pt +\phantom{This slide has been shown incrementally by a copy-paste procedure when writing the source (have a look at it). +It is straightforward, very flexible, one might occasionally lose track, and it may be tedious to introduce +changes later. A further possibility is shown on the next slides.} +\NewFrame +The page history is relevant if cross-references are used in the presentation. These will be discussed later. +\vskip5pt +With cross-references or links, also the {\cf\char'134 LinkBar} can be useful. In the {\cf\char'134 SlideFoot}-version +used, it is shown on the left side of the footline, but currently is defined to be empty. +\vskip5pt +The {\cf\char'134 LinkBar} is intended to hold links to various places in the presentation you might want to jump to. +\vskip5pt +This slide has been shown incrementally by a copy-paste procedure when writing the source (have a look at it). +It is straightforward, very flexible, one might occasionally lose track, and it may be tedious to introduce +changes later. A further possibility is shown on the next slides. +\NewSlide +\def\hl{\setcolour\attentioncolour} +%%% +%%% +%%% +\Frames5{% +\SlideTitle{\hfill {\onframe1\hl Slides} {\onframe2\hl Step} {\onframe3\hl by} {\onframe4\hl Step}} +A slide can be shown incrementally using +\vskip1pt +\beforeframe2\hide{\afterframe1\cf +\char'134 NewSlide\par +\char'134 Frames\char'173}{\it num}{\afterframe1\cf\char'175\char'173}% +{\it CONTENT} +{\afterframe1\cf\char'175\char'134 endFrames\par +\char'134NewSlide} +\vskip1pt +\beforeframe3\hide By the above, the {\it CONTENT} of the slide, enclosed between +{\afterframe2\cf\char'134begingroup} \dots{\afterframe2\cf\char'134endgroup}, +is repeated {\it num} times, with a +{\afterframe2\cf\char'134NewFrame} between subsequent repetitions. +\vskip1pt +\beforeframe4\hide Due to this grouping, definitions are local to the body of a frame. +{\afterframe3\cf\char'134global} is used in the replacement texts of {\afterframe3\cf\char'134SlideTitle} +and {\afterframe3\cf\char'134SlideFoot} to allow frame-dependent changes here, too. +\vskip1pt +\beforeframe5\hide +{\onframe5\cf\char'134hide}, defined as {\onframe5\cf\char'134setcolour\char'134backgroundcolour}, can be used +to hide parts of the slide on a monochromatic background.} +\endFrames +%%% +%%% +%%% +\NewSlide +\Frames5{% +Incremental showing or modification of content is achieved by +\vskip1pt +\beforeframe2\hide{\afterframe1\cf\char'134 onframe\char'173}{\it fn}{\afterframe1\cf\char'175\char'173}{\it arg}% +{\afterframe1\cf\char'175}\par +which evaluates to {\it arg} on frame number {\it fn} and to {\afterframe1\cf\char'134relax} otherwise (frames are counted from 1). +\vskip1pt +\beforeframe3\hide{\afterframe2\cf\char'134 afterframe\char'173}{\it fn}{\afterframe2\cf\char'175\char'173}% +{\it arg}{\afterframe2\cf\char'175}\par +which evaluates to {\it arg} after frame {\it fn} and to {\afterframe2\cf\char'134relax} before and on frame {\it fn}. +\vskip1pt +\beforeframe4\hide{\afterframe3\cf\char'134 beforeframe\char'173}{\it fn}{\afterframe3\cf\char'175\char'173}{\it arg}% +{\afterframe3\cf\char'175}\par +which evaluates to {\it arg} before frame {\it fn} and to {\afterframe3\cf\char'134relax} on and after frame {\it fn}. +\vskip1pt +\beforeframe5\hide If {\it arg} is a single token, no braces are necessary. The same applies if {\it fn} or {\it num} +is a single digit number.}% +\endFrames +\NewSlide +%%% +%%% +%%% +\SlideTitle{\hfil Links} +{\cf\char'134 target\char'173}{\it NAME\/}{\cf\char'175} creates a target named {\it NAME} for a link at the position in +the presentation where it is used. +\vskip5pt +{\cf\char'134 link\char'173}{\it NAME\/}{\cf\char'175\char'173}{\it Stuff\/}{\cf\char'175} +turns {\it Stuff} into a link to the target named {\it NAME}. +\vskip5pt +{\cf\char'134 weblink\char'173}{\it URI\/}{\cf\char'175\char'173}{\it Stuff\/}{\cf\char'175} +makes {\it Stuff} a link to the specified {\it URI}. +\vskip5pt +{\cf\char'134 filelink\char'173}{\it file}{\cf\char'175\char'173}{\it filedest}{\cf\char'175\char'173}{\it Stuff\/}{\cf\char'175} +makes {\it Stuff} a link to destination {\it filedest} in {\it file}. + +{\it filedest} for example can be {\cf [}{\it page} {\cf/Fit]}, with {\it page} the page number (starting at 0). +\vskip10pt +A further possibility can be found \link{Further}{here (click)}. +\def\LinkBar{% +\link{Images}{\linkbarfont Images} +\link{Further}{\linkbarfont Area} +\link{title}{\linkbarfont Title} +} +\NewSlide +%%% +%%% +%%% +{\cf\char'134 linkarea\char'173}{\it dest}{\cf\char'175\char'173}{\it rect}{\cf\char'175\char'173}{\it border}{\cf +\char'175\char'173}{\it colour}{\cf\char'175}\target{Further} +\vskip5pt +Creates a rectangular area which is a link to target {\it dest}; {\it rect} consists of +four space-separated numbers for lower left and upper right corner, {\it border} is the border width, and {\it colour} is the +border colour, specified as three space-separated values for red, green, and blue, all between 0 and 1. +\vskip5pt +\linkarea{title}{150 30 180 60}{2}{0.8 0 0} +\image[width 2cm]{Stern.png} +\vskip5pt +Notice also that {\cf\char'134 LinkBar} has been redefined (on the previous slide already) +\linkarea{Images}{10 100 50 120}{2}{0.8 0 1} +\NewSlide +%%% +%%% +%%% +\SlideTitle{\hfill Transition Effects} +\UseTrans +\SetTrans{Fade} +\SetDuration{2} +\def\satt{\setcolour\attentioncolour} +\def\sumcol{0 0 0} +\def\sscol{\setcolour\sumcol} +\Frames{6}{% +Transition effects for a presentation +can be provided by the macros in {\cf present-transitions.tex} +to be {\cf\char'134input} after {\cf present.tex}. + +\beforeframe2\hide +Transitions are activated with {\afterframe1\cf\char'134UseTrans} and deactivated with +{\afterframe1\cf\char'134NoTrans}. + +\beforeframe3\hide +The type of a transition effect is selected with {\afterframe2\cf\char'134SetTrans\char'173}{\it TYPE\/}{\afterframe2\cf\char'175}, +the duration of a transition effect +with {\afterframe2\cf\char'134SetDuration\char'173}{\it num}{\afterframe2\cf\char'175}. + +\beforeframe4\hide +Possible values for {\it TYPE} are {\afterframe3\cf Split}, +{\afterframe3\cf Blinds}, +{\afterframe3\cf Box}, +{\afterframe3\cf Wipe}, +{\afterframe3\cf Dissolve}, +{\afterframe3\cf Glitter}, +{\afterframe3\cf R}, +{\afterframe3\cf Fly}, +{\afterframe3\cf Push}, +{\afterframe3\cf Cover}, +{\afterframe3\cf Uncover}, +{\afterframe3\cf Fade}. +See the PDF Reference for details. +\beforeframe5\hide +{\it num} specifies the duration of the transition effect in seconds. + +\beforeframe6\hide{\afterframe5\satt Only +some transition effects may be supported by your pdf-viewer}.}% +\endFrames +\NewSlide +\SetTrans{Push} +\Frames{15}{% +Compare +$$ +\Gamma^{{\onframe3\satt a}}_{{\onframe4\satt b}{\onframe5\satt c}}= +{\textstyle{1\over2}} +g^{{\onframe3\satt a}{\afterframe1\sscol u}} +\Big(\partial_{\onframe4\satt b} +g_{{\afterframe1\sscol u}{\onframe5\satt c}} ++\partial_{\onframe5\satt c}g_{{\onframe4\satt b}{\afterframe1\sscol u}} +-\partial_{\afterframe1\sscol u}g_{{\onframe4\satt b}{\onframe5\satt c}}\Big) +$$ +\beforeframe6\hide +\onframe{5}\NoTrans +with +$$ +\Gamma^{{\onframe{8}\satt a}}_{{\onframe{9}\satt b}{\onframe{10}\satt c}}= +{\textstyle{1\over2}} +g^{{\onframe{8}\satt a}{\afterframe6\sscol u}} +\Big(\partial_{\onframe{9}\satt b} +g_{{\afterframe6\sscol u}{\onframe{10}\satt c}} ++\partial_{\onframe{10}\satt c}g_{{\onframe{9}\satt b}{\afterframe6\sscol u}} +-\partial_{\afterframe6\sscol u}g_{{\onframe{9}\satt b}{\onframe{10}\satt c}}\Big) +$$ +\onframe{11}\UseTrans +\beforeframe{11}\hide\onframe{11}{\SetTrans{Dissolve}}% +Are transition effects an advantage didactically? +\vskip5pt +\beforeframe{12}\hide\onframe{12}{\SetTrans{Fade}} +Sometimes {\afterframe{12}\satt\onframe{12}\hide transition} effects may be {\afterframe{12}\satt\onframe{12}\hide helpful}. +\vskip3pt +Sometimes they {\beforeframe{14}\hide\afterframe{13}\satt distract} +the {\beforeframe{14}\hide\afterframe{13}\satt audience} +from the {\beforeframe{14}\hide\afterframe{13}\satt content} of the slide. +\vskip3pt +\onframe{14}{\SetTrans{Dissolve}\SetDuration{5}} +\beforeframe{15}\hide Use links or {\onframe{15}\cf \char'134PageBar}-symbols for navigation in order to +see transition effects. +}\endFrames +\NewSlide +\NoTrans +%%% +%%% +%%% +\SlideTitle{\hfil Background Images} +\SetBackground{background.png} +You can set images for the background with +\vskip5pt +{\cf\char'134 SetBackground\char'173}{\it filename}{\cf\char'175} +\vskip5pt +where +{\it filename} is the name of the image file. +\vskip5pt +The background image is unset (i.e. the background colour will show again) with {\cf\char'134 UnsetBackground}. +\vskip5pt +The background image is scaled to width and height of the slide. It should have an appropriate aspect ratio. +\vskip5pt +\att{As you see some combinations of text colour and background image can cause visibility problems.} +\NewSlide +\UnsetBackground +%%% +%%% +%%% +\SlideTitle{\hfil Concluding Remarks} +PDF provides the possibility to include movies, and to launch applications (which could be a movie player) via clickable +elements. The usability for a presentation depends on how to manage the player together with a fullscreen display of the +slides. Movie support is not officially included in {\cf present.tex}. +\vskip5pt +If you prepare a pdf-image for a presentation which is to be shown on some different computer, it would be best to +embed fonts used in the image into the image file. For example, if you have a file {\cf image.eps}, you need to +convert it to pdf, in order to use it with {\cf pdftex}. You can embed the fonts by +\vskip5pt +{\cf ps2pdf -dEPSCrop=true -dPDFA image.eps} +\vskip5pt +A look at {\cf present.tex} is recommended. +\bye diff --git a/macros/plain/contrib/present/Pfeil1.pdf b/macros/plain/contrib/present/Pfeil1.pdf Binary files differnew file mode 100644 index 0000000000..8e28f5c1cc --- /dev/null +++ b/macros/plain/contrib/present/Pfeil1.pdf diff --git a/macros/plain/contrib/present/Pfeil2.pdf b/macros/plain/contrib/present/Pfeil2.pdf Binary files differnew file mode 100644 index 0000000000..9873536d99 --- /dev/null +++ b/macros/plain/contrib/present/Pfeil2.pdf diff --git a/macros/plain/contrib/present/Pfeil3.pdf b/macros/plain/contrib/present/Pfeil3.pdf Binary files differnew file mode 100644 index 0000000000..746ba5f450 --- /dev/null +++ b/macros/plain/contrib/present/Pfeil3.pdf diff --git a/macros/plain/contrib/present/Pfeil4.pdf b/macros/plain/contrib/present/Pfeil4.pdf Binary files differnew file mode 100644 index 0000000000..fdccf86b70 --- /dev/null +++ b/macros/plain/contrib/present/Pfeil4.pdf diff --git a/macros/plain/contrib/present/README b/macros/plain/contrib/present/README new file mode 100644 index 0000000000..a8f6bf42a5 --- /dev/null +++ b/macros/plain/contrib/present/README @@ -0,0 +1,69 @@ +present.tex +Version 2.2.1, February 2019 + +Some simple macros for preparing presentations in TeX +Copyright 2010-2019 Matthias Meister +Distributed under the LaTeX Project Public License + +present.tex +holds the macros, and is simply \input in a file + +HowToTalkTeX.pdf +is a presentation on present.tex done with the macros + +HowToTalkTeX.tex +is the corresponding source; together with the pdf it +is an example of how the macros are used to prepare a talk. + +Required: pdftex + +The macros in present.tex allow the user to: ++) set a colour for the background and for the text ++) set background images ++) include links between parts of the presentation ++) include weblinks ++) include links to local files ++) include images ++) show slides incrementally + +The macros as such are simple enough so that users should +not find it difficult to adapt them to their needs. + +A documentation for pdftex and the PDF-Reference might +occasionally be useful in the context of those macros +which have PDF-code in their replacement text. + +----------------------- +Changes + +From 2.2 to 2.2.1: + +Merely updated contact details in files. +No changes to the macros. + + +From 2.1 to 2.2: + +Added macros \Frames, \endFrames, \onframe, \afterframe, +\beforeframe to support the incremental showing of a slide +as a sequence of frames. + +The additional source file present-transitions.tex +contains macro definitions which allow to use transition +effects between slides / frames. + + +From 2.0 to 2.1: + +Fixed a bug which caused complaints about unknown +operators 0.0RG and 0.0rg with some pdf-viewers. + + +From 1.0 to 2.0: + +*) An image can be set on the slide background. +*) Added control word \rm for using roman type + at correct size within math. +*) Rewritten colour support; miniltx.tex, color.tex, + color.sty no longer required. As a result, control + sequences for handling colour have changed. diff --git a/macros/plain/contrib/present/Sagnac.pdf b/macros/plain/contrib/present/Sagnac.pdf Binary files differnew file mode 100644 index 0000000000..d7fc7cae23 --- /dev/null +++ b/macros/plain/contrib/present/Sagnac.pdf diff --git a/macros/plain/contrib/present/Stern.png b/macros/plain/contrib/present/Stern.png Binary files differnew file mode 100644 index 0000000000..b94b6646d0 --- /dev/null +++ b/macros/plain/contrib/present/Stern.png diff --git a/macros/plain/contrib/present/background.png b/macros/plain/contrib/present/background.png Binary files differnew file mode 100644 index 0000000000..d78f8b107c --- /dev/null +++ b/macros/plain/contrib/present/background.png diff --git a/macros/plain/contrib/present/present-transitions.tex b/macros/plain/contrib/present/present-transitions.tex new file mode 100644 index 0000000000..fe28fa50e4 --- /dev/null +++ b/macros/plain/contrib/present/present-transitions.tex @@ -0,0 +1,53 @@ +% +% +% present-transitions.tex +% +% Author: Matthias Meister (tex@flamma-mentis.eu) +% Version 1.0, April 2012 +% +% This file is part of a work distributed under the LaTeX Project Public License. +% The macros in this file are a supplement to the macros in present.tex. +% +\catcode`\@=11 +\let\simplelink=\link +\let\simplelinkarea=\linkarea +\let\simplepagelink=\pagelink + +\def\Tr@ns{Push} +\def\D@r{2} + +\def\tl@nk#1#2{% +\pdfstartlink attr {/Border [0 0 0]} user {/Subtype /Link /A <</S /GoTo /D /#1 /Next <</S /Trans /Trans << /S /\Tr@ns /D \D@r >> >> >>}#2% +\pdfendlink} + +\def\tl@nkarea#1#2#3#4{% +\pdfannot{% +/Subtype /Link +/Rect [#2] +/Border [0 0 #3] +/C [#4] +/A << /S /GoTo /D (#1) /Next << /S /Trans /Trans << /S /\Tr@ns /D \D@r >> >> >>}} + +\def\tpagel@nk#1#2{% +\pdfstartlink +attr {/Border [0 0 0]} user {/Subtype /Link /A <</S /Named /N /#1 /Next << /S /Trans /Trans << /S /\Tr@ns /D \D@r>> >> >>}% +#2% +\pdfendlink} + +\def\NoTrans{% +\global\let\link=\simplelink +\global\let\pagelink=\simplepagelink +\global\let\linkarea=\simplelinkarea +} + +\def\UseTrans{% +\global\let\link=\tl@nk +\global\let\pagelink=\tpagel@nk +\global\let\linkarea=\tl@nkarea +} + +\def\SetDuration#1{\gdef\D@r{#1}} +\def\SetTrans#1{\gdef\Tr@ns{#1}} + +\NoTrans +\catcode`\@=12 diff --git a/macros/plain/contrib/present/present.tex b/macros/plain/contrib/present/present.tex new file mode 100644 index 0000000000..30f94cde7a --- /dev/null +++ b/macros/plain/contrib/present/present.tex @@ -0,0 +1,297 @@ +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% +% present.tex +% Some macros for preparing presentations in TeX, using pdftex +% Version 2.2.1 +% Copyright 2010-2019 Matthias Meister +% +% This work may be distributed and/or modified under the +% conditions of the LaTeX Project Public License, either version 1.3 +% of this license or (at your option) any later version. +% The latest version of this license is in +% http://www.latex-project.org/lppl.txt +% +% This work has the LPPL maintenance status 'maintained'. +% +% The Current Maintainer of this work is: +% +% Matthias Meister (tex@flamma-mentis.eu) +% +% The work consists of the following files: +% present.tex (the macro collection) +% present-transitions.tex (additional macros, providing transition effects) +% HowToTalkTeX.tex (an example of present.tex in use and a documentation) +% HowToTalkTeX.pdf (pdf obtained from HowToTalkTex.tex with pdftex) +% Stern.png (auxiliary file) +% Sagnac.pdf (auxiliary file) +% Pfeil1.pdf (auxiliary file) +% Pfeil2.pdf (auxiliary file) +% Pfeil3.pdf (auxiliary file) +% Pfeil4.pdf (auxiliary file) +% background.png (auxiliary file) +% +% (The auxiliary files are used in present.tex and HowToTalkTeX.tex, and +% therefore should remain unchanged, too) +% +% With reference to the definitions in the LaTeX Project Public License, for the +% purposes of this work a 'Base Interpreter' is a program implementing the TeX +% language. +% +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + +\catcode`\@=11 + + +\parindent0pt % Indentation probably not good for presentation +\parskip0pt % Neither is automatic extra space between paragraphs + +\def\StandardAspect{% % Define "slide format", basically determined +\pdfpagewidth=120mm % by aspect ratio of screen +\pdfpageheight=90mm % StandardAspect gives 4:3 aspect ratio +\vsize=67mm % +\hsize=110mm % If you change these values, +\hoffset=-20.4mm % do so with care. +\voffset=-12.4mm % +} + +\def\WideAspect{% % WideAspect gives 144:90 aspect ratio +\pdfpagewidth=144mm % +\pdfpageheight=90mm % +\vsize=67mm % If you change these values, +\hsize=134mm % do so with care +\hoffset=-20.4mm % +\voffset=-12.4mm % +} + + +% +% Set some fonts +% +\font\titlefont=cmssbx10 at 20pt % Define fonts for title of presentation +\font\normalfont=cmss12 % ordinary text +\font\slidetitlefont=cmssbx10 % title of a slide +\font\linkbarfont=cmss8 % the LinkBar (see below) +\font\it=cmti12 +% +\baselineskip=15pt +% %% Below fonts for math are adapted to 12pt size +\font\tfont=cmr12 +\font\sfont=cmr9 +\font\ssfont=cmr7 +\font\tifont=cmmi12 +\font\sifont=cmmi9 +\font\ssifont=cmmi7 +\font\tsyfont=cmsy10 at 12pt +\font\ssyfont=cmsy9 +\font\sssyfont=cmsy7 +\font\texfont=cmex10 at 12 pt +\font\sexfont=cmex9 +\font\ssexfont=cmex7 +% +\textfont0=\tfont +\scriptfont0=\sfont +\scriptscriptfont0=\ssfont +\textfont1=\tifont +\scriptfont1=\sifont +\scriptscriptfont1=\ssifont +\textfont2=\tsyfont +\scriptfont2=\ssyfont +\scriptscriptfont2=\sssyfont +\textfont3=\texfont +\scriptfont3=\sexfont +\scriptscriptfont3=\ssexfont +% + +% +% Definitions to allow referencing the last page of a document +% +\newwrite\wl@stpage +\newread\rl@stpage +\def\bye{% +\immediate\openout\wl@stpage=\jobname.lp% The number of the last slide is written in a file +\write\wl@stpage{\the\pageno}% % with extension .lp +\closeout\wl@stpage +\par\vfill +\supereject +\end +} +\def\LP{undef} +\openin\rl@stpage=\jobname.lp +\ifeof\rl@stpage\closein\rl@stpage\message{RUN AGAIN to get correct number of last page!} +\else\read\rl@stpage to \LP\fi + +% +% Define some colours +% +% The commands below handle colour without color.tex, directly with pdftex +% Added October 3rd, 2010 + +% Define colours +\def\backgroundcolour{1.0 1.0 1.0} % Colour of page background +\def\textcolour{0.0 0.0 1.0} % Colour of text +\def\attentioncolour{1 0 0} % Colour for "Attention" + +\newdimen\vsh@ft % vertical shift for background image, vsh@ft+\voffset=-25.4mm +\newdimen\hsh@ft % horizontal shift for background image, hsh@ft+\hoffset=-25.4mm +\vsh@ft=-13mm +\hsh@ft=-5mm + +\def\bl@nk{ } % Introduced this +\newcount\colst@ck +\colst@ck=\pdfcolorstackinit page {\textcolour\bl@nk rg \textcolour\bl@nk RG} % and modified this on March 20, 2012 +\def\popst@ck{\pdfcolorstack\colst@ck pop} +\def\setcolour#1{\pdfcolorstack\colst@ck push {#1 rg #1 RG}\aftergroup\popst@ck} +\long\def\coloured#1#2{{\setcolour#1#2}} +\long\def\att#1{\coloured\attentioncolour{#1}} +\def\bgc@lset{\relax} +\def\setbgcolour#1{\def\bgc@lset{\begingroup\pdfcolorstack\colst@ck push {#1 rg #1 RG}\aftergroup\popst@ck +\vbox to 0pt{\kern\vsh@ft\hbox to 0pt{% +\kern\hsh@ft\vrule depth0pt height\pdfpageheight width\pdfpagewidth\hss}\vss} +\nointerlineskip +\endgroup}} + + +\def\NewSlide{\vfill\eject} % Begin a new slide; slide number increases + +\def\NewFrame{\vfill\eject\advance\pageno by -1} % Begin new frame ("same" slide, with changes) + % slide number does not change + +\def\SlideTitle#1{% % Set the slide title, show it as the headline +\global\headline{% % of the slide in slidetitlefont, with a +\vbox to 5mm{% % horizontal line separating the headline from +\hbox to \hsize{\slidetitlefont #1}% % the main body of the slide +\vskip3pt plus 1fil minus 1fil +\hrule height 1pt depth 0pt +}}} + +\def\SlideFoot{% % Set the footline of the slide, separated by +\global\footline{% % a horizontal slide from the main body of the +\vbox to 5mm {% % slide. This macro takes no argument. +\hrule height 1pt depth 0pt % Several possibilities are provided below. +\vskip3pt plus 1fil minus 1fil % Only one of the following options should be +\hbox to \hsize{% % uncommented. +\rlap{\LinkBar}\phantom{\PageBar}\hfil{\normalfont\the\pageno/\LP}\hfil\PageBar% Links to sections, +% %slide number, page navigation +%\hfil\the\pageno/\LP\hfil% % Slide number; \LP is number of last slide +%% % empty +}}}} + +\def\LinkBar{% % If you use LinkBar, you have to define it and possibly redefine +LinkBar} % it at several places in your talk. The definition given + % just prints "LinkBar", in order to show where it goes. + +\def\PageBar{% % This provides page navigation: Next page, previous page, +\hbox{% % going back and forth in page history +\pagelink{PrevPage}{\image[width4mm]{Pfeil2.pdf}}\kern2mm +\pagelink{NextPage}{\image[width4mm]{Pfeil1.pdf}}\kern2mm +\pagelink{GoBack}{\image[width4mm]{Pfeil3.pdf}}\kern2mm +\pagelink{GoForward}{\image[width4mm]{Pfeil4.pdf}} +}} + +% +% Make #2 a link to the destination named #1 in the presentation. +% A destination is created and named with the \target control word. +% +\def\link#1#2{% +\pdfstartlink attr {/Border [0 0 0]} goto name {#1} +#2% +\pdfendlink} + +% +% Creates named destination at position where it is issued. #1 is name of destination. +% +\def\target#1{% +\pdfdest name {#1} xyz\relax} + +% +% Used in the PageBar. Uses the predefined actions PrevPage etc. +% +\def\pagelink#1#2{% +\pdfstartlink +attr {/Border [0 0 0]} user {/Subtype /Link /A <</S /Named /N /#1>>}% +#2% +\pdfendlink} + +% +% Sets a rectangular area of the screen to be a link to a destination. +% #1 is the destination (in the same document); it can be a named or other destination +% #2 defines the rectangle which is the active link area, specified by +% four space separated numbers corresponding to lower left and upper right corners +% #3 is the border width (in "default user-space units") +% #4 is the RGB-color, specified as three space separated numbers R G B between 0 and 1 +% +\def\linkarea#1#2#3#4{% +\pdfannot{% +/Subtype /Link +/Rect [#2] +/Border [0 0 #3] +/C [#4] +/A << /S /GoTo /D (#1) >>}} + +% +% Make #2 a link to the web destination #1 +% +\def\weblink#1#2{% +\pdfstartlink attr {/Border [0 0 0]} user {/Subtype /Link /A << /S /URI /URI (#1) >>}% +#2\pdfendlink} + +% +% Make #3 a link to destination #2 in file #1 (a pdf-file). One of several possible forms of a destination +% is [page /Fit], where "page" is the page number in the file, counting from 0 +% Named destinations are also possible +% +\def\filelink#1#2#3{% +\pdfstartlink attr {/Border [0 0 0]} user {/Subtype /Link /A << /S /GoToR /F (#1) /D #2 /NewWindow true >>}% +#3\pdfendlink} + +% +% Includes an image. The image file name is #2, and #1 is a specification of the dimension of the +% image (will be scaled accordingly) in the usual TeX syntax (width, height, depth). +% +\def\image[#1]#2{% +\pdfximage #1 {#2}\pdfrefximage\pdflastximage} + +%\def\movie#1#2#3{% +%\pdfstartlink attr {/Border [0 0 0]} user {/Subtype /Link /A << /S /Launch /F (mplayer -noborder -ontop -geometry #2 #1) >>}% +%#3\pdfendlink} + +\footline{} % Set some +\StandardAspect % default values + +% +% Added 28. August 2010. Not part of version 1.0 +% +% Setting / unsetting a background image. If no background image is used, the background shows background colour +% +\def\h@lpr{\relax} +\def\BIM@G{\relax} +\def\SetBackground#1{\def\BIM@G{#1}} +\def\UnsetBackground{\def\BIM@G{\relax}} +\output{% +\shipout\vbox{% +\bgc@lset +\ifx\BIM@G\h@lpr \else +{\vbox to 0pt{\kern\vsh@ft\hbox to 0pt{\kern\hsh@ft\image[width\pdfpagewidth height\pdfpageheight]{\BIM@G}\hss}\vss}% +\nointerlineskip}\fi +\makeheadline +\pagebody +\makefootline} +\advancepageno +\ifnum\outputpenalty>-20000\else\dosupereject\fi} + +\def\rm{\fam=0} %% Added 14. September 2010. Use roman font in math. + +%%% +%%% Macros for incremental showing of slides (frames). +%%% Added 29. March 2012 +%%% +\newcount\ind@x +\newcount\m@xind +\long\def\Frames#1#2{\m@xind=#1\long\def\Fr@mes{#2}} +\def\endFrames{\ind@x=0% +\loop\advance\ind@x by 1\begingroup\Fr@mes\endgroup\ifnum\ind@x<\m@xind\NewFrame\repeat} +\def\onframe#1#2{\ifnum\ind@x=#1#2\else\relax\fi} +\def\afterframe#1#2{\ifnum\ind@x>#1#2\else\relax\fi} +\def\beforeframe#1#2{\ifnum\ind@x<#1#2\else\relax\fi} +\def\hide{\setcolour\backgroundcolour} +\catcode`\@=12 |