6

I have something like this:

\setuppagenumbering[state=stop]
\setuppapersize[A5,landscape][A4]
\setuplayout[topspace=1cm,backspace=1cm,
  header=0mm,footer=0mm,
  width=middle,height=middle]
\setuparranging[2TOP]

I'd like to have a thin line in the middle of the page so that I know where to cut the paper. Alternatively, kind of "crop marks" with the same purpose would do. Is there an option for that? marking=on in \setuplayout didn't help (probably because the "classical" crop marks fall outside of the paper with these settings - am I right?).

I'm using ConTeXt MkIV.

Note: please retag this question as appropriate, I didn't know what tags would be best.

8

Marking are usually shown in a way so that they do no show when the page is cut. One way to see what is happening is to set the print paer size to A3. For example,

\setuppapersize[A5,landscape][A3]
\setuparranging[2TOP]

\setuplayout
  [
    topspace=1cm,
    backspace=1cm,
    header=0mm,
    footer=0mm,
    width=middle,
    height=middle,
    marking=on,
    location=middle,
  ]

  \showframe

enter image description here

However, you can easily add a background image to show your own marks.

\setuppapersize[A5,landscape][A4]
\setuparranging[2TOP]

\setuplayout
  [
    topspace=1cm,
    backspace=1cm,
    header=0mm,
    footer=0mm,
    width=middle,
    height=middle,
    marking=on,
    location=middle,
  ]

\startuseMPgraphic{cropmarks}
  StartPage;
  begingroup;
  drawoptions(withpen pencircle scaled 1bp withcolor red);
  if odd(\the\realpageno) :
    draw (0,0) -- (1cm, 0);
    draw (PaperWidth,1mm) -- (PaperWidth-1cm, 1mm);
  fi ;
  endgroup;
  StopPage;
\stopuseMPgraphic

\defineoverlay[cropmarks][\useMPgraphic{cropmarks}]

\setupbackgrounds[page][background=cropmarks]

enter image description here

4

I had the same idea as Aditya, however with a different approach. Adityas solution resorts to MetaPost, the most flexible solution you can get. The following solution uses a version of ConTeXts \framed command to draw a thin line between the pages without direct use of MetaPost.

\setuppagenumbering [state=stop]
\setuparranging     [2TOP]
\setuppapersize     [A5,landscape] [A4]
\setuplayout
  [
     topspace=1cm,
    backspace=1cm,
       header=0mm,
       footer=0mm,
        width=middle,
       height=middle,
  ]

\setupbackgrounds [page] [background=cropmarks, setups=cropmarks]
\definelayer      [cropmarks]

\startsetups cropmarks
  \doifoddpageelse{}{%
    \setlayerframed [cropmarks]
      [
           frame=off,
        topframe=on,
           width=\paperwidth,
          height=\paperheight,
      ]{}}
\stopsetups

\starttext
  \dorecurse{20}{
    \input knuth\par}
\stoptext

The result:

result

EDIT: The code above is way too complicated, much easier:

\setuppagenumbering [state=stop]
\setuparranging     [2TOP]
\setuppapersize     [A5,landscape] [A4]
\setupbackgrounds   [page] [topframe=on]
\setuplayout
  [  topspace=1cm,
    backspace=1cm,
       header=0mm,
       footer=0mm,
        width=middle,
       height=middle]

\starttext
  \dorecurse{20}{
    \input knuth\par}
\stoptext
2
  • It is better to use \doifoddpageelse{...}{...} rather an an explicit \ifodd... test. – Aditya Apr 19 '12 at 19:18
  • 2
    You're totally right, I changed it. The point is that it's easy to remember the basic TeX building blocks. ConTeXt has so many of them, I have to look them up. And, you know … the human in general is lazy :) – Marco Apr 19 '12 at 19:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.