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

Inti::Gtk::Layout Class Reference

A GtkLayout C++ wrapper class. More...

#include <inti/gtk/layout.h>

Inheritance diagram for Inti::Gtk::Layout:

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
Child Property Proxies
Signal Proxies

Protected Member Functions

Constructors
Signal Handlers

Detailed Description

A GtkLayout C++ wrapper class.

Layout is similar to DrawingArea in that it's a "blank slate" and doesn't do anything but paint a blank background by default. It's different in that it supports scrolling natively (you can add it to a ScrolledWindow), and it can contain child widgets, since it's a Container. However if you're just going to draw, a DrawingArea is a better choice since it has lower overhead. When handling expose events on a Layout, you must draw to bin_window(), rather than to Gtk::Widget::get_window() as you would for a drawing area.


Constructor & Destructor Documentation

Inti::Gtk::Layout::Layout GtkLayout *  layout,
bool  reference = false
[explicit, protected]
 

Construct a new Layout from an existing GtkLayout.

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

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

Inti::Gtk::Layout::Layout Adjustment hadjustment,
Adjustment vadjustment
 

Construct a new Layout with the specified horizontal and vertical adjustments.

Parameters:
hadjustment The Adjustment for the horizontal position.
vadjustment The Adjustment for the vertical position.


Member Function Documentation

Gdk::Window* Inti::Gtk::Layout::bin_window  )  const
 

Returns the Gdk::Window to draw to in response to an expose event.

Note layout widgets should not draw to Gtk::Widget::get_window().

Adjustment* Inti::Gtk::Layout::get_hadjustment  )  const
 

Get the Adjustment for the horizontal position.

Returns:
The Adjustment used for communication between the horizontal scrollbar and layout.

This method should only be called after the layout has been placed in a ScrolledWindow or otherwise configured for scrolling (see ScrolledWindow, Scrollbar, Adjustment for details).

void Inti::Gtk::Layout::get_size unsigned int *  width,
unsigned int *  height
 

Gets the size that has been set on the layout, and that determines the total extents of the layout's scrollbar area (see set_size()).

Parameters:
width The location to store the width set on layout, or null.
height The location to store the height set on layout, or null.

Adjustment* Inti::Gtk::Layout::get_vadjustment  )  const
 

Get the Adjustment for the vertical position.

Returns:
The Adjustment used for communication between the vertical scrollbar and layout.

This method should only be called after the layout has been placed in a ScrolledWindow or otherwise configured for scrolling (see ScrolledWindow, Scrollbar, Adjustment for details).

void Inti::Gtk::Layout::move Widget child_widget,
int  x,
int  y
 

Move a current child of the Layout to a new position.

Parameters:
child_widget The child of the Layout to move.
x The X position to move to.
y The Y position to move to.

virtual void Inti::Gtk::Layout::on_set_scroll_adjustments Adjustment hadjustment,
Adjustment vadjustment
[protected, virtual]
 

Called when a layout is added to a scrolling aware parent.

Parameters:
hadjustment The horizontal adjustment.
vadjustment The vertical adjustment.

void Inti::Gtk::Layout::put Widget child_widget,
int  x,
int  y
 

Add child_widget to the Layout, at position (x,y); the Layout becomes the new parent container of child_widget.

Parameters:
child_widget The child widget to add.
x The X position of child widget.
y The Y position of child widget.

void Inti::Gtk::Layout::set_hadjustment Adjustment adjustment  ) 
 

Sets the horizontal scroll adjustment for the layout.

Parameters:
adjustment The new horizontal scroll adjustment.

See ScrolledWindow, Scrollbar, Adjustment for details.

void Inti::Gtk::Layout::set_size unsigned int  width,
unsigned int  height
 

Sets the size of the scrollable area of the layout.

Parameters:
width The width of entire scrollable area.
height The height of entire scrollable area.

void Inti::Gtk::Layout::set_vadjustment Adjustment adjustment  ) 
 

Sets the vertical scroll adjustment for the layout.

Parameters:
adjustment The new vertical scroll adjustment.

See ScrolledWindow, Scrollbar, Adjustment for details.


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


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