KFormDesigner::WidgetLibrary Class Reference
#include <widgetlibrary.h>
Detailed Description
This class searches for factories and provides KActions for widget creation.Every widget can be located using this library. You call WidgetLibrary functions instead of calling directly factories. See WidgetFactory for a description of the functions.
Definition at line 56 of file widgetlibrary.h.
Signals | |
| void | prepareInsert (const QCString &c) |
Public Member Functions | |
| WidgetLibrary (QObject *parent=0, const QStringList &supportedFactoryGroups=QStringList()) | |
| virtual | ~WidgetLibrary () |
| ActionList | createWidgetActions (KXMLGUIClient *client, KActionCollection *parent, QObject *receiver, const char *slot) |
| creates actions for widget creating | |
| void | addCustomWidgetActions (KActionCollection *col) |
| QWidget * | createWidget (const QCString &classname, QWidget *parent, const char *name, Container *c, int options=WidgetFactory::DefaultOptions) |
| searches the right factory and creates a widget. | |
| bool | createMenuActions (const QCString &c, QWidget *w, QPopupMenu *menu, KFormDesigner::Container *container) |
| WidgetFactory::CreateWidgetOptions | showOrientationSelectionPopup (const QCString &classname, QWidget *parent, const QPoint &pos) |
| Shows orientation selection popup. | |
| QString | internalProperty (const QCString &classname, const QCString &property) |
| QString | displayName (const QCString &classname) |
| QString | namePrefix (const QCString &classname) |
| QString | textForWidgetName (const QCString &name, const QCString &className) |
| QCString | classNameForAlternate (const QCString &classname) |
| QString | iconName (const QCString &classname) |
| QString | includeFileName (const QCString &classname) |
| QString | savingName (const QCString &classname) |
| bool | startEditing (const QCString &classname, QWidget *w, Container *container) |
| bool | previewWidget (const QCString &classname, QWidget *widget, Container *container) |
| bool | clearWidgetContent (const QCString &classname, QWidget *w) |
| bool | saveSpecialProperty (const QCString &classname, const QString &name, const QVariant &value, QWidget *w, QDomElement &parentNode, QDomDocument &parent) |
| bool | readSpecialProperty (const QCString &classname, QDomElement &node, QWidget *w, ObjectTreeItem *item) |
| bool | isPropertyVisible (const QCString &classname, QWidget *w, const QCString &property, bool multiple=false, bool isTopLevel=false) |
| QValueList< QCString > | autoSaveProperties (const QCString &classname) |
| WidgetInfo * | widgetInfoForClassName (const char *classname) |
| WidgetFactory * | factoryForClassName (const char *className) |
| WidgetFactory * | factory (const char *factoryName) const |
| bool | advancedPropertiesVisible () const |
| void | setAdvancedPropertiesVisible (bool set) |
| QString | propertyDescForName (WidgetInfo *winfo, const QCString &propertyName) |
| QString | propertyDescForValue (WidgetInfo *winfo, const QCString &name) |
| void | setPropertyOptions (WidgetPropertySet &list, const WidgetInfo &winfo, QWidget *w) |
| bool | propertySetShouldBeReloadedAfterPropertyChange (const QCString &classname, QWidget *w, const QCString &property) |
Protected Member Functions | |
| void | loadFactoryWidgets (WidgetFactory *f) |
| Adds a factory to the library, creates actions for widgets in the added factory. | |
| void | lookupFactories () |
| Lookups widget factories list (note that this function get called once in ctor). | |
| void | loadFactories () |
| Loads widget factories found in lookupFactories(). | |
Protected Attributes | |
| WidgetLibraryPrivate * | d |
Constructor & Destructor Documentation
|
||||||||||||
|
Constructs WidgetLibrary object. In supportedFactoryGroups you can provide factory group list to be supported. Factory groups are defined by "X-KFormDesigner-FactoryGroup" field in every factory serviece's .desktop file. By default (when supportedFactoryGroups is empty) only factories having empty "X-KFormDesigner-FactoryGroup" field will be loaded. Factory group names are case-insensitive. Definition at line 109 of file widgetlibrary.cpp. References d, and lookupFactories(). |
|
|
Definition at line 121 of file widgetlibrary.cpp. References d. |
Member Function Documentation
|
|
Definition at line 350 of file widgetlibrary.cpp. References d. Referenced by KFormDesigner::FormManager::createActions(). |
|
|
Definition at line 569 of file widgetlibrary.cpp. References d. |
|
|
Definition at line 608 of file widgetlibrary.cpp. References KFormDesigner::WidgetInfo::className(), d, KFormDesigner::WidgetInfo::factory(), KFormDesigner::WidgetInfo::inheritedClass(), and loadFactories(). |
|
|
Checks if the classname is an alternate classname, and returns the good classname. If classname is not alternate, classname is returned. Definition at line 496 of file widgetlibrary.cpp. References d, and loadFactories(). |
|
||||||||||||
|
Definition at line 432 of file widgetlibrary.cpp. References KFormDesigner::WidgetInfo::className(), d, KFormDesigner::WidgetInfo::factory(), KFormDesigner::WidgetInfo::inheritedClass(), and loadFactories(). |
|
||||||||||||||||||||
|
Definition at line 380 of file widgetlibrary.cpp. References KFormDesigner::WidgetInfo::className(), d, KFormDesigner::WidgetInfo::factory(), KFormDesigner::WidgetInfo::inheritedClass(), and loadFactories(). |
|
||||||||||||||||||||||||
|
searches the right factory and creates a widget.
Definition at line 361 of file widgetlibrary.cpp. References KFormDesigner::WidgetInfo::className(), d, KFormDesigner::WidgetInfo::factory(), KFormDesigner::WidgetInfo::inheritedClass(), and loadFactories(). Referenced by KFormDesigner::CreateLayoutCommand::execute(). |
|
||||||||||||||||||||
|
creates actions for widget creating
Definition at line 321 of file widgetlibrary.cpp. References d, loadFactories(), and prepareInsert(). Referenced by KFormDesigner::FormManager::createActions(). |
|
|
Definition at line 448 of file widgetlibrary.cpp. References d, loadFactories(), and KFormDesigner::WidgetInfo::name(). |
|
|
Definition at line 685 of file widgetlibrary.cpp. References d. Referenced by KFormDesigner::WidgetFactory::setEditor(), and KFormDesigner::WidgetFactory::setWidget(). |
|
|
Definition at line 630 of file widgetlibrary.cpp. References KFormDesigner::WidgetInfo::factory(), and widgetInfoForClassName(). Referenced by KFormDesigner::WidgetFactory::editor(). |
|
|
Definition at line 523 of file widgetlibrary.cpp. References d, loadFactories(), and KFormDesigner::WidgetInfo::pixmap(). Referenced by showOrientationSelectionPopup(). |
|
|
Definition at line 512 of file widgetlibrary.cpp. References d, KFormDesigner::WidgetInfo::includeFileName(), and loadFactories(). Referenced by KFormDesigner::FormIO::saveWidget(). |
|
||||||||||||
|
Definition at line 690 of file widgetlibrary.cpp. References d, KFormDesigner::WidgetInfo::factory(), KFormDesigner::WidgetInfo::inheritedClass(), and loadFactories(). |
|
||||||||||||||||||||||||
|
Definition at line 575 of file widgetlibrary.cpp. References KFormDesigner::WidgetInfo::className(), d, KFormDesigner::WidgetInfo::factory(), KFormDesigner::WidgetInfo::inheritedClass(), and loadFactories(). |
|
|
Loads widget factories found in lookupFactories(). This is called once. Definition at line 230 of file widgetlibrary.cpp. References d, loadFactoryWidgets(), KFormDesigner::WidgetFactory::m_hiddenClasses, KFormDesigner::WidgetFactory::m_library, KFormDesigner::WidgetFactory::m_showAdvancedProperties, and KFormDesigner::WidgetFactory::m_xmlGUIFileName. Referenced by autoSaveProperties(), classNameForAlternate(), clearWidgetContent(), createMenuActions(), createWidget(), createWidgetActions(), displayName(), iconName(), includeFileName(), internalProperty(), isPropertyVisible(), namePrefix(), previewWidget(), readSpecialProperty(), saveSpecialProperty(), savingName(), showOrientationSelectionPopup(), startEditing(), textForWidgetName(), and widgetInfoForClassName(). |
|
|
|
Lookups widget factories list (note that this function get called once in ctor).
Definition at line 195 of file widgetlibrary.cpp. References d, and KFormDesigner::version(). Referenced by WidgetLibrary(). |
|
|
Definition at line 471 of file widgetlibrary.cpp. References d, loadFactories(), and KFormDesigner::WidgetInfo::namePrefix(). |
|
|
Referenced by createWidgetActions(). |
|
||||||||||||||||
|
Definition at line 416 of file widgetlibrary.cpp. References KFormDesigner::WidgetInfo::className(), d, KFormDesigner::WidgetInfo::factory(), KFormDesigner::WidgetInfo::inheritedClass(), and loadFactories(). Referenced by KFormDesigner::Form::setDesignMode(). |
|
||||||||||||
|
Definition at line 636 of file widgetlibrary.cpp. References d, KFormDesigner::WidgetInfo::factory(), KFormDesigner::WidgetInfo::m_parentFactoryName, and KFormDesigner::WidgetFactory::propertyDescForName(). |
|
||||||||||||
|
Definition at line 654 of file widgetlibrary.cpp. References d, and KFormDesigner::WidgetFactory::propertyDescForValue(). |
|
||||||||||||||||
|
Definition at line 755 of file widgetlibrary.cpp. References KFormDesigner::WidgetInfo::factory(), and widgetInfoForClassName(). |
|
||||||||||||||||||||
|
Definition at line 550 of file widgetlibrary.cpp. References KFormDesigner::WidgetInfo::className(), d, KFormDesigner::WidgetInfo::factory(), KFormDesigner::WidgetInfo::inheritedClass(), and loadFactories(). |
|
||||||||||||||||||||||||||||
|
Definition at line 534 of file widgetlibrary.cpp. References KFormDesigner::WidgetInfo::className(), d, KFormDesigner::WidgetInfo::factory(), KFormDesigner::WidgetInfo::inheritedClass(), and loadFactories(). Referenced by KFormDesigner::FormIO::savePropertyValue(). |
|
|
Definition at line 459 of file widgetlibrary.cpp. References d, loadFactories(), and KFormDesigner::WidgetInfo::savingName(). Referenced by KFormDesigner::FormIO::saveWidget(). |
|
|
Sets advanced properties to be visible or not. Definition at line 564 of file widgetlibrary.cpp. References d. Referenced by KexiFormPart::KexiFormPart(), and KexiReportPart::KexiReportPart(). |
|
||||||||||||||||
|
Used by WidgetPropertySet::setWidget() after creating properties. Definition at line 672 of file widgetlibrary.cpp. References d, KFormDesigner::WidgetInfo::factory(), KFormDesigner::WidgetInfo::m_parentFactoryName, and KFormDesigner::WidgetFactory::setPropertyOptions(). |
|
||||||||||||||||
|
Shows orientation selection popup.
Definition at line 702 of file widgetlibrary.cpp. References KFormDesigner::WidgetFactory::AnyOrientation, d, KFormDesigner::WidgetInfo::factory(), KFormDesigner::WidgetFactory::HorizontalOrientation, iconName(), KFormDesigner::WidgetInfo::inheritedClass(), loadFactories(), KFormDesigner::WidgetInfo::name(), KFormDesigner::WidgetInfo::pixmap(), and KFormDesigner::WidgetFactory::VerticalOrientation. |
|
||||||||||||||||
|
Definition at line 400 of file widgetlibrary.cpp. References KFormDesigner::WidgetInfo::className(), d, KFormDesigner::WidgetInfo::factory(), KFormDesigner::WidgetInfo::inheritedClass(), and loadFactories(). |
|
||||||||||||
|
Definition at line 482 of file widgetlibrary.cpp. References d, loadFactories(), KFormDesigner::WidgetInfo::name(), and KFormDesigner::WidgetInfo::namePrefix(). |
|
|
Definition at line 623 of file widgetlibrary.cpp. References d, and loadFactories(). Referenced by factoryForClassName(), and propertySetShouldBeReloadedAfterPropertyChange(). |
Member Data Documentation
|
The documentation for this class was generated from the following files:
