Lines Matching refs:page

1 page.title=Printing Custom Documents
29 <p>For some applications, such as drawing apps, page layout apps and other apps that focus on
32 precise control of everything that goes into a page, including fonts, text flow, page breaks,
37 communicate with the print framework, adjust to printer settings, draw page elements and
87 printers with different output capabilities, different page sizes, or different page orientations.
104 user changes a print setting which impacts the output, such as a different page size,
105 or page orientation, giving your application an opportunity to compute the layout of the
131 number of pages for print job, given information about the printed page size.
146 // Create a new PdfDocument with the requested page attributes
200 // Six items per page in landscape orientation
218 requested page of content to a multi-page PDF document file. When this process is complete, you
251 // Iterate over each page of the document,
254 // Check to see if this page is in the output range.
257 // is used to compute the next output page index.
259 PdfDocument.Page page = mPdfDocument.startPage(i);
269 // Draw page content for printing
270 drawPage(page);
272 // Rendering is complete, so page can be finalized.
273 mPdfDocument.finishPage(page);
296 <p>This sample delegates rendering of PDF page content to <code>drawPage()</code>
310 performing the page rendering and writing operations on a separate thread, for example
326 object to draw elements on an PDF page, similar to drawing on an activity layout. You can draw
327 elements on the printed page using the {@link android.graphics.Canvas} draw methods. The following
328 example code demonstrates how to draw some simple elements on a PDF document page using these
332 private void drawPage(PdfDocument.Page page) {
333 Canvas canvas = page.getCanvas();
352 <p>When using {@link android.graphics.Canvas} to draw on a PDF page, elements are specified in
354 of elements on the page. For positioning of drawn elements, the coordinate system starts at 0,0
355 for the top left corner of the page.</p>
360 physical piece of paper. Make sure that you account for the unprintable edges of the page when