INavigationWidgetFactory Class | Extending Qt Creator Manual

Extending Qt Creator Manual | INavigationWidgetFactory

Extending Qt Creator Manual 4.4.1

# INavigationWidgetFactory Class

(Core::INavigationWidgetFactory)

The INavigationWidgetFactory class provides new instances of navigation widgets. More...

Header: | #include <INavigationWidgetFactory>

- List of all members, including inherited members

## Public Functions

| INavigationWidgetFactory()
QKeySequence | activationSequence() const
virtual NavigationView | createWidget() = 0
QString | displayName() const
Id | id() const
int | priority() const
virtual void | restoreSettings(QSettings *settings, int position, QWidget *widget)
virtual void | saveSettings(QSettings *settings, int position, QWidget *widget)
void | setActivationSequence(const QKeySequence &keys)
void | setDisplayName(const QString &displayName)
void | setId(Id id)
void | setPriority(int priority)

## Detailed Description

The INavigationWidgetFactory class provides new instances of navigation widgets.

A navigation widget factory is necessary because there can be more than one navigation widget of the same type at a time. Each navigation widget is wrapped in a Core::NavigationView for delivery.

## Member Function Documentation

### INavigationWidgetFactory::INavigationWidgetFactory()

Creates a Core::NavigationViewFactory.

### QKeySequence INavigationWidgetFactory::activationSequence() const

Returns the keyboard shortcut to activate an instance of a navigation widget.

See also setActivationSequence().

### `[pure virtual]` NavigationView INavigationWidgetFactory::createWidget()

Returns a Core::NavigationView containing the widget and the buttons. The ownership is given to the caller.

### QString INavigationWidgetFactory::displayName() const

Returns the display name of the navigation widget, which is shown in the dropdown menu above the navigation widget.

See also setDisplayName().

### Id INavigationWidgetFactory::id() const

Returns a unique identifier for referencing the navigation widget factory.

See also setId().

### int INavigationWidgetFactory::priority() const

Determines the position of the navigation widget in the dropdown menu.

0 to 1000 from top to bottom

See also setPriority().

### `[virtual]` void INavigationWidgetFactory::restoreSettings(QSettings *settings, int position, QWidget *widget)

Reads and restores the settings for the widget at position that was created by this factory (the position identifies a specific navigation widget).

See also INavigationWidgetFactory::saveSettings().

### `[virtual]` void INavigationWidgetFactory::saveSettings(QSettings *settings, int position, QWidget *widget)

Stores the settings for the widget at position that was created by this factory (the position identifies a specific navigation widget).

See also INavigationWidgetFactory::restoreSettings().

### void INavigationWidgetFactory::setActivationSequence(const QKeySequence &keys)

Sets the keyboard activation sequence for the factory.

See also activationSequence().

### void INavigationWidgetFactory::setDisplayName(const QString &displayName)

Sets the display name for the factory.

See also displayName().

### void INavigationWidgetFactory::setId(Id id)

Sets the id for the factory.

See also id().

### void INavigationWidgetFactory::setPriority(int priority)

Sets the priority for the factory.

See also priority().