2008-03-08 08:52:38 -05:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Name: slider.h
|
2008-03-10 11:24:38 -04:00
|
|
|
// Purpose: interface of wxSlider
|
2008-03-08 08:52:38 -05:00
|
|
|
// Author: wxWidgets team
|
2010-07-13 09:29:13 -04:00
|
|
|
// Licence: wxWindows licence
|
2008-03-08 08:52:38 -05:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
2011-11-02 16:22:29 -04:00
|
|
|
|
|
|
|
#define wxSL_HORIZONTAL wxHORIZONTAL /* 0x0004 */
|
|
|
|
#define wxSL_VERTICAL wxVERTICAL /* 0x0008 */
|
|
|
|
|
|
|
|
#define wxSL_TICKS 0x0010
|
|
|
|
#define wxSL_AUTOTICKS wxSL_TICKS // we don't support manual ticks
|
|
|
|
#define wxSL_LEFT 0x0040
|
|
|
|
#define wxSL_TOP 0x0080
|
|
|
|
#define wxSL_RIGHT 0x0100
|
|
|
|
#define wxSL_BOTTOM 0x0200
|
|
|
|
#define wxSL_BOTH 0x0400
|
|
|
|
#define wxSL_SELRANGE 0x0800
|
|
|
|
#define wxSL_INVERSE 0x1000
|
|
|
|
#define wxSL_MIN_MAX_LABELS 0x2000
|
|
|
|
#define wxSL_VALUE_LABEL 0x4000
|
|
|
|
#define wxSL_LABELS (wxSL_MIN_MAX_LABELS|wxSL_VALUE_LABEL)
|
|
|
|
|
2008-03-08 08:52:38 -05:00
|
|
|
/**
|
|
|
|
@class wxSlider
|
2008-03-08 09:43:31 -05:00
|
|
|
|
2008-10-04 16:49:51 -04:00
|
|
|
A slider is a control with a handle which can be pulled back and forth to
|
|
|
|
change the value.
|
2008-03-08 09:43:31 -05:00
|
|
|
|
2008-03-08 08:52:38 -05:00
|
|
|
On Windows, the track bar control is used.
|
2008-03-08 09:43:31 -05:00
|
|
|
|
2014-06-17 11:05:56 -04:00
|
|
|
Slider generates the same events as wxScrollBar but in practice the most
|
|
|
|
convenient way to process wxSlider updates is by handling the
|
|
|
|
slider-specific @c wxEVT_SLIDER event which carries wxCommandEvent
|
|
|
|
containing just the latest slider position.
|
2008-03-08 09:43:31 -05:00
|
|
|
|
2008-03-08 08:52:38 -05:00
|
|
|
@beginStyleTable
|
2008-04-06 10:43:04 -04:00
|
|
|
@style{wxSL_HORIZONTAL}
|
2008-03-08 08:52:38 -05:00
|
|
|
Displays the slider horizontally (this is the default).
|
2008-04-06 10:43:04 -04:00
|
|
|
@style{wxSL_VERTICAL}
|
2008-03-08 08:52:38 -05:00
|
|
|
Displays the slider vertically.
|
2008-04-06 10:43:04 -04:00
|
|
|
@style{wxSL_AUTOTICKS}
|
2009-11-14 09:25:54 -05:00
|
|
|
Displays tick marks. Windows only.
|
|
|
|
@style{wxSL_MIN_MAX_LABELS}
|
2009-11-14 18:14:27 -05:00
|
|
|
Displays minimum, maximum labels (new since wxWidgets 2.9.1).
|
2009-11-14 09:25:54 -05:00
|
|
|
@style{wxSL_VALUE_LABEL}
|
2009-11-14 18:14:27 -05:00
|
|
|
Displays value label (new since wxWidgets 2.9.1).
|
2008-04-06 10:43:04 -04:00
|
|
|
@style{wxSL_LABELS}
|
2009-11-14 18:14:27 -05:00
|
|
|
Displays minimum, maximum and value labels (same as wxSL_VALUE_LABEL
|
|
|
|
and wxSL_MIN_MAX_LABELS together).
|
2008-04-06 10:43:04 -04:00
|
|
|
@style{wxSL_LEFT}
|
2008-03-08 08:52:38 -05:00
|
|
|
Displays ticks on the left and forces the slider to be vertical.
|
2008-04-06 10:43:04 -04:00
|
|
|
@style{wxSL_RIGHT}
|
2008-03-08 08:52:38 -05:00
|
|
|
Displays ticks on the right and forces the slider to be vertical.
|
2008-04-06 10:43:04 -04:00
|
|
|
@style{wxSL_TOP}
|
2008-03-08 08:52:38 -05:00
|
|
|
Displays ticks on the top.
|
2008-04-06 10:43:04 -04:00
|
|
|
@style{wxSL_BOTTOM}
|
2008-03-08 08:52:38 -05:00
|
|
|
Displays ticks on the bottom (this is the default).
|
2008-04-06 10:43:04 -04:00
|
|
|
@style{wxSL_SELRANGE}
|
2008-03-08 08:52:38 -05:00
|
|
|
Allows the user to select a range on the slider. Windows only.
|
2008-04-06 10:43:04 -04:00
|
|
|
@style{wxSL_INVERSE}
|
2011-04-03 16:31:32 -04:00
|
|
|
Inverses the minimum and maximum endpoints on the slider. Not
|
2008-03-08 08:52:38 -05:00
|
|
|
compatible with wxSL_SELRANGE.
|
|
|
|
@endStyleTable
|
2008-03-08 09:43:31 -05:00
|
|
|
|
2009-11-14 18:15:27 -05:00
|
|
|
Notice that @c wxSL_LEFT, @c wxSL_TOP, @c wxSL_RIGHT and @c wxSL_BOTTOM
|
|
|
|
specify the position of the slider ticks in MSW implementation and that the
|
|
|
|
slider labels, if any, are positioned on the opposite side. So, to have a
|
|
|
|
label on the left side of a vertical slider, @b wxSL_RIGHT must be used (or
|
|
|
|
none of these styles at all should be specified as left and top are default
|
|
|
|
positions for the vertical and horizontal sliders respectively).
|
|
|
|
|
2009-02-18 12:58:51 -05:00
|
|
|
@beginEventEmissionTable{wxScrollEvent}
|
2008-10-04 16:49:51 -04:00
|
|
|
You can use EVT_COMMAND_SCROLL... macros with window IDs for when intercepting
|
|
|
|
scroll events from controls, or EVT_SCROLL... macros without window IDs for
|
|
|
|
intercepting scroll events from the receiving window -- except for this,
|
|
|
|
the macros behave exactly the same.
|
|
|
|
@event{EVT_SCROLL(func)}
|
|
|
|
Process all scroll events.
|
|
|
|
@event{EVT_SCROLL_TOP(func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_TOP scroll-to-top events (minimum position).
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_SCROLL_BOTTOM(func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_BOTTOM scroll-to-bottom events (maximum position).
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_SCROLL_LINEUP(func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_LINEUP line up events.
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_SCROLL_LINEDOWN(func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_LINEDOWN line down events.
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_SCROLL_PAGEUP(func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_PAGEUP page up events.
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_SCROLL_PAGEDOWN(func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_PAGEDOWN page down events.
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_SCROLL_THUMBTRACK(func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_THUMBTRACK thumbtrack events
|
2008-10-04 16:49:51 -04:00
|
|
|
(frequent events sent as the user drags the thumbtrack).
|
|
|
|
@event{EVT_SCROLL_THUMBRELEASE(func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_THUMBRELEASE thumb release events.
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_SCROLL_CHANGED(func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_CHANGED end of scrolling events (MSW only).
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_COMMAND_SCROLL(id, func)}
|
|
|
|
Process all scroll events.
|
|
|
|
@event{EVT_COMMAND_SCROLL_TOP(id, func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_TOP scroll-to-top events (minimum position).
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_COMMAND_SCROLL_BOTTOM(id, func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_BOTTOM scroll-to-bottom events (maximum position).
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_COMMAND_SCROLL_LINEUP(id, func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_LINEUP line up events.
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_COMMAND_SCROLL_LINEDOWN(id, func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_LINEDOWN line down events.
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_COMMAND_SCROLL_PAGEUP(id, func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_PAGEUP page up events.
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_COMMAND_SCROLL_PAGEDOWN(id, func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_PAGEDOWN page down events.
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_COMMAND_SCROLL_THUMBTRACK(id, func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_THUMBTRACK thumbtrack events
|
2008-10-04 16:49:51 -04:00
|
|
|
(frequent events sent as the user drags the thumbtrack).
|
|
|
|
@event{EVT_COMMAND_SCROLL_THUMBRELEASE(func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_THUMBRELEASE thumb release events.
|
2008-10-04 16:49:51 -04:00
|
|
|
@event{EVT_COMMAND_SCROLL_CHANGED(func)}
|
2011-01-06 14:52:14 -05:00
|
|
|
Process @c wxEVT_SCROLL_CHANGED end of scrolling events (MSW only).
|
2011-03-15 07:10:34 -04:00
|
|
|
@event{EVT_SLIDER(id, func)}
|
2013-04-25 06:11:03 -04:00
|
|
|
Process @c wxEVT_SLIDER which is generated after any
|
2011-03-15 07:10:34 -04:00
|
|
|
change of wxSlider position in addition to one of the events above.
|
2014-06-17 11:05:56 -04:00
|
|
|
Notice that the handler of this event receives a wxCommandEvent as
|
|
|
|
argument and not wxScrollEvent, as all the other handlers.
|
2008-10-04 16:49:51 -04:00
|
|
|
@endEventTable
|
|
|
|
|
|
|
|
@section slider_diff The difference between EVT_SCROLL_THUMBRELEASE and EVT_SCROLL_CHANGED
|
|
|
|
|
|
|
|
The EVT_SCROLL_THUMBRELEASE event is only emitted when actually dragging the
|
|
|
|
thumb using the mouse and releasing it (This EVT_SCROLL_THUMBRELEASE event
|
|
|
|
is also followed by an EVT_SCROLL_CHANGED event).
|
|
|
|
|
|
|
|
The EVT_SCROLL_CHANGED event also occurs when using the keyboard to change
|
|
|
|
the thumb position, and when clicking next to the thumb
|
|
|
|
(In all these cases the EVT_SCROLL_THUMBRELEASE event does not happen).
|
|
|
|
In short, the EVT_SCROLL_CHANGED event is triggered when scrolling/ moving
|
|
|
|
has finished independently of the way it had started.
|
|
|
|
Please see the widgets sample ("Slider" page) to see the difference between
|
|
|
|
EVT_SCROLL_THUMBRELEASE and EVT_SCROLL_CHANGED in action.
|
|
|
|
|
2008-03-08 08:52:38 -05:00
|
|
|
@library{wxcore}
|
|
|
|
@category{ctrl}
|
2012-11-03 14:32:50 -04:00
|
|
|
@appearance{slider}
|
2008-03-08 09:43:31 -05:00
|
|
|
|
2009-02-17 19:19:22 -05:00
|
|
|
@see @ref overview_events, wxScrollBar
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
|
|
|
class wxSlider : public wxControl
|
|
|
|
{
|
|
|
|
public:
|
2008-05-26 03:33:59 -04:00
|
|
|
/**
|
|
|
|
Default constructor
|
|
|
|
*/
|
|
|
|
wxSlider();
|
2008-10-04 10:30:56 -04:00
|
|
|
|
2008-03-08 08:52:38 -05:00
|
|
|
/**
|
|
|
|
Constructor, creating and showing a slider.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-08 09:43:31 -05:00
|
|
|
@param parent
|
2008-03-09 08:33:59 -04:00
|
|
|
Parent window. Must not be @NULL.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param id
|
2008-03-09 08:33:59 -04:00
|
|
|
Window identifier. The value wxID_ANY indicates a default value.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param value
|
2008-03-09 08:33:59 -04:00
|
|
|
Initial position for the slider.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param minValue
|
2008-03-09 08:33:59 -04:00
|
|
|
Minimum slider position.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param maxValue
|
2008-03-09 08:33:59 -04:00
|
|
|
Maximum slider position.
|
2008-10-05 07:24:00 -04:00
|
|
|
@param pos
|
2009-04-21 07:21:36 -04:00
|
|
|
Window position.
|
|
|
|
If ::wxDefaultPosition is specified then a default position is chosen.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param size
|
2009-04-21 07:21:36 -04:00
|
|
|
Window size.
|
|
|
|
If ::wxDefaultSize is specified then a default size is chosen.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param style
|
2008-03-09 08:33:59 -04:00
|
|
|
Window style. See wxSlider.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param validator
|
2008-03-09 08:33:59 -04:00
|
|
|
Window validator.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param name
|
2008-03-09 08:33:59 -04:00
|
|
|
Window name.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see Create(), wxValidator
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-03-08 09:43:31 -05:00
|
|
|
wxSlider(wxWindow* parent, wxWindowID id, int value,
|
|
|
|
int minValue, int maxValue,
|
2008-10-05 07:24:00 -04:00
|
|
|
const wxPoint& pos = wxDefaultPosition,
|
2008-03-08 09:43:31 -05:00
|
|
|
const wxSize& size = wxDefaultSize,
|
|
|
|
long style = wxSL_HORIZONTAL,
|
|
|
|
const wxValidator& validator = wxDefaultValidator,
|
2008-11-13 16:32:53 -05:00
|
|
|
const wxString& name = wxSliderNameStr);
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Destructor, destroying the slider.
|
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual ~wxSlider();
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Clears the selection, for a slider with the @b wxSL_SELRANGE style.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-11-21 19:21:10 -05:00
|
|
|
@onlyfor{wxmsw}
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual void ClearSel();
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Clears the ticks.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-11-21 19:21:10 -05:00
|
|
|
@onlyfor{wxmsw}
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual void ClearTicks();
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
2008-10-04 16:49:51 -04:00
|
|
|
Used for two-step slider construction.
|
|
|
|
See wxSlider() for further details.
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-10-28 11:36:26 -04:00
|
|
|
bool Create(wxWindow* parent, wxWindowID id, int value, int minValue,
|
|
|
|
int maxValue, const wxPoint& point = wxDefaultPosition,
|
|
|
|
const wxSize& size = wxDefaultSize, long style = wxSL_HORIZONTAL,
|
2008-03-08 08:52:38 -05:00
|
|
|
const wxValidator& validator = wxDefaultValidator,
|
2008-10-28 11:36:26 -04:00
|
|
|
const wxString& name = wxSliderNameStr);
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Returns the line size.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see SetLineSize()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual int GetLineSize() const;
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Gets the maximum slider value.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see GetMin(), SetRange()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual int GetMax() const;
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Gets the minimum slider value.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see GetMin(), SetRange()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual int GetMin() const;
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Returns the page size.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see SetPageSize()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual int GetPageSize() const;
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Returns the selection end point.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-11-21 19:21:10 -05:00
|
|
|
@onlyfor{wxmsw}
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see GetSelStart(), SetSelection()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual int GetSelEnd() const;
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Returns the selection start point.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-11-21 19:21:10 -05:00
|
|
|
@onlyfor{wxmsw}
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see GetSelEnd(), SetSelection()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual int GetSelStart() const;
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Returns the thumb length.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-11-21 19:21:10 -05:00
|
|
|
@onlyfor{wxmsw}
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see SetThumbLength()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual int GetThumbLength() const;
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Returns the tick frequency.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-11-21 19:21:10 -05:00
|
|
|
@onlyfor{wxmsw}
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see SetTickFreq()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual int GetTickFreq() const;
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Gets the current slider value.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see GetMin(), GetMax(), SetValue()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual int GetValue() const;
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Sets the line size for the slider.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-08 09:43:31 -05:00
|
|
|
@param lineSize
|
2008-10-04 16:49:51 -04:00
|
|
|
The number of steps the slider moves when the user moves it up
|
|
|
|
or down a line.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see GetLineSize()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual void SetLineSize(int lineSize);
|
2008-03-08 08:52:38 -05:00
|
|
|
|
2013-05-16 13:57:01 -04:00
|
|
|
|
|
|
|
/**
|
|
|
|
Sets the minimum slider value.
|
|
|
|
|
|
|
|
@param minValue
|
|
|
|
The new bottom end of the slider range.
|
|
|
|
|
|
|
|
@see GetMin(), SetRange()
|
|
|
|
*/
|
|
|
|
void SetMin( int minValue );
|
|
|
|
|
|
|
|
/**
|
|
|
|
Sets the maximum slider value.
|
|
|
|
|
|
|
|
@param maxValue
|
|
|
|
The new top end of the slider range.
|
|
|
|
|
|
|
|
@see GetMax(), SetRange()
|
|
|
|
*/
|
|
|
|
void SetMax( int maxValue );
|
|
|
|
|
2008-03-08 08:52:38 -05:00
|
|
|
/**
|
|
|
|
Sets the page size for the slider.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-08 09:43:31 -05:00
|
|
|
@param pageSize
|
2008-03-09 08:33:59 -04:00
|
|
|
The number of steps the slider moves when the user pages up or down.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see GetPageSize()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual void SetPageSize(int pageSize);
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Sets the minimum and maximum slider values.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see GetMin(), GetMax()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual void SetRange(int minValue, int maxValue);
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Sets the selection.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-08 09:43:31 -05:00
|
|
|
@param startPos
|
2008-03-09 08:33:59 -04:00
|
|
|
The selection start position.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param endPos
|
2008-03-09 08:33:59 -04:00
|
|
|
The selection end position.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-11-21 19:21:10 -05:00
|
|
|
@onlyfor{wxmsw}
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see GetSelStart(), GetSelEnd()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual void SetSelection(int startPos, int endPos);
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Sets the slider thumb length.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-08 09:43:31 -05:00
|
|
|
@param len
|
2008-03-09 08:33:59 -04:00
|
|
|
The thumb length.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-11-21 19:21:10 -05:00
|
|
|
@onlyfor{wxmsw}
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see GetThumbLength()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual void SetThumbLength(int len);
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Sets a tick position.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-08 09:43:31 -05:00
|
|
|
@param tickPos
|
2008-03-09 08:33:59 -04:00
|
|
|
The tick position.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-11-21 19:21:10 -05:00
|
|
|
@onlyfor{wxmsw}
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see SetTickFreq()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual void SetTick(int tickPos);
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Sets the tick mark frequency and position.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-08 09:43:31 -05:00
|
|
|
@param n
|
2008-03-09 08:33:59 -04:00
|
|
|
Frequency. For example, if the frequency is set to two, a tick mark is
|
2008-10-04 16:49:51 -04:00
|
|
|
displayed for every other increment in the slider's range.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-11-21 19:21:10 -05:00
|
|
|
@onlyfor{wxmsw}
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see GetTickFreq()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2011-02-05 11:36:30 -05:00
|
|
|
virtual void SetTickFreq(int n);
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Sets the slider position.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-08 09:43:31 -05:00
|
|
|
@param value
|
2008-03-09 08:33:59 -04:00
|
|
|
The slider position.
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-09-27 07:21:10 -04:00
|
|
|
virtual void SetValue(int value);
|
2008-03-08 08:52:38 -05:00
|
|
|
};
|
2008-03-10 11:24:38 -04:00
|
|
|
|