vdk 2.4.0
|
Containers base class. More...
#include <widcontain.h>
Containers base class.
This class provides a container widget, common class for specialized containers such as VDKBox, VDKTable etc. User should not construct explicitely this kind of object.
void VDKObjectContainer::Add | ( | VDKObject * | obj, |
int | justify = l_justify , |
||
int | fill = TRUE , |
||
int | expand = TRUE , |
||
int | padding = 0 |
||
) | [virtual] |
Add an object.
Reimplemented from VDKObject.
Reimplemented in VDKBox, VDKEventBox, VDKFixed, VDKFrame, VDKHandleBox, VDKMenu, VDKMenubar, VDKNotebook, VDKPaned, VDKRadioButtonGroup, VDKScrolled, VDKTable, and VDKToolbar.
int VDKObjectContainer::BorderWidth | ( | int | w = -1 | ) | [inline] |
Sets container border width
w | returns border width if is < 0 |
VDKObject * VDKObjectContainer::FindTag | ( | int | tag | ) |
Find an object with Tag==tag, NULL if fails
tag | value to be searched |
void VDKObjectContainer::ForEachDo | ( | void(*)(VDKObject *) | action | ) |
Apply user defined functions to each contained object
void VDKObjectContainer::RemoveObject | ( | VDKObject * | obj | ) | [inline] |
Remove an object from container, object will be destroyed
obj | object to be removed |
void VDKObjectContainer::RemoveObjectFromContainer | ( | VDKObject * | obj | ) | [virtual] |
This function will remove an object from a container without destroying it.
obj | object to be removed Tip: should be used to reparent an widget, or it will leak. Example: // remove from source container // referencing it otherwise will be destroyed by gtk+ source->RemoveObjectFromContainer(widget); // add to target container target->Add(widget); // set target as parent to redirect signal flow widget->Parent(target); // unref widget again (or it will leak) gtk_widget_unref(widget->Widget()); |
void VDKObjectContainer::RemoveObjects | ( | ) |
Remove all objects from container destroying them