[NTG-context] Logo in the margin at the bottom of the page

Henri Menke henrimenke at gmail.com
Wed Aug 15 06:10:21 CEST 2018


You have to use the correct margin width, i.e. \rightmarginwidth in the 
right margin and vice versa in the left margin.  You should also scale 
the margins to fit in the backspace/cutspace because by default they 
don't and run off the paper.

\showframe
\useMPlibrary[dum]
\setuplayout
   [height=middle,
    width=middle,
    backspace=2cm,
    topspace=10mm,
    bottomspace=10mm,
    header=10mm,
    footer=10mm,
    footerdistance=10mm,
    headerdistance=10mm,
 
leftmargin=\dimexpr\layoutparameter{backspace}-\layoutparameter{leftmargindistance}\relax,
 
cutspace=\dimexpr\layoutparameter{rightmargin}+\layoutparameter{rightmargindistance}\relax]

\setupfooter[margin][strut=no]

\setupfootertexts
   [margin]
   []
   [{\externalfigure[dummy][width=\rightmarginwidth,height=\footerheight]}]
   []
   [{\externalfigure[dummy][width=\leftmarginwidth,height=\footerheight]}]

\starttext
\dorecurse{10}{\page[dummy]}
\stoptext


On 14/08/18 22:50, Fabrice Couvreur wrote:
> Hi Henri,
> Thank you for your suggestion.
> However, I believe that my way of doing should not be the best because 
> fixing width=\marginwidth the image is cropped.
> Fabrice
> 
> 
> \showframe
> \useMPlibrary[dum]
> \setuplayout
>    [height=middle,
>     width=middle,
>     backspace=2cm,
>     topspace=10mm,
>     bottomspace=10mm,
>     header=10mm,
>     footer=10mm,
>     footerdistance=10mm,
>     headerdistance=10mm]
> 
> \setupfooter[margin][strut=no]
> 
> \setupfootertexts
>      [margin]
>      []
>      [{\externalfigure[dummy][width=,height=\footerheight]}]
>      []
>      [{\externalfigure[dummy][width=\marginwidth,height=\footerheight]}]
> 
>      \starttext
>      \dorecurse{10}{\page[dummy]}
>      \stoptext
> 
> 
> Le mar. 14 août 2018 à 12:18, Henri Menke <henrimenke at gmail.com 
> <mailto:henrimenke at gmail.com>> a écrit :
> 
> 
> 
>     On 14/08/18 22:13, Fabrice Couvreur wrote:
>      > Hello,
>      > I wish to place a small logo at the bottom of the page.
>      > It works almost but it is not very well adjusted.
>      > How to cure it ?
>      > Thank you.
>      > fabrice
>      >
>      > \showframe
>      > \useMPlibrary[dum]
>      > \setuplayout
>      >    [height=middle,
>      >     width=middle,
>      >     backspace=2cm,
>      >     topspace=10mm,
>      >     bottomspace=10mm,
>      >     header=10mm,
>      >     footer=10mm,
>      >     footerdistance=10mm,
>      >     headerdistance=10mm]
>      >
> 
>     \setupfooter[margin][strut=no]
> 
>      > \setupfootertexts
>      >      [margin]
>      >      []
>      >     
>     [{\externalfigure[dummy][width=\marginwidth,height=\footerheight]}]
>      >      []
>      >     
>     [{\externalfigure[dummy][width=\marginwidth,height=\footerheight]}]
>      >
>      >      \starttext
>      >      \dorecurse{10}{\page[dummy]}
>      >      \stoptext
>      >
>      >
>      >
>     ___________________________________________________________________________________
>      > If your question is of interest to others as well, please add an
>     entry to the Wiki!
>      >
>      > maillist : ntg-context at ntg.nl <mailto:ntg-context at ntg.nl> /
>     http://www.ntg.nl/mailman/listinfo/ntg-context
>      > webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
>      > archive  : https://bitbucket.org/phg/context-mirror/commits/
>      > wiki     : http://contextgarden.net
>      >
>     ___________________________________________________________________________________
>      >
>     ___________________________________________________________________________________
>     If your question is of interest to others as well, please add an
>     entry to the Wiki!
> 
>     maillist : ntg-context at ntg.nl <mailto:ntg-context at ntg.nl> /
>     http://www.ntg.nl/mailman/listinfo/ntg-context
>     webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
>     archive  : https://bitbucket.org/phg/context-mirror/commits/
>     wiki     : http://contextgarden.net
>     ___________________________________________________________________________________
> 
> 
> 
> ___________________________________________________________________________________
> If your question is of interest to others as well, please add an entry to the Wiki!
> 
> maillist : ntg-context at ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki     : http://contextgarden.net
> ___________________________________________________________________________________
> 


More information about the ntg-context mailing list