Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

vtkKWMenuButton Class Reference

an option menu widget More...

#include <vtkKWMenuButton.h>

Inheritance diagram for vtkKWMenuButton:

Inheritance graph
[legend]
Collaboration diagram for vtkKWMenuButton:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 vtkTypeRevisionMacro (vtkKWMenuButton, vtkKWCoreWidget)
void PrintSelf (ostream &os, vtkIndent indent)
virtual void Create (vtkKWApplication *app)
virtual void UpdateEnableState ()
virtual const char * GetValue ()
virtual void SetValue (const char *name)
virtual void NextValue ()
virtual void PreviousValue ()
virtual vtkKWMenuGetMenu ()
virtual void AddRadioButton (const char *label)
virtual void AddRadioButton (const char *label, vtkObject *obj, const char *method, const char *help=0)
virtual void AddRadioButtonImage (const char *image_name, vtkObject *obj, const char *method, const char *help=0)
virtual void SetIndicatorVisibility (int ind)
virtual int GetIndicatorVisibility ()
virtual void IndicatorVisibilityOn ()
virtual void IndicatorVisibilityOff ()
virtual void SetWidth (int width)
virtual int GetWidth ()
virtual void SetMaximumLabelWidth (int)
virtual int GetMaximumLabelWidth ()
virtual void SetAnchor (int)
virtual int GetAnchor ()
virtual void SetAnchorToNorth ()
virtual void SetAnchorToNorthEast ()
virtual void SetAnchorToEast ()
virtual void SetAnchorToSouthEast ()
virtual void SetAnchorToSouth ()
virtual void SetAnchorToSouthWest ()
virtual void SetAnchorToWest ()
virtual void SetAnchorToNorthWest ()
virtual void SetAnchorToCenter ()
virtual void SetImageToIcon (vtkKWIcon *icon)
virtual void SetImageToPredefinedIcon (int icon_index)
virtual void SetImageToPixels (const unsigned char *pixels, int width, int height, int pixel_size, unsigned long buffer_length=0)
virtual void TracedVariableChangedCallback (const char *, const char *, const char *)

Static Public Member Functions

vtkKWMenuButtonNew ()

Protected Member Functions

 vtkKWMenuButton ()
 ~vtkKWMenuButton ()
virtual char * GetCurrentValue ()
virtual void SetCurrentValue (const char *)
virtual void UpdateOptionMenuLabel ()

Protected Attributes

char * CurrentValue
vtkKWMenuMenu
int MaximumLabelWidth

Detailed Description

an option menu widget

A widget that looks like a button but when pressed provides a list of options that the user can select.

Definition at line 30 of file vtkKWMenuButton.h.


Constructor & Destructor Documentation

vtkKWMenuButton::vtkKWMenuButton  )  [protected]
 

vtkKWMenuButton::~vtkKWMenuButton  )  [protected]
 


Member Function Documentation

vtkKWMenuButton* vtkKWMenuButton::New  )  [static]
 

Reimplemented from vtkKWCoreWidget.

Reimplemented in vtkPVColorSelectionWidget.

vtkKWMenuButton::vtkTypeRevisionMacro vtkKWMenuButton  ,
vtkKWCoreWidget 
 

void vtkKWMenuButton::PrintSelf ostream &  os,
vtkIndent  indent
 

Reimplemented from vtkKWCoreWidget.

Reimplemented in vtkPVColorSelectionWidget.

virtual void vtkKWMenuButton::Create vtkKWApplication app  )  [virtual]
 

Create the widget.

Reimplemented from vtkKWCoreWidget.

virtual const char* vtkKWMenuButton::GetValue  )  [virtual]
 

Set/Get the current entry of this option menu. This can be an image name if any entry in the menu uses an image instead of a label.

virtual void vtkKWMenuButton::SetValue const char *  name  )  [virtual]
 

Set/Get the current entry of this option menu. This can be an image name if any entry in the menu uses an image instead of a label.

Reimplemented in vtkPVColorSelectionWidget.

virtual void vtkKWMenuButton::NextValue  )  [virtual]
 

Set/Get the current entry to the previous or next entry and call the corresponding callback if any.

virtual void vtkKWMenuButton::PreviousValue  )  [virtual]
 

Set/Get the current entry to the previous or next entry and call the corresponding callback if any.

virtual vtkKWMenu* vtkKWMenuButton::GetMenu  )  [virtual]
 

Get the menu object

virtual void vtkKWMenuButton::AddRadioButton const char *  label  )  [virtual]
 

Add/Insert radiobutton entries to the internal menu. The following methods are just convenience calls to the internal vtkKWMenu's AddRadioButton methods, but we make sure all radiobuttons share the same internal variable reference so that they behave as if they were part of the same group.

virtual void vtkKWMenuButton::AddRadioButton const char *  label,
vtkObject *  obj,
const char *  method,
const char *  help = 0
[virtual]
 

