3

I found simpleslides module extremely suitable for academic presentations, yet I am clueless as how to place a logo in the lower right area of the slides in any of the specified styles. Is there any way to place a logo simply from the presentation context file? or something must be done in the third party module styles? The documentation of simpleslides module indicate that tweaking any of the provided styles is possible, but still your help would be highly appreciated to show how. I didn't find helpful information by searching the ConTeXt Wiki

MWE from the same module

\usemodule[visualcounter]
\usemodule[simpleslides][style=Sunrise] 
\setupTitle
  [ title={Simple Slides?},
   author={Hirwanto},
     date={6 Januari 2013},
  ]



\setupvisualcounter
  [simpleslides:squarescounter]
  [
   distance={(\the\dimexpr\visualcounterparameter{maxwidth})/last_counter - width},
  ]

\stopmode
\starttext

\placeTitle

\SlideTitle {The first slide}

Write whatever you want.

\SlideTitle {The second slide}
Continue writing.
% \externalfigure[logo.png][width=3cm,frame=off] % How to include a logo?
\stoptext

%%% Local Variables:
%%% mode: context
%%% TeX-master: t
%%% TeX-engine: luatex
%%% End:
1
  • I am one of the co-authors of simpleslides (but I am not longer a current maintainer). The module does not provide any mechanism for placing a logo. So, using layers to place the logo is the simplest solution.
    – Aditya
    Commented Sep 21, 2018 at 15:52

2 Answers 2

3

Not the most automated solution, but as you can still use any valid ConTeXt solution I would suggest layers. Please note that in the current example you have to do manual positioning.

slides

\usemodule[visualcounter]
\usemodule[simpleslides][style=Sunrise] 
\setupTitle
  [ title={Simple Slides?},
   author={Hirwanto},
     date={6 Januari 2013},
  ]



\setupvisualcounter
  [simpleslides:squarescounter]
  [
   distance={(\the\dimexpr\visualcounterparameter{maxwidth})/last_counter - width},
  ]

\definelayer[logo][state=repeat]
\setlayer[logo][x=\dimexpr(\paperwidth-4cm)\relax,y=8.75cm]{\externalfigure[example-image.png][width=3cm,frame=off]}

\setupSlideTitle[after={\placelayer[logo]}]

\starttext

\placeTitle

\SlideTitle {The first slide}

Write whatever you want.

\SlideTitle {The second slide}
Continue writing.
\stoptext
4
  • Thanks for your valuable idea of using layers. To me this is a satisfactory solution, I still don't realize the potential power of context in doing it better than this. Please allow me to wait for other possible answers before accepting it as the answer to this question.
    – doctorate
    Commented Sep 21, 2018 at 13:36
  • @doctorate I'm pretty sure that there is a better solution (at least more automated placement), so I'm also interested in a solution by the experts :)
    – TeXnician
    Commented Sep 21, 2018 at 13:39
  • Always terminate \dimexpr with \relax. Commented Sep 21, 2018 at 21:50
  • @HenriMenke Good point, thanks. I've edited the post.
    – TeXnician
    Commented Sep 22, 2018 at 7:41
1

Using Texnician's solution, you can write your own module like

\startmodule myslidesetup
\setupvisualcounter
  [simpleslides:squarescounter]
  [
   distance={(\the\dimexpr\visualcounterparameter{maxwidth})/last_counter - width},
  ]

\definelayer[logo][state=repeat]
\setlayer[logo][x=\dimexpr(\paperwidth-4cm),y=8.75cm]{\externalfigure[example-image.png][width=3cm,frame=off]}

\setupSlideTitle[after={\placelayer[logo]}]
\stopmodule

and save it in a file t-myslidesetup.tex that can be in the same directory (or a parent)

Then you can use your setup like this :

\usemodule[visualcounter]
\usemodule[simpleslides][style=Sunrise] 
\usemodule[myslidesetup]

\setupTitle
  [ title={Simple Slides?},
   author={Hirwanto},
     date={6 Januari 2013},
  ]

\starttext

\placeTitle

\SlideTitle {The first slide}

Write whatever you want.

\SlideTitle {The second slide}
Continue writing.
\stoptext

You can also include the two calls

\usemodule[visualcounter]
\usemodule[simpleslides][style=Sunrise] 

in your own module (in the very beginning). Everything you write in your own module will override default setups so you don't have to tweak the original file and it is better if you want to share (no need to find, share and replace the modified system files).

Hope this helps

2
  • thanks for the input I am aware of a similar mechanism explained in the documentation file of simpleslides module, page 35 Using your own styles, just \usemodule[simpleslides][style=myslidesetup] would be enough if you would copy the original s-simpleslides-Sunrise.tex to your working dir and rename it to e.g. s-myslidesetup and of course adapt your changes there, it will automatically be picked up as a module. Try it for yourself.
    – doctorate
    Commented Sep 21, 2018 at 15:27
  • by the way as a naming rule, I'd prefer names which indicate which style I copied from, e.g. s-mysunrise.tex instead of giving a general name like s-myslidesetup.tex kind of thing.
    – doctorate
    Commented Sep 21, 2018 at 15:30

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .