Reference Manual
Inti Logo
Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Namespace Members | Compound Members | File Members

Inti::Gtk::AspectFrame Class Reference

A GtkAspectFrame C++ wrapper class. More...

#include <inti/gtk/aspectframe.h>

Inheritance diagram for Inti::Gtk::AspectFrame:

Inti::Gtk::Frame Inti::Gtk::Bin Inti::Gtk::Container Inti::Gtk::Widget Inti::Gtk::Object Inti::Atk::Implementor Inti::G::Object Inti::G::TypeInterface Inti::G::TypeInstance Inti::MemoryHandler Inti::G::TypeInstance Inti::ReferencedBase Inti::ReferencedBase List of all members.

Public Member Functions

Constructors
Accessors
Methods
Property Proxies

Protected Member Functions

Constructors

Detailed Description

A GtkAspectFrame C++ wrapper class.

The AspectFrame 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. AspectFrame derives from Frame, so it can draw a label and a frame around the child. The frame will be "shrink-wrapped" to the size of the child.


Constructor & Destructor Documentation

Inti::Gtk::AspectFrame::AspectFrame GtkAspectFrame *  aspect_frame,
bool  reference = false
[explicit, protected]
 

Construct a new AspectFrame from an existing GtkAspectFrame.

Parameters:
aspect_frame A pointer to a GtkAspectFrame.
reference Set false if the initial reference count is floating, set true if it's not.

The aspect_frame can be a newly created GtkAspectFrame or an existing GtkAspectFrame. (see G::Object::Object).

Inti::Gtk::AspectFrame::AspectFrame float  xalign,
float  yalign
 

Construct an AspectFrame with the specified xalign and yalign values.

Parameters:
xalign The horizontal alignment of the child within the allocation of the AspectFrame; this ranges from 0.0 (left aligned) to 1.0 (right aligned).
yalign The vertical alignment of the child within the allocation of the AspectFrame. This ranges from 0.0 (left aligned) to 1.0 (right aligned).

This constructor takes the aspect ratio from the requistion of the child. This is the same as setting obey_child to true.

Inti::Gtk::AspectFrame::AspectFrame float  xalign,
float  yalign,
float  ratio
 

Construct an AspectFrame with the specified xalign, yalign and ratio values.

Parameters:
xalign The horizontal alignment of the child within the allocation of the AspectFrame; this ranges from 0.0 (left aligned) to 1.0 (right aligned).
yalign The vertical alignment of the child within the allocation of the AspectFrame. This ranges from 0.0 (left aligned) to 1.0 (right aligned).
ratio The desired aspect ratio.

This constructor takes the aspect ratio from ratio and sets obey_child to false.

Inti::Gtk::AspectFrame::AspectFrame const String label,
float  xalign,
float  yalign,
float  ratio
 

Construct a labelled AspectFrame with the specified xalign, yalign and ratio values.

Parameters:
label The label text.
xalign The horizontal alignment of the child within the allocation of the AspectFrame; this ranges from 0.0 (left aligned) to 1.0 (right aligned).
yalign The vertical alignment of the child within the allocation of the AspectFrame. This ranges from 0.0 (left aligned) to 1.0 (right aligned).
ratio The desired aspect ratio.

This constructor takes the aspect ratio from ratio and sets obey_child to false.


Member Function Documentation

void Inti::Gtk::AspectFrame::set float  xalign,
float  yalign,
float  ratio,
bool  obey_child
 

Sets the parameters for an existing AspectFrame.

Parameters:
xalign The horizontal alignment of the child within the allocation of the AspectFrame; this ranges from 0.0 (left aligned) to 1.0 (right aligned).
yalign The vertical alignment of the child within the allocation of the AspectFrame. This ranges from 0.0 (left aligned) to 1.0 (right aligned).
ratio The desired aspect ratio.
obey_child If true, ratio is ignored, and the aspect ratio is taken from the requistion of the child.


The documentation for this class was generated from the following file: Main Page - Footer


Generated on Sun Sep 14 20:08:13 2003 for Inti by doxygen 1.3.2 written by Dimitri van Heesch, © 1997-2002