Forum How do I...?

units available

jim_albright
In experimenting with the size of a div I couldn't get pica (pi) or (p) to work. But %, em, px, pt, cm, and in all seem to work. Why doesn't pica work?

Jim Albright
Wycliffe Bible Translators

mikeday
I believe pica units are "pc".
jim_albright
Works great. Thanks again. Where could I have found that? Wikipedia gives abbreviation as (p).

Jim Albright
Wycliffe Bible Translators

mikeday
The CSS 2.1 specification describes length units, but to be honest I've never seen anyone actually use picas. :D
jim_albright
Karis was the graphic artist that I worked under. She is from New Zealand. She used picas all the time. I had the privilege of typesetting three New Testaments under her watchful eye.

A word to the wise. Even though you have a wonderful tool here with Prince, make sure you have a graphic artist check your work. I had great tools with Ventura Publisher and a laser printer, but I didn't know the difference between sans serif and serif when I started. The before and after pages with her help were so striking that I destroyed all evidence of my ignorance. Too bad it would make good copy now.

Jim Albright
Wycliffe Bible Translators

_savage
Thanks for this thread!

Mike, the CSS specification that you link to gives accurate measurements for absolute units. Inch (1in = 2.54cm) and Point (1pt = 1/72nd of 1in, 72pt = 1in) are the ones I am particularly interested in, because at the moment these are the only units I use in my stylesheets. (I assume that is enough considering that the target medium, i.e. page size, is given and fixed.)

Does Prince implement those units precisely?

Edited by _savage

mikeday
Yes, internally PDF files are specified in points (exactly 1/72in) and Prince converts all other units to points using the standard conversion factors. The only tricky one is pixels. :)
_savage
I can imagine! How do you handle pixels in your case when pixels are really a device-specific resolution?
mikeday
Prince defaults to 96dpi for px units, although you can override this if you really have to with the --css-dpi option on the command-line.