Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members

FX::FXSlider Class Reference

#include <FXSlider.h>

Inheritance diagram for FX::FXSlider:

FX::FXFrame FX::FXWindow FX::FXDrawable FX::FXId FX::FXObject List of all members.

Public Types

enum  {
  ID_AUTOINC = FXFrame::ID_LAST,
  ID_AUTODEC,
  ID_LAST
}

Public Methods

 FXSlider (FXComposite *p, FXObject *tgt=NULL, FXSelector sel=0, FXuint opts=SLIDER_NORMAL, FXint x=0, FXint y=0, FXint w=0, FXint h=0, FXint pl=0, FXint pr=0, FXint pt=0, FXint pb=0)
 Construct a slider widget.

virtual FXint getDefaultWidth ()
 Return default width.

virtual FXint getDefaultHeight ()
 Return default height.

virtual void enable ()
 Enable the slider.

virtual void disable ()
 Disable the slider.

void setValue (FXint value)
 Change slider value.

FXint getValue () const
 Return slider value.

void setRange (FXint lo, FXint hi)
 Change the slider's range.

void getRange (FXint &lo, FXint &hi) const
 Get the slider's current range.

FXuint getSliderStyle () const
 Change the slider style.

void setSliderStyle (FXuint style)
 Get the current slider style.

FXint getHeadSize () const
 Get the slider's head size.

void setHeadSize (FXint hs)
 Change the slider's head size.

FXint getSlotSize () const
 Get the slider's current slot size.

void setSlotSize (FXint bs)
 Change the slider's slot size.

FXint getIncrement () const
 Get the slider's auto-increment/decrement value.

void setIncrement (FXint inc)
 Change the slider's auto-increment/decrement value.

void setTickDelta (FXint dist)
 Change the delta between ticks.

FXint getTickDelta () const
 Get delta between ticks.

void setSlotColor (FXColor clr)
 Change the color of the slot the slider head moves in.

FXColor getSlotColor () const
 Get the current slot color.

void setHelpText (const FXString &text)
 Set the help text to be displayed on the status line.

const FXStringgetHelpText () const
 Get the current help text.

void setTipText (const FXString &text)
 Set the tip text to be displayed in the tooltip.

const FXStringgetTipText () const
 Get the current tooltip text value.

virtual void save (FXStream &store) const
 Save to stream.

virtual void load (FXStream &store)
 Load from stream.

virtual ~FXSlider ()
 Destroy the slider.


Detailed Description

The slider widget is a valuator widget which provides simple linear value range. Two visual appearances are supported:- the sunken look, which is enabled with the SLIDER_INSIDE_BAR option and the regular look. The latter may have optional arrows on the slider thumb. While being moved, the slider sends a SEL_CHANGED message to its target; at the end of the interaction, a SEL_COMMAND message is sent. The message data represents the current slider value, of type FXint.

See also: