#include <container.h>
Inherits TQObject.
|
| enum | LayoutType {
NoLayout =0
, HBox
, VBox
, Grid
,
HFlow
, VFlow
, HSplitter
, VSplitter
} |
| |
This class makes a container out of any TQWidget.
You can then create child widgets, and the background is dotted. A class to make a container from any widget
Definition at line 73 of file container.h.
◆ LayoutType
| enum KFormDesigner::Container::LayoutType |
◆ Container()
| Container::Container |
( |
Container * |
toplevel, |
|
|
TQWidget * |
container, |
|
|
TQObject * |
parent = 0, |
|
|
const char * |
name = 0 |
|
) |
| |
◆ ~Container()
| Container::~Container |
( |
| ) |
|
|
virtual |
◆ createBoxLayout()
Internal function to create a HBoxLayout or VBoxLayout for this container. list is a subclass of TQObjectList that can sort widgets following their position (such as HorWidgetList or VerWidgetList).
Definition at line 655 of file container.cpp.
◆ createFlowLayout()
| void Container::createFlowLayout |
( |
| ) |
|
|
protected |
◆ createGridLayout()
| void Container::createGridLayout |
( |
bool |
testOnly = false | ) |
|
|
protected |
Internal function to create a GridLayout. if testOnly is true, the layout is simulated, and only the widget's grid info aris filled.
Definition at line 733 of file container.cpp.
◆ deleteWidget
| void Container::deleteWidget |
( |
TQWidget * |
w | ) |
|
|
slot |
◆ drawConnection()
| void Container::drawConnection |
( |
TQMouseEvent * |
mev | ) |
|
|
protected |
Drawing functions used by eventFilter.
Definition at line 944 of file container.cpp.
◆ drawCopiedWidgetRect()
| void Container::drawCopiedWidgetRect |
( |
TQMouseEvent * |
mev | ) |
|
|
protected |
◆ drawInsertRect()
| void Container::drawInsertRect |
( |
TQMouseEvent * |
mev, |
|
|
TQObject * |
s |
|
) |
| |
|
protected |
◆ drawSelectionRect()
| void Container::drawSelectionRect |
( |
TQMouseEvent * |
mev | ) |
|
|
protected |
◆ eventFilter()
| bool Container::eventFilter |
( |
TQObject * |
o, |
|
|
TQEvent * |
e |
|
) |
| |
|
virtual |
This is the main function of Container, which filters the event sent to the watched widget.
It takes care of drawing the background and the insert rect, of creating the new child widgets, of moving the widgets and pop up a menu when right-clicking.
Definition at line 150 of file container.cpp.
◆ form()
| Form * KFormDesigner::Container::form |
( |
| ) |
const |
|
inline |
◆ layout()
| TQLayout * KFormDesigner::Container::layout |
( |
| ) |
const |
|
inline |
- Returns
- a pointer to the TQLayout of this Container, or 0 if there is not.
Definition at line 107 of file container.h.
◆ layoutMargin()
| int KFormDesigner::Container::layoutMargin |
( |
| ) |
|
|
inline |
◆ layoutSpacing()
| int KFormDesigner::Container::layoutSpacing |
( |
| ) |
|
|
inline |
◆ layoutType()
| LayoutType KFormDesigner::Container::layoutType |
( |
| ) |
const |
|
inline |
- Returns
- the type of the layout associated to this Container's widget (see LayoutType enum).
Definition at line 110 of file container.h.
◆ layoutTypeToString()
| TQString Container::layoutTypeToString |
( |
int |
type | ) |
|
|
static |
- Returns
- the string representing the layoutType type.
Definition at line 918 of file container.cpp.
◆ moveSelectedWidgetsBy()
| void Container::moveSelectedWidgetsBy |
( |
int |
realdx, |
|
|
int |
realdy, |
|
|
TQMouseEvent * |
mev = 0 |
|
) |
| |
|
protected |
◆ objectTree()
◆ reloadLayout
| void Container::reloadLayout |
( |
| ) |
|
|
slot |
Recreates the Container layout. Calls this when a widget has been moved or added to update the layout.
Definition at line 647 of file container.cpp.
◆ setForm()
◆ setLayout()
| void Container::setLayout |
( |
LayoutType |
type | ) |
|
◆ setLayoutMargin()
| void KFormDesigner::Container::setLayoutMargin |
( |
int |
margin | ) |
|
|
inline |
◆ setLayoutSpacing()
| void KFormDesigner::Container::setLayoutSpacing |
( |
int |
spacing | ) |
|
|
inline |
◆ setObjectTree()
◆ setSelectedWidget
| void Container::setSelectedWidget |
( |
TQWidget * |
selected, |
|
|
bool |
add, |
|
|
bool |
dontRaise = false, |
|
|
bool |
moreWillBeSelected = false |
|
) |
| |
|
slot |
Sets selected to be the selected widget of this container (and so of the Form). If add is true, the formerly selected widget is still selected, and the new one is just added. If false, selected replace the actually selected widget. If dontRaise is true, then the widget selected (and its parent) won't be raised (eg when you select widget in ObjectTreeView). - See also
- Form::setSelectedWidget()
Definition at line 539 of file container.cpp.
◆ stopInlineEditing()
| void KFormDesigner::Container::stopInlineEditing |
( |
| ) |
|
|
inline |
Stops the inline editing of the current widget (as when you click on another widget or press Esc).
Definition at line 137 of file container.h.
◆ stringToLayoutType()
| Container::LayoutType Container::stringToLayoutType |
( |
const TQString & |
name | ) |
|
|
static |
- Returns
- the LayoutType (an int) for a given layout name.
Definition at line 932 of file container.cpp.
◆ toplevel()
◆ unSelectWidget
| void Container::unSelectWidget |
( |
TQWidget * |
w | ) |
|
|
slot |
Unselects the widget w. The widget is removed from the Form's list and its resizeHandles are removed.
Definition at line 554 of file container.cpp.
◆ widget()
| TQWidget * KFormDesigner::Container::widget |
( |
| ) |
const |
|
inline |
- Returns
- The watched widget.
Definition at line 94 of file container.h.
◆ widgetDeleted
| void Container::widgetDeleted |
( |
| ) |
|
|
protectedslot |
This slot is called when the watched widget is deleted. Deletes the Container too.
Definition at line 583 of file container.cpp.
◆ DeleteWidgetCommand
◆ FormIO
◆ InsertWidgetCommand
◆ PasteWidgetCommand
The documentation for this class was generated from the following files:
|