libyui-qt  2.47.1.1
YQWizard.h
1 /*
2  Copyright (C) 2000-2012 Novell, Inc
3  This library is free software; you can redistribute it and/or modify
4  it under the terms of the GNU Lesser General Public License as
5  published by the Free Software Foundation; either version 2.1 of the
6  License, or (at your option) version 3.0 of the License. This library
7  is distributed in the hope that it will be useful, but WITHOUT ANY
8  WARRANTY; without even the implied warranty of MERCHANTABILITY or
9  FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
10  License for more details. You should have received a copy of the GNU
11  Lesser General Public License along with this library; if not, write
12  to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
13  Floor, Boston, MA 02110-1301 USA
14 */
15 
16 
17 /*-/
18 
19  File: YQWizard.h
20 
21  Author: Stefan Hundhammer <sh@suse.de>
22 
23 /-*/
24 
25 
26 #ifndef YQWizard_h
27 #define YQWizard_h
28 
29 #include <string>
30 #include <vector>
31 
32 #include <qpixmap.h>
33 #include <qstringlist.h>
34 #include "QY2ListView.h"
35 #include <QGridLayout>
36 #include <QSplitter>
37 #include <qlabel.h>
38 #include <QMenu>
39 #include <QAction>
40 #include <qevent.h>
41 #include <yui/YWizard.h>
42 #include "YQWizardButton.h"
43 
44 using std::vector;
45 
46 class QGridLayout;
47 class QFrame;
48 class QSplitter;
49 class QLabel;
50 class QMenuBar;
51 class QPushButton;
52 class QSpacerItem;
53 class QToolButton;
54 class QStackedWidget;
55 class YReplacePoint;
56 class QTreeWidgetItem;
57 class YQAlignment;
58 class YQReplacePoint;
59 class QY2ListView;
60 class QY2HelpDialog;
61 class QY2RelNotesDialog;
62 
63 
64 class YQWizard : public QSplitter, public YWizard
65 {
66  Q_OBJECT
67 
68 protected:
69  class Step;
70  class TreeItem;
71 
72 public:
73  /**
74  * Constructor.
75  **/
76  YQWizard( YWidget * parent,
77  const std::string & backButtonLabel,
78  const std::string & abortButtonLabel,
79  const std::string & nextButtonLabel,
80  YWizardMode wizardMode = YWizardMode_Standard );
81 
82  /**
83  * Destructor.
84  **/
85  virtual ~YQWizard();
86 
87  /**
88  * Returns a descriptive label of this dialog instance for debugging.
89  *
90  * Reimplemented from YWidget.
91  **/
92  virtual std::string debugLabel() const;
93 
94  enum Direction { Forward, Backward };
95 
96  /**
97  * Returns the current direction of wizard operations - going forward or
98  * going backward. This can be used to maintain a consistent direction when
99  * assigning default buttons to a dialog.
100  **/
101  Direction direction() const { return _direction; }
102 
103  //
104  // Wizard basics
105  //
106 
107  /**
108  * Return internal widgets.
109  *
110  * Implemented from YWizard.
111  **/
112  virtual YQWizardButton * backButton() const { return _backButton; }
113  virtual YQWizardButton * abortButton() const { return _abortButton; }
114  virtual YQWizardButton * nextButton() const { return _nextButton; }
115 
116  virtual YReplacePoint * contentsReplacePoint() const { return _contentsReplacePoint; }
117 
118  /**
119  * Set the label of one of the wizard buttons (backButton(), abortButton(),
120  * nextButton() ) if that button is non-null.
121  *
122  * Implemented from YWizard.
123  **/
124  virtual void setButtonLabel( YPushButton * button, const std::string & newLabel );
125 
126  /**
127  * Set the help text.
128  *
129  * Implemented from YWizard.
130  **/
131  virtual void setHelpText( const std::string & helpText );
132 
133  /**
134  * Set the dialog icon. An empty icon name clears the current icon.
135  *
136  * Implemented from YWizard.
137  **/
138  virtual void setDialogIcon( const std::string & iconName );
139 
140  /**
141  * Set the dialog title shown in window manager's title bar.
142  * An empty std::string clears the current text.
143  *
144  * Implemented from YWizard.
145  **/
146  virtual void setDialogTitle( const std::string & titleText );
147 
148 
149  /**
150  * Set the dialog heading.
151  *
152  * Implemented from YWizard.
153  **/
154  virtual void setDialogHeading( const std::string & headingText );
155 
156 
157  //
158  // Steps handling
159  //
160 
161  /**
162  * Add a step for the steps panel on the side bar.
163  * This only adds the step to the internal list of steps.
164  * The display is only updated upon calling updateSteps().
165  *
166  * Implemented from YWizard.
167  **/
168  virtual void addStep( const std::string & text, const std::string & id );
169 
170  /**
171  * Add a step heading for the steps panel on the side bar.
172  * This only adds the heading to the internal list of steps.
173  * The display is only updated upon calling updateSteps().
174  *
175  * Implemented from YWizard.
176  **/
177  virtual void addStepHeading( const std::string & text );
178 
179  /**
180  * Return list of pointers to steps.
181  * Not needed outside copySteps() function
182  *
183  **/
184  QList<YQWizard::Step*> stepsList() { return _stepsList; }
185 
186  /**
187  * Create a copy of given wizard's steps set (names & IDs)
188  * Populates _stepsList structure of current wizard
189  *
190  **/
191  void copySteps( YQWizard *wizard);
192 
193  /**
194  * Delete all steps and step headings from the internal lists.
195  * The display is only updated upon calling updateSteps().
196  *
197  * Implemented from YWizard.
198  **/
199  virtual void deleteSteps();
200 
201  /**
202  * Set the current step. This also triggers updateSteps() if necessary.
203  *
204  * Implemented from YWizard.
205  **/
206  virtual void setCurrentStep( const std::string & id );
207 
208  /**
209  * Return QString ID of currently active step
210  *
211  **/
212  QString currentStep() { return _currentStepID; };
213 
214  /**
215  * Update the steps display: Reflect the internal steps and heading lists
216  * in the layout.
217  *
218  * Implemented from YWizard.
219  **/
220  virtual void updateSteps();
221 
222 
223  //
224  // Tree handling
225  //
226 
227  /**
228  * Add a tree item. If "parentID" is an empty std::string, it will be a root
229  * item. 'text' is the text that will be displayed in the tree, 'id' the ID
230  * with which this newly created item can be referenced - and that will be
231  * returned when the user clicks on a tree item.
232  *
233  * Implemented from YWizard.
234  **/
235  virtual void addTreeItem( const std::string & parentID,
236  const std::string & text,
237  const std::string & id );
238 
239  /**
240  * Select the tree item with the specified ID, if such an item exists.
241  *
242  * Implemented from YWizard.
243  **/
244  virtual void selectTreeItem( const std::string & id );
245 
246  /**
247  * Returns the current tree selection or an empty std::string if nothing is
248  * selected or there is no tree.
249  *
250  * Implemented from YWizard.
251  **/
252  virtual std::string currentTreeSelection();
253 
254  /**
255  * Delete all tree items.
256  *
257  * Implemented from YWizard.
258  **/
259  virtual void deleteTreeItems();
260 
261 
262  //
263  // Menu handling
264  //
265 
266  /**
267  * Add a menu to the menu bar. If the menu bar is not visible yet, it will
268  * be made visible. 'text' is the user-visible text for the menu bar
269  * (including keyboard shortcuts marked with '&'), 'id' is the menu ID for
270  * later addMenuEntry() etc. calls.
271  *
272  * Implemented from YWizard.
273  **/
274  virtual void addMenu( const std::string & text,
275  const std::string & id );
276 
277  /**
278  * Add a submenu to the menu with ID 'parentMenuID'.
279  *
280  * Implemented from YWizard.
281  **/
282  virtual void addSubMenu( const std::string & parentMenuID,
283  const std::string & text,
284  const std::string & id );
285 
286  /**
287  * Add a menu entry to the menu with ID 'parentMenuID'. 'id' is what will
288  * be returned by UI::UserInput() etc. when a user activates this menu entry.
289  *
290  * Implemented from YWizard.
291  **/
292  virtual void addMenuEntry( const std::string & parentMenuID,
293  const std::string & text,
294  const std::string & id );
295 
296  /**
297  * Add a menu separator to a menu.
298  *
299  * Implemented from YWizard.
300  **/
301  virtual void addMenuSeparator( const std::string & parentMenuID );
302 
303  /**
304  * Delete all menus and hide the menu bar.
305  *
306  * Implemented from YWizard.
307  **/
308  virtual void deleteMenus();
309 
310 
311  //
312  // Misc
313  //
314 
315  /**
316  * Show a "Release Notes" button above the "Help" button in the steps panel
317  * with the specified label that will return the specified id to
318  * UI::UserInput() when clicked.
319  *
320  * The button (or the wizard) will assume ownership of the id and delete it
321  * in the destructor.
322  *
323  * Implemented from YWizard.
324  **/
325  virtual void showReleaseNotesButton( const std::string & label,
326  const std::string & id );
327 
328  /**
329  * Hide an existing "Release Notes" button.
330  *
331  * Implemented from YWizard.
332  **/
333  virtual void hideReleaseNotesButton();
334 
335  /**
336  * Retranslate internal buttons that are not accessible from the outside:
337  * - [Help]
338  * - [Steps]
339  * - [Tree]
340  *
341  * Implemented from YWizard.
342  **/
343  virtual void retranslateInternalButtons();
344 
345  /**
346  * Event filter.
347  *
348  * Reimplemented from QWidget.
349  **/
350  virtual bool eventFilter( QObject * obj, QEvent * ev );
351 
352  /**
353  * Return this wizard's work area (the pane right of the side bar).
354  * This should not be needed outside of YQMainWinDock.
355  **/
356  QWidget * workArea() const { return _workArea; }
357 
358 
359  //
360  // Geometry management
361  //
362 
363  /**
364  * Preferred width of the widget.
365  *
366  * Reimplemented from YWidget.
367  **/
368  virtual int preferredWidth();
369 
370  /**
371  * Preferred height of the widget.
372  *
373  * Reimplemented from YWidget.
374  **/
375  virtual int preferredHeight();
376 
377  /**
378  * Set the new size of the widget.
379  *
380  * Reimplemented from YWidget.
381  **/
382  virtual void setSize( int newWidth, int newHeight );
383 
384  /**
385  * Returns true if the wizard should follow the first wizard with steps
386  **/
387  bool isSecondary() const;
388 
389 signals:
390 
391  /**
392  * Emitted when the "Back" or "Cancel" button is clicked.
393  **/
394  void backClicked();
395 
396  /**
397  * Emitted when the "Abort" button is clicked.
398  **/
399  void abortClicked();
400 
401  /**
402  * Emitted when the "Next" or "OK" button is clicked.
403  *
404  * Notice: As long as this signal is connected, the wizard will no longer
405  * send button events to the UI. Rather, the connected QObject has to take
406  * care to propagate those events.
407  * This is used in YQPatternSelector, for example.
408  **/
409  void nextClicked();
410 
411 
412 public slots:
413 
414  /**
415  * Adapt the size of the client area (the ReplacePoint(`id(`contents)) to
416  * fit in its current space.
417  **/
418  void resizeClientArea();
419 
420  /**
421  * Show the current help text.
422  *
423  * This is useful only if it is obscured by any wizard steps, but it can
424  * safely be called at any time.
425  **/
426  void showHelp();
427 
428  /**
429  * Show an overview of the power-user hotkeys
430  **/
431  void showHotkeys();
432 
433  /**
434  * Show the current wizard steps, if there are any. If there are none,
435  * nothing happens.
436  **/
437  void showSteps();
438 
439  /**
440  * Show the current selection tree in the side panel, if there is any. If
441  * there is none, nothing happens.
442  **/
443  void showTree();
444 
445 protected slots:
446 
447  /**
448  * Internal notification that the "Back" button has been clicked.
449  **/
450  void slotBackClicked();
451 
452  /**
453  * Internal notification that the "Abort" button has been clicked.
454  **/
455  void slotAbortClicked();
456 
457  /**
458  * Internal notification that the "Next" button has been clicked.
459  **/
460  void slotNextClicked();
461 
462  /**
463  * Propagate button clicked event of release notes button to the
464  * application.
465  **/
466  void showReleaseNotes();
467 
468  /**
469  * Internal notification that [Space] or [Return] has been pressed on a
470  * tree item.
471  * If the item has an ID, that ID will be returned to UI::UserInput().
472  **/
473  void sendTreeEvent( QTreeWidgetItem * item );
474 
475  /**
476  * Internal notification that the tree selection has changed.
477  *
478  * If the currently selected item has an ID, that ID will be returned to
479  * UI::UserInput().
480  **/
481  void treeSelectionChanged();
482 
483  /**
484  * Internal notification that a menu item with numeric ID 'numID' has been
485  * activated.
486  **/
487  void sendMenuEvent( QAction *action );
488 
489 protected:
490 
491  // Layout functions
492 
493  void layoutTitleBar ( QWidget * parent );
494  QLayout *layoutSideBar ( QWidget * parent );
495  void layoutSideBarButtonBox ( QWidget * parent, QPushButton * button );
496  void layoutStepsPanel();
497  void layoutTreePanel();
498  QWidget *layoutWorkArea ( QWidget * parent );
499  void layoutClientArea ( QWidget * parent );
500  QLayout *layoutButtonBox ( QWidget * parent );
501  bool titleIsOnTheLeft();
502 
503  /**
504  * Destroy the button box's buttons
505  **/
506  void destroyButtons();
507 
508  /**
509  * Update all step - use appropriate icons and colors
510  **/
511  void updateStepStates();
512 
513  /**
514  * Send a wizard event with the specified ID.
515  **/
516  void sendEvent( const std::string & id );
517 
518  /**
519  * Notification that a signal is being connected.
520  *
521  * Reimplemented from QObject.
522  **/
523  void connectNotify ( const char * signal );
524 
525  /**
526  * Notification that a signal is being disconnected.
527  *
528  * Reimplemented from QObject.
529  **/
530  void disconnectNotify ( const char * signal );
531 
532  /**
533  * Set a button's label.
534  **/
535  void setButtonLabel( YQWizardButton * button, const QString & newLabel );
536 
537  /**
538  * Enable or disable a button.
539  **/
540  void enableButton( YQWizardButton * button, bool enabled );
541 
542  /**
543  * Set the keyboard focus to a button.
544  **/
545  void setButtonFocus( YQWizardButton * button );
546 
547  /**
548  * Find a step with the specified ID. Returns 0 if there is no such step.
549  **/
550  YQWizard::Step * findStep( const QString & id );
551 
552  /**
553  * Find a tree item with the specified ID. Tree items without IDs cannot be
554  * found at all.
555  * Returns the item or 0 if no such item found.
556  **/
557  YQWizard::TreeItem * findTreeItem( const std::string & id );
558 
559 
560  //
561  // Data members
562  //
563 
564  std::string _backButtonLabel;
565  std::string _abortButtonLabel;
566  std::string _nextButtonLabel;
567 
568  bool _stepsEnabled;
569  bool _stepsRegistered;
570  bool _treeEnabled;
571  bool _protectNextButton;
572  bool _stepsDirty;
573  bool _sendButtonEvents;
574  Direction _direction;
575 
576  QString _currentStepID;
577  QString _qHelpText;
578  QString _qHotkeysText;
579 
580  QY2HelpDialog * _helpDlg;
581  QY2HelpDialog * _hotkeysDlg;
582  QY2RelNotesDialog * _relNotesDlg;
583 
584  QStackedWidget * _sideBar;
585  QWidget * _stepsPanel;
586  YQWizardButton * _releaseNotesButton;
587  static std::string _releaseNotesButtonId;
588  static std::string _releaseNotesButtonLabel;
589  YQWizardButton * _helpButton;
590  QAction * _helpAction;
591  QAction * _hotkeysAction;
592  QPushButton * _stepsButton;
593  QPushButton * _treeButton;
594  QFrame * _treePanel;
595  QY2ListView * _tree;
596 
597  QFrame * _workArea;
598  QWidget * _clientArea;
599  QMenuBar * _menuBar;
600  QLabel * _dialogIcon;
601  QLabel * _dialogLogo;
602  QLabel * _dialogHeading;
603  YQAlignment * _contents;
604  YQWizardButton * _backButton;
605  YQWizardButton * _abortButton;
606  YQWizardButton * _nextButton;
607  YReplacePoint * _contentsReplacePoint;
608 
609  QList<YQWizard::Step*> _stepsList;
610  QHash<QString,YQWizard::Step*> _stepsIDs;
611  QHash<QString,YQWizard::TreeItem*> _treeIDs;
612  QHash<QString,QMenu*> _menuIDs;
613  QHash<QAction*, std::string> _menuEntryIDs;
614 
615  QIcon _previousWindowIcon;
616 
617 private:
618  static YQWizard *main_wizard;
619 
620 protected:
621 
622  /**
623  * Helper class to represent a wizard step internally
624  **/
625  class Step
626  {
627  public:
628 
629  Step( const QString & name = "", const QString & id = "" )
630  : _name( name )
631  , _statusLabel( 0 )
632  , _nameLabel(0)
633  , _enabled( true )
634  , _idList( id )
635  , _status( Unset )
636  {}
637 
638  /**
639  * Destructor. Intentionally not deleting the widgets.
640  **/
641  virtual ~Step();
642 
643  virtual bool isHeading() const { return false; }
644 
645  enum Status { Unset, Todo, Current, Done };
646 
647  QString name() const { return _name; }
648  QLabel * statusLabel() const { return _statusLabel; }
649  QLabel * nameLabel() const { return _nameLabel; }
650  bool isEnabled() const { return _enabled; }
651  const QStringList & id() const { return _idList; }
652  void addID( const QString & id ) { _idList.append( id ); }
653  virtual bool hasID( const QString & id ) { return _idList.indexOf( id ) != -1; }
654 
655  void setStatusLabel( QLabel * label ) { _statusLabel = label; }
656  void setNameLabel ( QLabel * label ) { _nameLabel = label; }
657  void setEnabled( bool enabled ) { _enabled = enabled; }
658 
659  void deleteLabels();
660 
661  /**
662  * Set text color and status icon for one wizard step
663  **/
664  void setStatus( Status s );
665 
666  protected:
667 
668  QString _name;
669  QLabel * _statusLabel;
670  QLabel * _nameLabel;
671  bool _enabled;
672  QStringList _idList;
673  Status _status;
674 
675  private:
676  Q_DISABLE_COPY(Step);
677  };
678 
679 
680  /**
681  * Helper class to represent a wizard step heading internally
682  **/
683  class StepHeading: public Step
684  {
685  public:
686 
687  StepHeading( const QString & name = "" )
688  : Step( name, "" )
689  {}
690 
691  virtual ~StepHeading() {}
692  virtual bool isHeading() const { return true; }
693  virtual bool hasID( const QString & id ) { return false; }
694 
695  private:
696  Q_DISABLE_COPY(StepHeading);
697  };
698 
699 
700  /**
701  * Helper class for wizard tree item
702  **/
703  class TreeItem: public QY2ListViewItem
704  {
705  public:
706  TreeItem( QY2ListView * parent,
707  const QString & text,
708  const QString & id )
709  : QY2ListViewItem( parent, text )
710  , _id( id )
711  {}
712 
713  TreeItem( YQWizard::TreeItem * parent,
714  const QString & text,
715  const QString & id )
716  : QY2ListViewItem( parent, text )
717  , _id( id )
718  {}
719 
720  virtual QString text(int index) const { return QTreeWidgetItem::text(index); }
721  QString text() const { return QTreeWidgetItem::text(0); }
722  QString id() const { return _id; }
723 
724  private:
725  QString _id;
726  };
727 
728 }; // class YQWizard
729 
730 
731 
732 #endif // YQWizard_h
virtual std::string currentTreeSelection()
Returns the current tree selection or an empty std::string if nothing is selected or there is no tree...
Definition: YQWizard.cc:673
void showReleaseNotes()
Propagate button clicked event of release notes button to the application.
Definition: YQWizard.cc:1154
bool isSecondary() const
Returns true if the wizard should follow the first wizard with steps.
Definition: YQWizard.cc:208
virtual void setCurrentStep(const std::string &id)
Set the current step.
Definition: YQWizard.cc:487
void setButtonFocus(YQWizardButton *button)
Set the keyboard focus to a button.
void resizeClientArea()
Adapt the size of the client area (the ReplacePoint(id(contents)) to fit in its current space...
Definition: YQWizard.cc:1324
virtual ~Step()
Destructor.
Definition: YQWizard.cc:1442
virtual void setDialogIcon(const std::string &iconName)
Set the dialog icon.
Definition: YQWizard.cc:993
QWidget * workArea() const
Return this wizard&#39;s work area (the pane right of the side bar).
Definition: YQWizard.h:356
void destroyButtons()
Destroy the button box&#39;s buttons.
Definition: YQWizard.cc:960
virtual void deleteTreeItems()
Delete all tree items.
Definition: YQWizard.cc:618
Direction direction() const
Returns the current direction of wizard operations - going forward or going backward.
Definition: YQWizard.h:101
void sendTreeEvent(QTreeWidgetItem *item)
Internal notification that [Space] or [Return] has been pressed on a tree item.
Definition: YQWizard.cc:654
void showSteps()
Show the current wizard steps, if there are any.
Definition: YQWizard.cc:1175
virtual std::string debugLabel() const
Returns a descriptive label of this dialog instance for debugging.
Definition: YQWizard.cc:1040
Helper class to represent a wizard step heading internally.
Definition: YQWizard.h:683
virtual void setHelpText(const std::string &helpText)
Set the help text.
Definition: YQWizard.cc:1055
virtual void setButtonLabel(YPushButton *button, const std::string &newLabel)
Set the label of one of the wizard buttons (backButton(), abortButton(), nextButton() ) if that butto...
Definition: YQWizard.cc:1348
virtual void setSize(int newWidth, int newHeight)
Set the new size of the widget.
Definition: YQWizard.cc:1318
void connectNotify(const char *signal)
Notification that a signal is being connected.
Definition: YQWizard.cc:973
virtual void deleteSteps()
Delete all steps and step headings from the internal lists.
Definition: YQWizard.cc:527
Helper class for wizard tree item.
Definition: YQWizard.h:703
virtual void showReleaseNotesButton(const std::string &label, const std::string &id)
Show a "Release Notes" button above the "Help" button in the steps panel with the specified label tha...
Definition: YQWizard.cc:1365
virtual bool eventFilter(QObject *obj, QEvent *ev)
Event filter.
Definition: YQWizard.cc:1330
void slotAbortClicked()
Internal notification that the "Abort" button has been clicked.
Definition: YQWizard.cc:1073
virtual void selectTreeItem(const std::string &id)
Select the tree item with the specified ID, if such an item exists.
Definition: YQWizard.cc:637
void enableButton(YQWizardButton *button, bool enabled)
Enable or disable a button.
YQWizard(YWidget *parent, const std::string &backButtonLabel, const std::string &abortButtonLabel, const std::string &nextButtonLabel, YWizardMode wizardMode=YWizardMode_Standard)
Constructor.
Definition: YQWizard.cc:88
void copySteps(YQWizard *wizard)
Create a copy of given wizard&#39;s steps set (names & IDs) Populates _stepsList structure of current wiz...
Definition: YQWizard.cc:495
virtual void addStepHeading(const std::string &text)
Add a step heading for the steps panel on the side bar.
Definition: YQWizard.cc:328
void treeSelectionChanged()
Internal notification that the tree selection has changed.
Definition: YQWizard.cc:666
virtual void setDialogHeading(const std::string &headingText)
Set the dialog heading.
Definition: YQWizard.cc:1029
virtual void setDialogTitle(const std::string &titleText)
Set the dialog title shown in window manager&#39;s title bar.
Definition: YQWizard.cc:1018
virtual ~YQWizard()
Destructor.
Definition: YQWizard.cc:186
virtual void addMenuEntry(const std::string &parentMenuID, const std::string &text, const std::string &id)
Add a menu entry to the menu with ID &#39;parentMenuID&#39;.
Definition: YQWizard.cc:1237
virtual YQWizardButton * backButton() const
Return internal widgets.
Definition: YQWizard.h:112
YQWizard::TreeItem * findTreeItem(const std::string &id)
Find a tree item with the specified ID.
Definition: YQWizard.cc:628
void abortClicked()
Emitted when the "Abort" button is clicked.
void setStatus(Status s)
Set text color and status icon for one wizard step.
Definition: YQWizard.cc:1448
virtual void hideReleaseNotesButton()
Hide an existing "Release Notes" button.
Definition: YQWizard.cc:1386
void slotBackClicked()
Internal notification that the "Back" button has been clicked.
Definition: YQWizard.cc:1062
virtual void retranslateInternalButtons()
Retranslate internal buttons that are not accessible from the outside:
Definition: YQWizard.cc:1397
virtual void addMenuSeparator(const std::string &parentMenuID)
Add a menu separator to a menu.
Definition: YQWizard.cc:1260
QString currentStep()
Return QString ID of currently active step.
Definition: YQWizard.h:212
virtual void addStep(const std::string &text, const std::string &id)
Add a step for the steps panel on the side bar.
Definition: YQWizard.cc:292
virtual void deleteMenus()
Delete all menus and hide the menu bar.
Definition: YQWizard.cc:1275
Enhanced QTreeWidget.
Definition: QY2ListView.h:47
void showHotkeys()
Show an overview of the power-user hotkeys.
Definition: YQWizard.cc:1109
void showHelp()
Show the current help text.
Definition: YQWizard.cc:1093
virtual void addSubMenu(const std::string &parentMenuID, const std::string &text, const std::string &id)
Add a submenu to the menu with ID &#39;parentMenuID&#39;.
Definition: YQWizard.cc:1213
void slotNextClicked()
Internal notification that the "Next" button has been clicked.
Definition: YQWizard.cc:1082
YQWizard::Step * findStep(const QString &id)
Find a step with the specified ID.
Definition: YQWizard.cc:542
virtual int preferredHeight()
Preferred height of the widget.
Definition: YQWizard.cc:1312
void showTree()
Show the current selection tree in the side panel, if there is any.
Definition: YQWizard.cc:1184
void sendEvent(const std::string &id)
Send a wizard event with the specified ID.
Definition: YQWizard.cc:1300
Helper class to represent a wizard step internally.
Definition: YQWizard.h:625
Enhanced QTreeWidgetItem.
Definition: QY2ListView.h:233
virtual void addMenu(const std::string &text, const std::string &id)
Add a menu to the menu bar.
Definition: YQWizard.cc:1193
QList< YQWizard::Step * > stepsList()
Return list of pointers to steps.
Definition: YQWizard.h:184
virtual void addTreeItem(const std::string &parentID, const std::string &text, const std::string &id)
Add a tree item.
Definition: YQWizard.cc:583
void nextClicked()
Emitted when the "Next" or "OK" button is clicked.
void disconnectNotify(const char *signal)
Notification that a signal is being disconnected.
Definition: YQWizard.cc:983
void updateStepStates()
Update all step - use appropriate icons and colors.
Definition: YQWizard.cc:444
void sendMenuEvent(QAction *action)
Internal notification that a menu item with numeric ID &#39;numID&#39; has been activated.
Definition: YQWizard.cc:1287
virtual int preferredWidth()
Preferred width of the widget.
Definition: YQWizard.cc:1306
void backClicked()
Emitted when the "Back" or "Cancel" button is clicked.
virtual void updateSteps()
Update the steps display: Reflect the internal steps and heading lists in the layout.
Definition: YQWizard.cc:335