QWidgetPlugin(3qt)

NAME
QWidgetPlugin - Abstract base for custom TQWidget plugins

SYNOPSIS
#include <ntqwidgetplugin.h>

  Public Members
QWidgetPlugin ()
~QWidgetPlugin ()
virtual QStringList keys () const = 0
virtual TQWidget * create ( const TQString & key, TQWidget * parent = 0, const char * name = 0 ) = 0
virtual TQString group ( const TQString & key ) const
virtual QIconSet iconSet ( const TQString & key ) const
virtual TQString includeFile ( const TQString & key ) const
virtual TQString toolTip ( const TQString & key ) const
virtual TQString whatsThis ( const TQString & key ) const
virtual bool isContainer ( const TQString & key ) const

DESCRIPTION
The QWidgetPlugin class provides an abstract base for custom TQWidget plugins.

The widget plugin is a simple plugin interface that makes it easy to create custom widgets that can be included in forms using TQt Designer and used by applications.

Writing a widget plugin is achieved by subclassing this base class, reimplementing the pure virtual functions keys(), create(), group(), iconSet(), includeFile(), toolTip(), whatsThis() and isContainer(), and exporting the class with the Q_EXPORT_PLUGIN macro.

See the TQt Designer manual's, 'Creating Custom Widgets' section in the 'Creating Custom Widgets' chapter, for a complete example of a QWidgetPlugin.

See also the Plugins documentation and the QWidgetFactory class that is supplied with TQt Designer.

See also Plugins.

MEMBER FUNCTION DOCUMENTATION

QWidgetPlugin::QWidgetPlugin ()
Constructs a widget plugin. This is invoked automatically by the Q_EXPORT_PLUGIN macro.

QWidgetPlugin::~QWidgetPlugin ()
Destroys the widget plugin.

You never have to call this explicitly. TQt destroys a plugin automatically when it is no longer used.

TQWidget * QWidgetPlugin::create ( const TQString & key, TQWidget * parent = 0, const char * name = 0 ) [pure virtual]
Creates and returns a TQWidget object for the widget key key. The widget key is the class name of the required widget. The name and parent arguments are passed to the custom widget's constructor.

See also keys().

TQString QWidgetPlugin::group ( const TQString & key ) const [virtual]
Returns the group (toolbar name) that the custom widget of class key should be part of when Qt Designer loads it.

The default implementation returns TQString::null.

QIconSet QWidgetPlugin::iconSet ( const TQString & key ) const [virtual]
Returns the iconset that Qt Designer should use to represent the custom widget of class key in the toolbar.

The default implementation returns an null iconset.

TQString QWidgetPlugin::includeFile ( const TQString & key ) const [virtual]
Returns the name of the include file that Qt Designer and uic should use to include the custom widget of class key in generated code.

The default implementation returns TQString::null.

bool QWidgetPlugin::isContainer ( const TQString & key ) const [virtual]
Returns true if the custom widget of class key can contain other widgets, e.g. like QFrame; otherwise returns false.

The default implementation returns false.

QStringList QWidgetPlugin::keys () const [pure virtual]
Returns the list of widget keys this plugin supports.

These keys must be the class names of the custom widgets that are implemented in the plugin.

See also create().

TQString QWidgetPlugin::toolTip ( const TQString & key ) const [virtual]
Returns the text of the tooltip that Qt Designer should use for the custom widget of class key's toolbar button.

The default implementation returns TQString::null.

TQString QWidgetPlugin::whatsThis ( const TQString & key ) const [virtual]
Returns the text of the whatsThis text that Qt Designer should use when the user requests whatsThis help for the custom widget of class key.

The default implementation returns TQString::null.

SEE ALSO
http://doc.trolltech.com/ntqwidgetplugin.html http://www.trolltech.com/faq/tech.html

COPYRIGHT
Copyright 1992-2007 Trolltech ASA, http://www.trolltech.com. See the license file included in the distribution for a complete license statement.

AUTHOR
Generated automatically from the source code.

BUGS
If you find a bug in Qt, please report it as described in http://doc.trolltech.com/bughowto.html. Good bug reports help us to help you. Thank you.

The definitive TQt documentation is provided in HTML format; it is located at $TQTDIR/doc/html and can be read using TQt Assistant or with a web browser. This man page is provided as a convenience for those users who prefer man pages, although this format is not officially supported by Trolltech.

If you find errors in this manual page, please report them to qt-bugs@trolltech.com. Please include the name of the manual page (tqwidgetplugin.3qt) and the Qt version (3.3.8).