How to install a "pdf printer"?
If you've CUPS installed, you can easily add a "PDF Printer" by installing the cups-pdf package:
sudo apt-get install cups-pdf
or since Ubuntu 16.04
sudo apt-get install printer-driver-cups-pdf
The pdf printer provided by that package will "print" the resulting PDFs into the /home/[user]/PDF
directory.
Ubuntu ships with this functionality. Try opening gedit
(source: ubuntu.com) or another GUI text editor and clicking the print button:
When the Print dialog appears, select the "Print to File" printer and select a location for the PDF. After clicking Print, you should end up with a PDF file in that location containing an identical copy of what would have printed on a sheet of paper.
Whenever you print , there is already an option for "print to file". I hope you are talking about that.. if not then please elaborate your question