Add/Insert radiobutton entries to the internal menu. The following methods are just convenience calls to the internal vtkKWMenu's AddRadioButton methods, but we make sure all radiobuttons share the same internal variable reference so that they behave as if they were part of the same group.

virtual void vtkKWMenuButton::AddRadioButtonImage const char *  image_name,
vtkObject *  obj,
const char *  method,
const char *  help = 0
[virtual]
 

Add/Insert radiobutton entries to the internal menu. The following methods are just convenience calls to the internal vtkKWMenu's AddRadioButton methods, but we make sure all radiobuttons share the same internal variable reference so that they behave as if they were part of the same group.

virtual void vtkKWMenuButton::SetIndicatorVisibility int  ind  )  [virtual]
 

Set the indicator On/Off. To be called after creation.

virtual int vtkKWMenuButton::GetIndicatorVisibility  )  [virtual]
 

Set the indicator On/Off. To be called after creation.

virtual void vtkKWMenuButton::IndicatorVisibilityOn  )  [virtual]
 

Set the indicator On/Off. To be called after creation.

virtual void vtkKWMenuButton::IndicatorVisibilityOff  )  [virtual]
 

Set the indicator On/Off. To be called after creation.

virtual void vtkKWMenuButton::SetWidth int  width  )  [virtual]
 

Convenience method to set the button width (in chars if text, in pixels if image).

virtual int vtkKWMenuButton::GetWidth  )  [virtual]
 

Convenience method to set the button width (in chars if text, in pixels if image).

virtual void vtkKWMenuButton::SetMaximumLabelWidth int   )  [virtual]
 

Set/Get the maximum width of the option menu label This does not modify the internal value, this is just for display purposes: the option menu button can therefore be automatically shrinked, while the menu associated to it will display all entries correctly. Set width to 0 (default) to prevent auto-cropping.

virtual int vtkKWMenuButton::GetMaximumLabelWidth  )  [virtual]
 

Set/Get the maximum width of the option menu label This does not modify the internal value, this is just for display purposes: the option menu button can therefore be automatically shrinked, while the menu associated to it will display all entries correctly. Set width to 0 (default) to prevent auto-cropping.

virtual void vtkKWMenuButton::SetAnchor int   )  [virtual]
 

Set/Get the anchoring. Specifies how the information in a widget (e.g. text or a bitmap) is to be displayed in the widget. Valid constants can be found in vtkKWTkOptions::AnchorType.

virtual int vtkKWMenuButton::GetAnchor  )  [virtual]
 

Set/Get the anchoring. Specifies how the information in a widget (e.g. text or a bitmap) is to be displayed in the widget. Valid constants can be found in vtkKWTkOptions::AnchorType.

virtual void vtkKWMenuButton::SetAnchorToNorth  )  [inline, virtual]
 

Set/Get the anchoring. Specifies how the information in a widget (e.g. text or a bitmap) is to be displayed in the widget. Valid constants can be found in vtkKWTkOptions::AnchorType.

Definition at line 104 of file vtkKWMenuButton.h.

virtual void vtkKWMenuButton::SetAnchorToNorthEast  )  [inline, virtual]
 

Set/Get the anchoring. Specifies how the information in a widget (e.g. text or a bitmap) is to be displayed in the widget. Valid constants can be found in vtkKWTkOptions::AnchorType.

Definition at line 106 of file vtkKWMenuButton.h.

virtual void vtkKWMenuButton::SetAnchorToEast  )  [inline, virtual]
 

Set/Get the anchoring. Specifies how the information in a widget (e.g. text or a bitmap) is to be displayed in the widget. Valid constants can be found in vtkKWTkOptions::AnchorType.

Definition at line 108 of file vtkKWMenuButton.h.

virtual void vtkKWMenuButton::SetAnchorToSouthEast  )  [inline, virtual]
 

Set/Get the anchoring. Specifies how the information in a widget (e.g. text or a bitmap) is to be displayed in the widget. Valid constants can be found in vtkKWTkOptions::AnchorType.

Definition at line 110 of file vtkKWMenuButton.h.

virtual void vtkKWMenuButton::SetAnchorToSouth  )  [inline, virtual]
 

Set/Get the anchoring. Specifies how the information in a widget (e.g. text or a bitmap) is to be displayed in the widget. Valid constants can be found in vtkKWTkOptions::AnchorType.

Definition at line 112 of file vtkKWMenuButton.h.

virtual void vtkKWMenuButton::SetAnchorToSouthWest  )  [inline, virtual]
 

Set/Get the anchoring. Specifies how the information in a widget (e.g. text or a bitmap) is to be displayed in the widget. Valid constants can be found in vtkKWTkOptions::AnchorType.

Definition at line 114 of file vtkKWMenuButton.h.

virtual void vtkKWMenuButton::SetAnchorToWest  )  [inline, virtual]
 

Set/Get the anchoring. Specifies how the information in a widget (e.g. text or a bitmap) is to be displayed in the widget. Valid constants can be found in vtkKWTkOptions::AnchorType.

Definition at line 116 of file vtkKWMenuButton.h.

