Gtk2::PaperSize(3) User Contributed Perl Documentation Gtk2::PaperSize(3)

Gtk2::PaperSize - wrapper for GtkPaperSize

Glib::Boxed
+----Gtk2::PaperSize

papersize = Gtk2::PaperSize->new ($name)

$name (string or undef)

papersize = Gtk2::PaperSize->new_custom ($name, $display_name, $width, $height, $unit)

  • $name (string)
  • $display_name (string)
  • $width (double)
  • $height (double)
  • $unit (Gtk2::Unit)

papersize = Gtk2::PaperSize->new_from_key_file ($key_file, $group_name)

  • $key_file (Glib::KeyFile)
  • $group_name (string)

May croak with a Glib::Error in $@ on failure.

Since: gtk+ 2.12

papersize = Gtk2::PaperSize->new_from_ppd ($ppd_name, $ppd_display_name, $width, $height)

  • $ppd_name (string)
  • $ppd_display_name (string)
  • $width (double)
  • $height (double)

double = $size->get_default_bottom_margin ($unit)

$unit (Gtk2::Unit)

double = $size->get_default_left_margin ($unit)

$unit (Gtk2::Unit)

double = $size->get_default_right_margin ($unit)

$unit (Gtk2::Unit)

double = $size->get_default_top_margin ($unit)

$unit (Gtk2::Unit)

string = $size->get_display_name

double = $size->get_height ($unit)

$unit (Gtk2::Unit)

$size2 (Gtk2::PaperSize)

string = $size->get_name

$include_custom (boolean)

Since: gtk+ 2.12

$size->set_size ($width, $height, $unit)

  • $width (double)
  • $height (double)
  • $unit (Gtk2::Unit)

$size->to_key_file ($key_file, $group_name)

  • $key_file (Glib::KeyFile)
  • $group_name (string)

Since: gtk+ 2.12

double = $size->get_width ($unit)

$unit (Gtk2::Unit)

  • 'pixel' / 'GTK_UNIT_PIXEL'
  • 'points' / 'GTK_UNIT_POINTS'
  • 'inch' / 'GTK_UNIT_INCH'
  • 'mm' / 'GTK_UNIT_MM'

Gtk2, Glib::Boxed

Copyright (C) 2003-2011 by the gtk2-perl team.

This software is licensed under the LGPL. See Gtk2 for a full notice.

2023-07-25 perl v5.38.0