I'm trying to create a XeTeX class which aligns text vertically on a grid. What I'm trying to achieve is layout on the left (created in InDesign), and what I'm generating now is on the right (the document text's baseline is not aligned with the grid):
http://koziej.info/typo-problems.png
I'm using geometry package with page head just below the top margin (includehead option). I use fancyhdr package to render these headings.
Question: how to specify \headheight and \headsep, so that the page content is aligned with the grid.
I cannot count it, because:
I do not know how within the head space (specified by
\headheight) the head content is positioned. Do the letters start just where top margin ends? Or is there some additional space?I do not know, also, how much space below the head baseline is still reserved for the head.
If I would know #2, i could set
\headskipso what when the first line height is added (first line height is just the font size, without the leading, right? so 10pt for 10pt document), I should get a multiplication of the grid step size. Yet I'm also not sure if there is no spacing above the the first line of text (isheight = dept + font sizefor the first line?).
BTW: is there some way to display all the boxes created by LaTeX?