logo top
Main Page   Widgets   Namespaces   Book  

Gtk::PageSetup Class Reference
[Printing]

Inheritance diagram for Gtk::PageSetup:

Inheritance graph
[legend]
List of all members.

Detailed Description

A PageSetup object stores the page size, orientation and margins.

You can get one of these from the page setup dialog and then pass it to the PrintOperation when printing. The benefit of splitting this out of the PrintSettings is that these affect the actual layout of the page, and thus need to be set long before the user prints.

The margins specified in this object are the "print margins", i.e. the parts of the page that the printer cannot print on. These are different from the layout margins that a word processor uses; they are typically used to determine the minimal size for the layout margins.

To obtain a PageSetup use PageSetup::create() to get the defaults, or use run_page_setup_dialog() to show the page setup dialog and receive the resulting page setup.

Since:
2.10


Public Member Functions

double get_bottom_margin (Unit unit) const
double get_left_margin (Unit unit) const
PageOrientation get_orientation () const
double get_page_height (Unit unit) const
double get_page_width (Unit unit) const
double get_paper_height (Unit unit) const
const PaperSize get_paper_size () const
PaperSize get_paper_size ()
double get_paper_width (Unit unit) const
double get_right_margin (Unit unit) const
double get_top_margin (Unit unit) const
const GtkPageSetup* gobj () const
 Provides access to the underlying C GObject.
GtkPageSetup* gobj ()
 Provides access to the underlying C GObject.
GtkPageSetup* gobj_copy ()
 Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs.
void set_bottom_margin (double margin, Unit unit)
void set_left_margin (double margin, Unit unit)
void set_orientation (PageOrientation orientation)
void set_paper_size (const PaperSize& paper_size)
void set_paper_size_and_default_margins (const PaperSize& paper_size)
void set_right_margin (double margin, Unit unit)
void set_top_margin (double margin, Unit unit)
virtual ~PageSetup ()

Static Public Member Functions

static Glib::RefPtr<PageSetupcreate ()

Protected Member Functions

 PageSetup ()

Related Functions

(Note that these are not member functions.)

Glib::RefPtr<Gtk::PageSetupwrap (GtkPageSetup* object, bool take_copy=false)


Constructor & Destructor Documentation

virtual Gtk::PageSetup::~PageSetup (  )  [virtual]
 

Gtk::PageSetup::PageSetup (  )  [protected]
 


Member Function Documentation

static Glib::RefPtr<PageSetup> Gtk::PageSetup::create (  )  [static]
 

double Gtk::PageSetup::get_bottom_margin ( Unit  unit  )  const
 

double Gtk::PageSetup::get_left_margin ( Unit  unit  )  const
 

PageOrientation Gtk::PageSetup::get_orientation (  )  const
 

double Gtk::PageSetup::get_page_height ( Unit  unit  )  const
 

double Gtk::PageSetup::get_page_width ( Unit  unit  )  const
 

double Gtk::PageSetup::get_paper_height ( Unit  unit  )  const
 

const PaperSize Gtk::PageSetup::get_paper_size (  )  const
 

PaperSize Gtk::PageSetup::get_paper_size (  ) 
 

double Gtk::PageSetup::get_paper_width ( Unit  unit  )  const
 

double Gtk::PageSetup::get_right_margin ( Unit  unit  )  const
 

double Gtk::PageSetup::get_top_margin ( Unit  unit  )  const
 

const GtkPageSetup* Gtk::PageSetup::gobj (  )  const [inline]
 

Provides access to the underlying C GObject.

Reimplemented from Glib::ObjectBase.

GtkPageSetup* Gtk::PageSetup::gobj (  )  [inline]
 

Provides access to the underlying C GObject.

Reimplemented from Glib::ObjectBase.

GtkPageSetup* Gtk::PageSetup::gobj_copy (  ) 
 

Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs.

void Gtk::PageSetup::set_bottom_margin ( double  margin,
Unit  unit
 

void Gtk::PageSetup::set_left_margin ( double  margin,
Unit  unit
 

void Gtk::PageSetup::set_orientation ( PageOrientation  orientation  ) 
 

void Gtk::PageSetup::set_paper_size ( const PaperSize paper_size  ) 
 

void Gtk::PageSetup::set_paper_size_and_default_margins ( const PaperSize paper_size  ) 
 

void Gtk::PageSetup::set_right_margin ( double  margin,
Unit  unit
 

void Gtk::PageSetup::set_top_margin ( double  margin,
Unit  unit
 


Friends And Related Function Documentation

Glib::RefPtr<Gtk::PageSetup> wrap ( GtkPageSetup*  object,
bool  take_copy = false
[related]
 

Parameters:
object The C instance
take_copy False if the result should take ownership of the C instance. True if it should take a new copy or ref.
Returns:
A C++ instance that wraps this C instance.


The documentation for this class was generated from the following file:
Generated for gtkmm 2.4 by Doxygen 1.4.6 © 1997-2001