11

is there a class or template to make a LaTeX page look like a math-ruled notebook/pad page? Thanks.

1 Answers1

17

You can do it by using TikZ and the background package (needs two runs to work correctly):

\documentclass{scrartcl}
\usepackage[margin=25mm]{geometry}
\usepackage{tikz}
\usepackage{lipsum}
\usepackage{background}

\SetBgContents%
{   \begin{tikzpicture}[remember picture, overlay]
    \draw [line width=0.3pt,color=gray,step=0.5cm] (current page.south west) grid (current page.north east);
    \end{tikzpicture}
}
\SetBgScale{1}
\SetBgAngle{0}

\begin{document}

\lipsum[1-14]

\end{document}

enter image description here

Tom Bombadil
  • 40,123
  • From the version 2.0 of background there's a new syntax for the options; your settings can be written as \backgroundsetup{ contents= {\begin{tikzpicture}[remember picture, overlay] \draw [line width=0.3pt,color=gray,step=0.5cm] (current page.south west) grid (current page.north east); \end{tikzpicture} } scale=1, angle=0} (the \SetBg... family of commands can still be used with the new version). – Gonzalo Medina Aug 24 '12 at 00:14
  • 2
    There's no need to explicitly load tikz; the background package internally loads it if the user hasn't loaded before. – Gonzalo Medina Aug 24 '12 at 00:15
  • @GonzaloMedina: Thanks for the info about the loading, and I'm aware there's a new version. The MiKTeX updater does not yet have it, and I was to lazy to install it manually. Great update, it will keep me from looking up the commands every time I use it :) – Tom Bombadil Aug 24 '12 at 00:19
  • 1
    (Just a question: is it possible to have the text aligned to the background lines?) – Karlo May 03 '17 at 15:36