I need to make questionnaire template for automatic processing with queXF. To do this I need to produce pages like this:

Example of page with frame

The queXF requirements for the pages are

  • unique barcode for each page (done by using barcode as page number with help of packages fancyhdr, pst-barcode, pstricks-add)
  • page frame for orientation

I need to draw the frame on each page like on the example page above (note that the frame is related to page, but not to text).

I see two ways for achieving this:

  • to set an image background
  • to draw separate lines (preferred)

Is it possible to do using LaTeX?

  • Found a hint in answer to different question for using background image: \documentclass{article} \usepackage{wallpaper} \ULCornerWallPaper{1}{background.pdf} \begin{document} Your text \end{document} But the solution without using additional files is still preferred. – Yuriy Petrovskiy Aug 30 '11 at 12:05
  • 1
    You can draw the frame / lines with pstricks. To get the same position ate every site you can use the package atbegshi or the package fancyhdr which do you use. – Marco Daniel Aug 30 '11 at 12:17
  • I had tried using fancyhdr for this, but it moves text down, below frame. (Maybe I had done something wrong) – Yuriy Petrovskiy Aug 30 '11 at 12:31
  • 1

You can use the background package:

\usepackage{lipsum}% just to generate some text

\draw (0.55\textwidth,10) -- (0.55\textwidth,0.52\textheight) -- (0.4\textwidth,0.52\textheight);
\draw (-0.55\textwidth,10) -- (-0.55\textwidth,0.52\textheight) -- (-0.4\textwidth,0.52\textheight);
\draw (-0.55\textwidth,-10) -- (-0.55\textwidth,-0.52\textheight) -- (-0.4\textwidth,-0.52\textheight);
\draw (0.55\textwidth,-10) -- (0.55\textwidth,-0.52\textheight) -- (0.4\textwidth,-0.52\textheight);





enter image description here


In relation to my comment here the adapted example with pstricks:


\newdimen\BorderWidth \BorderWidth=\paperwidth
\newdimen\BorderHeight \BorderHeight=\paperheight
\newdimen\BorderSep \BorderSep=30pt
\advance\BorderWidth by -2\BorderSep

    \advance\BorderHeight by -\BorderSep
%    \psframe[linewidth=3pt]%
%     (0,-\BorderHeight)(\BorderWidth, -\BorderSep)
    \@tempdima -\BorderHeight
    \advance\@tempdima .25\BorderWidth

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.