virtual void vtkKWMenuButton::SetAnchorToNorthWest  )  [inline, virtual]
 

Set/Get the anchoring. Specifies how the information in a widget (e.g. text or a bitmap) is to be displayed in the widget. Valid constants can be found in vtkKWTkOptions::AnchorType.

Definition at line 118 of file vtkKWMenuButton.h.

virtual void vtkKWMenuButton::SetAnchorToCenter  )  [inline, virtual]
 

Set/Get the anchoring. Specifies how the information in a widget (e.g. text or a bitmap) is to be displayed in the widget. Valid constants can be found in vtkKWTkOptions::AnchorType.

Definition at line 120 of file vtkKWMenuButton.h.

virtual void vtkKWMenuButton::SetImageToIcon vtkKWIcon icon  )  [virtual]
 

Specifies an image to display in the widget. Typically, if the image is specified then it overrides other options that specify a bitmap or textual value to display in the widget. Invoke vtkKWWidget's SetConfigurationOption("-image", imagename) to use a specific pre-existing Tk image, or call one of the following functions. The SetImageToPredefinedIcon method accepts an index to one of the predefined icon listed in vtkKWIcon. The SetImageToPixels method sets the image using pixel data. It expects a pointer to the pixels and the structure of the image, i.e. its width, height and the pixel_size (how many bytes per pixel, say 3 for RGB, or 1 for grayscale). If buffer_length = 0, it is computed automatically from the previous parameters. If it is not, it will most likely indicate that the buffer has been encoded using base64 and/or zlib. If pixel_size > 3 (i.e. RGBA), the image is blend the with background color of the widget.

virtual void vtkKWMenuButton::SetImageToPredefinedIcon int  icon_index  )  [virtual]
 

Specifies an image to display in the widget. Typically, if the image is specified then it overrides other options that specify a bitmap or textual value to display in the widget. Invoke vtkKWWidget's SetConfigurationOption("-image", imagename) to use a specific pre-existing Tk image, or call one of the following functions. The SetImageToPredefinedIcon method accepts an index to one of the predefined icon listed in vtkKWIcon. The SetImageToPixels method sets the image using pixel data. It expects a pointer to the pixels and the structure of the image, i.e. its width, height and the pixel_size (how many bytes per pixel, say 3 for RGB, or 1 for grayscale). If buffer_length = 0, it is computed automatically from the previous parameters. If it is not, it will most likely indicate that the buffer has been encoded using base64 and/or zlib. If pixel_size > 3 (i.e. RGBA), the image is blend the with background color of the widget.

virtual void vtkKWMenuButton::SetImageToPixels const unsigned char *  pixels,
int  width,
int  height,
int  pixel_size,
unsigned long  buffer_length = 0
[virtual]
 

Specifies an image to display in the widget. Typically, if the image is specified then it overrides other options that specify a bitmap or textual value to display in the widget. Invoke vtkKWWidget's SetConfigurationOption("-image", imagename) to use a specific pre-existing Tk image, or call one of the following functions. The SetImageToPredefinedIcon method accepts an index to one of the predefined icon listed in vtkKWIcon. The SetImageToPixels method sets the image using pixel data. It expects a pointer to the pixels and the structure of the image, i.e. its width, height and the pixel_size (how many bytes per pixel, say 3 for RGB, or 1 for grayscale). If buffer_length = 0, it is computed automatically from the previous parameters. If it is not, it will most likely indicate that the buffer has been encoded using base64 and/or zlib. If pixel_size > 3 (i.e. RGBA), the image is blend the with background color of the widget.

virtual void vtkKWMenuButton::UpdateEnableState  )  [virtual]
 

Update the "enable" state of the object and its internal parts. Depending on different Ivars (this->Enabled, the application's Limited Edition Mode, etc.), the "enable" state of the object is updated and propagated to its internal parts/subwidgets. This will, for example, enable/disable parts of the widget UI, enable/disable the visibility of 3D widgets, etc.

Reimplemented from vtkKWWidget.

virtual void vtkKWMenuButton::TracedVariableChangedCallback const char *  ,
const char *  ,
const char * 
[virtual]
 

Callbacks (don't call)

virtual char* vtkKWMenuButton::GetCurrentValue  )  [protected, virtual]
 

virtual void vtkKWMenuButton::SetCurrentValue const char *   )  [protected, virtual]
 

virtual void vtkKWMenuButton::UpdateOptionMenuLabel  )  [protected, virtual]
 


Member Data Documentation

char* vtkKWMenuButton::CurrentValue [protected]
 

Definition at line 168 of file vtkKWMenuButton.h.

vtkKWMenu* vtkKWMenuButton::Menu [protected]
 

Definition at line 169 of file vtkKWMenuButton.h.

int vtkKWMenuButton::MaximumLabelWidth [protected]
 

Definition at line 170 of file vtkKWMenuButton.h.


The documentation for this class was generated from the following file:
Generated on Tue May 30 12:40:11 2006 for ParaView by doxygen 1.3.5