The pdfpages package allows users to easily include individual pages from a PDF file, entire PDF documents, and even multiple PDF documents into a new document. While this functionality was previously possible, it was not as convenient and of the same quality as offered by the pdfpages package.
Another reason to explore this package is that currently, PDF files are predominantly set using LaTeX. pdfpages provides a range of additional options beyond simple insertion of PDF pages into another document.
When including the package, usually no option needs to be set. The package has three options: final (default setting), draft, and enable-survey (experimental extension). Therefore, simply using \usepackage{pdfpages}
is sufficient for inclusion.
The three most important settings are pages, nup, and landscape.
Determines which pages and in what order they are inserted.
% Include all pages \includepdf[pages=-]{File Name} % Include all pages in reverse order \includepdf[pages=last-1]{File Name} % Include pages from ... to ... \includepdf[pages={from-to}]{File Name} % Include specific pages X, Y, and Z \includepdf[pages={X,Y,Z}]{File Name} % Insert a blank page between X and Y \includepdf[pages={X,{},Y}]{File Name} % Mix different page selections \includepdf[pages={from-to, X,Y,{},Z}]{File Name} % If no value is set for pages, only the first page is taken automatically
Allows multiple pages of the included document to be placed on one page.
% One column and two rows \includepdf[pages=-, nup=1x2]{File Name} % Two columns and one row \includepdf[pages=-, nup=2x1]{File Name}
By default, it is assumed that the pages to be included are in portrait format. To include pages in landscape format, use the landscape option.
\includepdf[landscape=true,pages=-]{File Name}
Apart from the three main settings, there are many others, such as frame and delta, which add a frame around the pages or determine the spacing between pages. For example, to create handouts from slides created with the Beamer class:
\includepdf[pages=-,nup=2x2,frame=true,delta=3mm 3mm]{Handout-classic}