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 _getGType() static nothrow
GType _gType() @property nothrow
AspectFrame self() nothrowReturns `this`, for use in `with` statements.
AspectFrameGidBuilder builder() static nothrowGet builder for [gtk.aspect_frame.AspectFrame] Returns: New builder object
bool obeyChild() @property nothrow
void obeyChild(bool propval) @property nothrow
float ratio() @property nothrow
void ratio(float propval) @property nothrow
float xalign() @property nothrow
void xalign(float propval) @property nothrow
float yalign() @property nothrow
void yalign(float propval) @property nothrow
void set(float xalign, float yalign, float ratio, bool obeyChild) nothrowSet 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.

Fluent builder implementation template for gtk.aspect_frame.AspectFrame

Methods
T obeyChild(bool propval) nothrow
T ratio(float propval) nothrow
T xalign(float propval) nothrow
T yalign(float propval) nothrow

Fluent builder for gtk.aspect_frame.AspectFrame

Methods
AspectFrame build() nothrowCreate object from builder. Returns: New object