OpenOffice.org does envelopes quite excellently.
Open any text document, click on Insert → Envelope. The rest is completely self-explanatory to anybody who's ever had to use office-type software.
First, in Nautilus select the relevant .odt documents...
UPDATE:
You can fully "automate" the process by adding a Nautilus Action
sudo apt-get install nautilus-actions
eg (nautilus-actions setup):
Command: ooffice -writer -p -headless
Parameters: %M
Filenames: *.odt
[*]
Appears if selection has multiple files of folders
or:
here is my original "Terminal" version
In Nautilus copy selected files to the clipboard (filenames are stored)...
Set up your required printer settings in OpenOffice...
In gnome-terminal
, use the context-menu item Paste Filenames
...
Note: the pasted filenames are: 'single-quoted' and space delimited
ooffice -writer -p 'YOUR' 'PASTED' 'FILENAMES' &
I don't know how long a Terminal command-line can handle, but it does work..
(I just tested it; printing to a cups-pdf virtual "printer")
On newer versions of Ubuntu featuring LibreOffice instead of OpenOffice be sure to use the libreoffice
-command instead.
on libreoffice you might also have to use "--" instead of "-", the full command then is:
libreoffice --writer -p --headless 'filename1' 'filename2'
Best Answer
My other suggestion is to try glabels see here for some ideas: http://blog.worldlabel.com/2010/advanced-usage-with-glabels-labelscards-linuxgnu.html, glabels is a program designed mainly for labels, business cards and so on but custom layouts can be made with it so I think you could make a template for envelopes, its description says it supports mail merge from sources such as CSV files, vCards and Evolution data servers.