Mapper  0.9.0
API documentation
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
OpenOrienteering::MapPrinterPageFormat Class Reference

The MapPrinterPageFormat is a complete description of page properties. More...

#include <map_printer.h>

Collaboration diagram for OpenOrienteering::MapPrinterPageFormat:
Collaboration graph
[legend]

Public Types

enum  Orientation { Portrait, Landscape }
 Copy of QPrinter::Orientation because QPrinter is not available for Android. More...
 

Public Member Functions

 MapPrinterPageFormat (QSizeF page_rect_size=QSizeF(100.0, 100.0), qreal margin=5.0, qreal overlap=5.0)
 Constructs a new page format. More...
 
 MapPrinterPageFormat (const QPrinter &printer, qreal overlap=5.0)
 Constructs a new page format, initialized from the given printer's settings. More...
 

Static Public Member Functions

static MapPrinterPageFormat fromDefaultPrinter ()
 Returns a page format initialized from the default printer's settings. More...
 

Public Attributes

QPageSize::PageSizeId page_size
 The nominal page size. More...
 
Orientation orientation
 The orientation of the paper. More...
 
QRectF page_rect
 The printable page rectangle in mm. More...
 
QSizeF paper_dimensions
 The total dimensions of the page in mm. More...
 
qreal h_overlap
 The horizontal overlap in mm of pages when the output covers muliple pages. More...
 
qreal v_overlap
 The vertival overlap in mm of pages when the output covers muliple pages. More...
 

Detailed Description

The MapPrinterPageFormat is a complete description of page properties.

Member Enumeration Documentation

◆ Orientation

Copy of QPrinter::Orientation because QPrinter is not available for Android.

Enumerator
Portrait 
Landscape 

Constructor & Destructor Documentation

◆ MapPrinterPageFormat() [1/2]

OpenOrienteering::MapPrinterPageFormat::MapPrinterPageFormat ( QSizeF  page_rect_size = QSizeF(100.0, 100.0),
qreal  margin = 5.0,
qreal  overlap = 5.0 
)

Constructs a new page format.

The format is initialized as a custom page format with a page rectangle of the given size, surrounded by the given margin (in mm).

◆ MapPrinterPageFormat() [2/2]

OpenOrienteering::MapPrinterPageFormat::MapPrinterPageFormat ( const QPrinter printer,
qreal  overlap = 5.0 
)

Constructs a new page format, initialized from the given printer's settings.

Member Function Documentation

◆ fromDefaultPrinter()

MapPrinterPageFormat OpenOrienteering::MapPrinterPageFormat::fromDefaultPrinter ( )
static

Returns a page format initialized from the default printer's settings.

When building without Qt Print Support, returns a default constructed page format.

Member Data Documentation

◆ h_overlap

qreal OpenOrienteering::MapPrinterPageFormat::h_overlap

The horizontal overlap in mm of pages when the output covers muliple pages.

◆ orientation

Orientation OpenOrienteering::MapPrinterPageFormat::orientation

The orientation of the paper.

◆ page_rect

QRectF OpenOrienteering::MapPrinterPageFormat::page_rect

The printable page rectangle in mm.

◆ page_size

QPageSize::PageSizeId OpenOrienteering::MapPrinterPageFormat::page_size

The nominal page size.

◆ paper_dimensions

QSizeF OpenOrienteering::MapPrinterPageFormat::paper_dimensions

The total dimensions of the page in mm.

◆ v_overlap

qreal OpenOrienteering::MapPrinterPageFormat::v_overlap

The vertival overlap in mm of pages when the output covers muliple pages.


The documentation for this class was generated from the following files: