gtk.Misc widget is an
abstract widget used to derive subclasses which have alignment and padding
attributes. The horizontal and vertical padding attributes allow extra space
to be added around the widget. The horizontal and vertical alignment
attributes enable the widget to be positioned within its allocated area. The
alignment values represent the fraction of available free space (allocation
minus the widget size) to place to the left or above the widget for x and y
alignment respectively. 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 have no effect.
|the horizontal alignment|
|the vertical alignment|
set_alignment() method sets the
alignment of the widget in its allocated space.
sets the fraction (0.0-1.0) of free space (horizontal allocation minus
widget width) to place to the left of the widget.
yalign sets the fraction (0.0-1.0) of free space
(vertical allocation minus widget height) to place above the widget.
|a tuple containing the X and Y alignments of the widget|
get_alignment() method returns a
tuple containing the X and Y alignments of the widget within its allocation.
|the amount of space to add on the left and right of the widget, in pixels.|
|the amount of space to add on the top and bottom of the widget, in pixels.|
set_padding() method sets the
amount of space to add around the widget. The
value specifies the number of pixels of padding to add to the left and right
of the widget. The
yalign value specifies the number
of pixels to add above and below the widget.
|a tuple containing the horizontal and vertical padding in pixels for the widget.|
get_padding() method returns a
tuple containing the padding in the horizontal and vertical directions of
the widget. See
© manpagez.com 2000-2022 Individual documents may contain additional copyright information.