| Extracted from Pike v7.8 release 700 at 2013-06-08.

[Top]
GTK2
GTK2.Misc

# Class GTK2.Misc

Description

  The GTK2.Misc widget is an abstract widget which is not useful itself, but is used to derive subclasses which have alignment and padding attributes.

  The horizontal and vertical padding attributes allows extra space to be added around the widget.

  The horizontal and vertical alignment attributes enable the widget to be positioned within its allocated area. Note that if the widget is added to a container in such a way that it expands automatically to fill its allocated area, the alignment settings will not alter the widgets position.

  `GTK2.Vbox(0,0)->add(GTK2.Label("Label"))->set_size_request(100,20)`

  `GTK2.Vbox(0,0)->add(GTK2.Label("Label")->set_alignment(1.0,0.0))->set_size_request(100,20)`

  `GTK2.Vbox(0,0)->add(GTK2.Label("Label")->set_alignment(0.0,0.0))->set_size_request(100,20)`

  Properties: float xalign The horizontal alignment, from 0 (left) to 1 (right). int xpad The amount of space to add on the left and right of the widget, in pixels. float yalign The vertical alignment, from 0 (top) to 1 (bottom). int ypad The amount of space to add on the top and bottom of the widget, in pixels.

Inherit Widget

  inherit GTK2.Widget : Widget