kexi

KFormDesigner::ObjectTreeView Class Reference

#include <objecttreeview.h>

Inherits KListView.

List of all members.


Detailed Description

A graphical view of Form's ObjectTree. This is a KListView which represents an item for each widget in the form. The actually selected widget is written bold and selected. Clicking on a list item selects the corresponding widget in the Form.

Definition at line 67 of file objecttreeview.h.


Public Slots

void setSelectedWidget (QWidget *w, bool add=false)
void addItem (ObjectTreeItem *item)
void removeItem (ObjectTreeItem *item)
void renameItem (const QCString &oldname, const QCString &newname)

Public Member Functions

 ObjectTreeView (QWidget *parent=0, const char *name=0, bool tabStop=false)
virtual QSize sizeHint () const
void setForm (Form *form)
QString iconNameForClass (const QCString &classname)

Protected Slots

void displayContextMenu (KListView *list, QListViewItem *item, const QPoint &p)
void slotColumnSizeChanged (int)
void slotSelectionChanged ()
void slotBeforeFormDestroyed ()

Protected Member Functions

ObjectTreeViewItemloadTree (ObjectTreeItem *item, ObjectTreeViewItem *parent)
ObjectTreeViewItemfindItem (const QString &name)

Friends

class TabStopDialog

Member Function Documentation

void ObjectTreeView::setForm ( Form form  ) 

Sets form as the current Form in the list. The list will automatically be filled with an item for each widget in the Form, and selection will be synced. Nothing happens if form is already the current Form.

Definition at line 323 of file objecttreeview.cpp.

QString ObjectTreeView::iconNameForClass ( const QCString &  classname  ) 

Returns:
the pixmap name for a given class, to be shown next to the widget name.

Definition at line 201 of file objecttreeview.cpp.

void ObjectTreeView::setSelectedWidget ( QWidget *  w,
bool  add = false 
) [slot]

Sets the widget w as selected item, so it will be written bold. It is added to current selection if add is true.

Definition at line 242 of file objecttreeview.cpp.

void ObjectTreeView::addItem ( ObjectTreeItem item  )  [slot]

Adds the ObjectTreeItem item in the list, with the appropriate parent.

Definition at line 291 of file objecttreeview.cpp.

void ObjectTreeView::removeItem ( ObjectTreeItem item  )  [slot]

Removess the ObjectTreeItem item from the list.

Definition at line 303 of file objecttreeview.cpp.

void ObjectTreeView::renameItem ( const QCString &  oldname,
const QCString &  newname 
) [slot]

Just renames the list item from oldname to newname.

Definition at line 312 of file objecttreeview.cpp.

void ObjectTreeView::displayContextMenu ( KListView *  list,
QListViewItem *  item,
const QPoint &  p 
) [protected, slot]

This slot is called when the user right-click a list item. The widget context menu is shown, as inisde the Form.

Definition at line 213 of file objecttreeview.cpp.

void ObjectTreeView::slotSelectionChanged (  )  [protected, slot]

The selected list item has changed, so we emit a signal to update the Form.

Definition at line 274 of file objecttreeview.cpp.

void ObjectTreeView::slotBeforeFormDestroyed (  )  [protected, slot]

Called before Form object is destroyed.

Definition at line 351 of file objecttreeview.cpp.

ObjectTreeViewItem * ObjectTreeView::loadTree ( ObjectTreeItem item,
ObjectTreeViewItem parent 
) [protected]

Internal function to fill the list.

Definition at line 357 of file objecttreeview.cpp.

ObjectTreeViewItem * ObjectTreeView::findItem ( const QString &  name  )  [protected]

Returns:
The item whose name is name.

Definition at line 226 of file objecttreeview.cpp.


The documentation for this class was generated from the following files:
KDE Home | KDE Accessibility Home | Description of Access Keys