Default Paper Size in Open Office

Under Linux (or at least under Gnome or Ubuntu) we already had the issue with default paper size in Firefox. Now on my older Ubuntu 10.04 workstation where I have not yet upgraded from Open Office to LibreOffice my wife has a permanent problem with wrong default paper size when using Open Office.

I have examined the situation and found out that in Ubuntu system administration under Printing the default paper size has not been set to A4. OK, but didn't help for OpenOffice.

Finally I gave up finding the problem and started to google. After a while I found a blog entry at "Starry Hope": OpenOffice Default Paper Size for Printing - here the important part:
1. Change the default paper size in /etc/papersize
This is the first place to look and solved the problem most of the time. Simply edit /etc/papersize and change “letter” to “a4″ then restart OpenOffice.

2. Check for settings in ~/.cups
In some cases, CUPS saves printer settings for individual users in their home directory (don’t ask me why). If you see a .cups directory in your home directory, open it and see if “Letter” isn’t set as the default paper size in there. (In my case, I just deleted the .cups directory all together).

3. Check for poorly formatted PPD files
Check the PPD file for your printer in /etc/cups/ppd/ to see if it has errors. Apparently, some PPD files are incorrectly formatted and cause an error. This problem is most commonly discussed in relation to Brother printers. You can find more info in this bug report. - Seems to be fixed.

4. Change DefaultPageSize in SGENPRT.PS
It appears that OpenOffice gets its default media size for some printers from the DefaultPageSize line in the /usr/lib/openoffice/basis3.2/share/psprint/driver/SGENPRT.PS file. More info here.
In my case indeed, changing "letter" to "A4" in /etc/papersize already solved the issue - thanks so much!

Related post: Firefox change default page format, Normal.dot in OpenOffice or LibreOffice.

No comments: