gtk.aspect_frame

Module for [AspectFrame] class

Types 3

The #GtkAspectFrame is useful when you want pack a widget so that it can resize but always retains the same aspect ratio. For instance, one might be drawing a small preview of a larger image. #GtkAspectFrame derives from #GtkFrame, so it can draw a label and a frame around the child. The frame will be “shrink-wrapped” to the size of the child.

CSS nodes

GtkAspectFrame uses a CSS node with name frame.

Methods
GType _gType() @property
AspectFrame self()Returns `this`, for use in `with` statements.
AspectFrameGidBuilder builder()Get builder for [gtk.aspect_frame.AspectFrame] Returns: New builder object
bool obeyChild() @property
void obeyChild(bool propval) @property
float ratio() @property
void ratio(float propval) @property
float xalign() @property
void xalign(float propval) @property
float yalign() @property
void yalign(float propval) @property
void set(float xalign, float yalign, float ratio, bool obeyChild)Set parameters for an existing #GtkAspectFrame.
Constructors
this(void * ptr, Flag!"Take" take)
this(string label, float xalign, float yalign, float ratio, bool obeyChild)Create a new #GtkAspectFrame.
Methods
T obeyChild(bool propval)
T ratio(float propval)
T xalign(float propval)
T yalign(float propval)

Fluent builder for [gtk.aspect_frame.AspectFrame]