Hi, I am new to Manjaro and am using XFCE. Every time my wife and I try to print something it is defaulting to A4. I’d like to set the default to Letter so that I don’t have to set it in the Print dialog or on the printer to override A4 so that it will print.
I tried adding a line with “Letter” (without the quotes) to the /etc/papersize file but it seemed to have no effect, neither before or after rebooting.
If you are using Plasma there is a configuration which will override what is defined in /etc/locale.conf - it took me quite a while to figure that out - this has been the cause of many issues over time.
System Settings → Region and Language
The changes you make will be stored in ~/.config/plasma-localerc.
I suppose I should have remembered this (but didn’t).
Typically, I override LC_TIME with en_ZA,UTF-8 to use the ISO time format, while leaving all in /etc/locale.conf uniform for other applications that need it to be - the GUI method via Plasma’s Region and Language dialogs make that relatively easy.
There is also a possibility that the printer itself (which, so far has remained a mystery) might have it’s own overrides for paper formats.
When I bring up LibreOffice the paper size says Letter, but when I bring up Ocular or Kate no matter what I’ve tried so far it still says A4. Since some work and some don’t, and I didn’t have this problem before changing our laptops to Manjaro, I’m thinking that the printer isn’t the problem. On windows it always defaulted to Letter size paper.
I am guessing - I cannot know for sure - but Kate and Okular is Plasma applications and as such they may be expecting plasma-localerc file and fallback to international standard when not found.
The current paper size is obtained by looking in order at the following values until a non-empty value is found. If no paper size is configured, paper exits with an error.
The PAPERSIZE environment variable
The user’s default paper size in $XDG_CONFIG_HOME/papersize
The current locale’s default paper size (if supported by the system)
The system default paper size in /etc/papersize
The first paper size in the system list
The first paper size in the user’s list
ENVIRONMENT VARIABLES
PAPERSIZE
Paper size to use.
FILES
/etc/papersize
System default paper size. $XDG_CONFIG_HOME/papersize
User’s default paper size.
Yes, I know that. I was responding to another comment.
This part was for you:
Printing from Kate
I installed Okular and Kate in a Manjaro XFCE VM.
1. I opened Kate and went immediately to Print Preview.
2. In the Print Peview window I opened Page Setup. The default page size (for me) is A4 - I used the Page size dropdown to find “Letter”;
Three options found: “Letter Extra”, “Letter Plus” and “Letter Small” (I don’t know differences between these as I use A4).
3. I opted for “Letter Plus”, and clicked OK to close the dialog. At this point the Print Preview window visibly changed from the default paper dimensions.
4. I printed the document to print.pdf as I do not have a physical printer connected, then opened the file in Okular.
5. While the page was open in Okular I selected File → Properties and the respective dialog appeared indicating;
Page size: 216 x 322 mm (Portrait Letter Plus).
If you follow my example, what differences do you find?
Command-Line Printing and Options
In case the CUPS interface needs to be used; The following page shows how to set page sizes via the command-line, should it be useful for you.
This is not a suggestion to use CUPS via command-line, but just to inform you that the options exist, if needed.
Hi, I tried these steps and I got the same results as you. I go to print preview, change it to Legal / ANSI A (which is at the top of my list and then print it prints fine to my printer. If I get out and come back in Kate doesn’t retain my selection, it is back at A4.
That’s good, it shows that setting a page size and printing does actually work. Now, try this:
sudo nano /etc/papersize
You should see a commented line (the first line).
Beneath it, type “Letter” without the quotation marks.
Save the file.
You might need to login again, or reboot (I’m uncertain, as I’ve never needed to use this method).
Then the page default should in theory be set to Letter. Try printing, or simply follow the previous steps I gave, and all being well the default will have changed.
You are awesome. That worked very well, and that explains why LibreOffice works but Kate and Ocular did not. As you said, I needed to add the printer and add the plasma-localerc file and now it appears to be working fine. Thank you so much