KWWidgets
debian/tmp/usr/include/KWWidgets/vtkKWMenuButtonWithSpinButtons.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Module: $RCSfile: vtkKWWidgetWithSpinButtonsSubclass.h.in,v $
4 
5  Copyright (c) Kitware, Inc.
6  All rights reserved.
7  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
8 
9  This software is distributed WITHOUT ANY WARRANTY; without even
10  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11  PURPOSE. See the above copyright notice for more information.
12 
13 =========================================================================*/
14 // .NAME vtkKWMenuButtonWithSpinButtons - a vtkKWMenuButton associated to a vtkKWSpinButtons
15 // .SECTION Description
16 // This class creates a composite widget associating a vtkKWMenuButton to a
17 // vtkKWSpinButtons.
18 // As a subclass of vtkKWWidgetWithSpinButtons, it inherits a set of
19 // spin buttons.
20 // The only requirement is for the vtkKWMenuButton class to implement the
21 // NextValue() and PreviousValue() callbacks.
22 // @ingroup kwwidgets_autogenerated_widget_with_spinbuttons_group
23 // .SECTION Note
24 // This class and the corresponding code were
25 // \subpage kwwidgets_autogenerated_page "generated automatically" by
26 // instantiating the <tt>Templates/vtkKWWidgetWithSpinButtonsSubclass.h.in</tt>
27 // and <tt>Templates/vtkKWWidgetWithSpinButtonsSubclass.cxx.in</tt> files for
28 // the type vtkKWMenuButton. Classes related to the same template can be found
29 // in the \ref kwwidgets_autogenerated_widget_with_spinbuttons_group.
30 // .SECTION See Also
31 // vtkKWWidgetWithSpinButtons vtkKWMenuButton
32 
33 #ifndef __vtkKWMenuButtonWithSpinButtons_h
34 #define __vtkKWMenuButtonWithSpinButtons_h
35 
37 
38 class vtkKWMenuButton;
39 
41 {
42 public:
45  void PrintSelf(ostream& os, vtkIndent indent);
46 
47  // Description:
48  // Get the vtkKWMenuButton that is being associated to the spin buttons
49  virtual vtkKWMenuButton* GetWidget();
50 
51  // Description:
52  // Set the string that enables balloon help for this widget.
53  // Override to pass down to children.
54  virtual void SetBalloonHelpString(const char *str);
55 
56  // Description:
57  // Update the "enable" state of the object and its internal parts.
58  // Depending on different Ivars (this->Enabled, the application's
59  // Limited Edition Mode, etc.), the "enable" state of the object is updated
60  // and propagated to its internal parts/subwidgets. This will, for example,
61  // enable/disable parts of the widget UI, enable/disable the visibility
62  // of 3D widgets, etc.
63  virtual void UpdateEnableState();
64 
65  // Description:
66  // Callbacks
67  virtual void NextValueCallback();
68  virtual void PreviousValueCallback();
69 
70 protected:
73 
74  // Description:
75  // Create the widget
76  virtual void CreateWidget();
77 
78  // Description:
79  // Pack or repack the widget. To be implemented by subclasses.
80  virtual void Pack();
81 
82  // Description:
83  // Internal widget
84  vtkKWMenuButton *Widget;
85 
86 private:
87 
89  void operator=(const vtkKWMenuButtonWithSpinButtons&); // Not implemented
90 };
91 
92 #endif