X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/a660d684eda27638bca0384b2058911a31c8e845..9379c0d752144826342fa2688a77aa5cccea3d9b:/docs/latex/wx/slider.tex diff --git a/docs/latex/wx/slider.tex b/docs/latex/wx/slider.tex index e42ae9b619..898f67acd6 100644 --- a/docs/latex/wx/slider.tex +++ b/docs/latex/wx/slider.tex @@ -3,8 +3,7 @@ A slider is a control with a handle which can be pulled back and forth to change the value. -In Windows versions below Windows 95, a scrollbar is used to simulate the slider. In Windows 95, -the track bar control is used. +On Windows, the track bar control is used. Slider events are handled in the same way as a scrollbar. @@ -15,38 +14,46 @@ Slider events are handled in the same way as a scrollbar. \helpref{wxEvtHandler}{wxevthandler}\\ \helpref{wxObject}{wxobject} +\wxheading{Include files} + + + \wxheading{Window styles} \twocolwidtha{5cm} \begin{twocollist}\itemsep=0pt -\twocolitem{\windowstyle{wxSL\_HORIZONTAL}}{Displays the slider horizontally.} +\twocolitem{\windowstyle{wxSL\_HORIZONTAL}}{Displays the slider horizontally (this is the default).} \twocolitem{\windowstyle{wxSL\_VERTICAL}}{Displays the slider vertically.} \twocolitem{\windowstyle{wxSL\_AUTOTICKS}}{Displays tick marks.} \twocolitem{\windowstyle{wxSL\_LABELS}}{Displays minimum, maximum and value labels.} -\twocolitem{\windowstyle{wxSL\_LEFT}}{Displays ticks on the left, if a vertical slider.} -\twocolitem{\windowstyle{wxSL\_RIGHT}}{Displays ticks on the right, if a vertical slider.} -\twocolitem{\windowstyle{wxSL\_TOP}}{Displays ticks on the top, if a horizontal slider.} -\twocolitem{\windowstyle{wxSL\_SELRANGE}}{Allows the user to select a range on the slider. Windows 95 only.} +\twocolitem{\windowstyle{wxSL\_LEFT}}{Displays ticks on the left and forces the slider to be vertical.} +\twocolitem{\windowstyle{wxSL\_RIGHT}}{Displays ticks on the right and forces the slider to be vertical.} +\twocolitem{\windowstyle{wxSL\_TOP}}{Displays ticks on the top.} +\twocolitem{\windowstyle{wxSL\_BOTTOM}}{Displays ticks on the bottom (this is the default).} +\twocolitem{\windowstyle{wxSL\_SELRANGE}}{Allows the user to select a range on the slider. Windows only.} +\twocolitem{\windowstyle{wxSL\_INVERSE}}{Inverses the mininum and maximum endpoints on the slider. Not compatible with wxSL\_SELRANGE.} \end{twocollist} See also \helpref{window styles overview}{windowstyles}. +\input scrolevt.inc + \wxheading{See also} \helpref{Event handling overview}{eventhandlingoverview}, \helpref{wxScrollBar}{wxscrollbar} \latexignore{\rtfignore{\wxheading{Members}}} -\membersection{wxSlider::wxSlider}\label{wxsliderconstr} +\membersection{wxSlider::wxSlider}\label{wxsliderctor} \func{}{wxSlider}{\void} Default slider. -\func{}{wxSlider}{\param{wxWindow* }{parent}, \param{const wxWindowID }{id}, \param{const int }{value },\rtfsp -\param{const int}{ minValue}, \param{const int}{ maxValue},\rtfsp +\func{}{wxSlider}{\param{wxWindow* }{parent}, \param{wxWindowID }{id}, \param{int }{value },\rtfsp +\param{int}{ minValue}, \param{int}{ maxValue},\rtfsp \param{const wxPoint\& }{point = wxDefaultPosition}, \param{const wxSize\& }{size = wxDefaultSize},\rtfsp -\param{const long}{ style = wxSL\_HORIZONTAL},\rtfsp +\param{long}{ style = wxSL\_HORIZONTAL},\rtfsp \param{const wxValidator\& }{validator = wxDefaultValidator},\rtfsp \param{const wxString\& }{name = ``slider"}} @@ -76,7 +83,7 @@ Constructor, creating and showing a slider. \helpref{wxSlider::Create}{wxslidercreate}, \helpref{wxValidator}{wxvalidator} -\membersection{wxSlider::\destruct{wxSlider}} +\membersection{wxSlider::\destruct{wxSlider}}\label{wxsliderdtor} \func{void}{\destruct{wxSlider}}{\void} @@ -104,14 +111,14 @@ Windows 95 only. \membersection{wxSlider::Create}\label{wxslidercreate} -\func{bool}{Create}{\param{wxWindow* }{parent}, \param{const wxWindowID }{id}, \param{const int }{value },\rtfsp -\param{const int}{ minValue}, \param{const int}{ maxValue},\rtfsp +\func{bool}{Create}{\param{wxWindow* }{parent}, \param{wxWindowID }{id}, \param{int }{value },\rtfsp +\param{int}{ minValue}, \param{int}{ maxValue},\rtfsp \param{const wxPoint\& }{point = wxDefaultPosition}, \param{const wxSize\& }{size = wxDefaultSize},\rtfsp -\param{const long}{ style = wxSL\_HORIZONTAL},\rtfsp +\param{long}{ style = wxSL\_HORIZONTAL},\rtfsp \param{const wxValidator\& }{validator = wxDefaultValidator},\rtfsp \param{const wxString\& }{name = ``slider"}} -Used for two-step slider construction. See \helpref{wxSlider::wxSlider}{wxsliderconstr}\rtfsp +Used for two-step slider construction. See \helpref{wxSlider::wxSlider}{wxsliderctor}\rtfsp for further details. \membersection{wxSlider::GetLineSize}\label{wxslidergetlinesize} @@ -221,40 +228,9 @@ Gets the current slider value. \helpref{wxSlider::GetMin}{wxslidergetmin}, \helpref{wxSlider::GetMax}{wxslidergetmax},\rtfsp \helpref{wxSlider::SetValue}{wxslidersetvalue} -\membersection{wxSlider::SetRange}\label{wxslidersetrange} - -\func{void}{SetRange}{\param{const int}{ minValue}, \param{const int}{ maxValue}} - -Sets the minimum and maximum slider values. - -\wxheading{See also} - -\helpref{wxSlider::GetMin}{wxslidergetmin}, \helpref{wxSlider::GetMax}{wxslidergetmax} - -\membersection{wxSlider::SetTickFreq}\label{wxslidersettickfreq} - -\func{void}{SetTickFreq}{\param{const int }{n}, \param{const int }{pos}} - -Sets the tick mark frequency and position. - -\wxheading{Parameters} - -\docparam{n}{Frequency. For example, if the frequency is set to two, a tick mark is displayed for -every other increment in the slider's range.} - -\docparam{pos}{Position. Must be greater than zero. TODO: what is this for?} - -\wxheading{Remarks} - -Windows 95 only. - -\wxheading{See also} - -\helpref{wxSlider::GetTickFreq}{wxslidergettickfreq} - \membersection{wxSlider::SetLineSize}\label{wxslidersetlinesize} -\func{void}{SetLineSize}{\param{const int }{lineSize}} +\func{void}{SetLineSize}{\param{int }{lineSize}} Sets the line size for the slider. @@ -268,7 +244,7 @@ Sets the line size for the slider. \membersection{wxSlider::SetPageSize}\label{wxslidersetpagesize} -\func{void}{SetPageSize}{\param{const int }{pageSize}} +\func{void}{SetPageSize}{\param{int }{pageSize}} Sets the page size for the slider. @@ -280,9 +256,19 @@ Sets the page size for the slider. \helpref{wxSlider::GetPageSize}{wxslidergetpagesize} +\membersection{wxSlider::SetRange}\label{wxslidersetrange} + +\func{void}{SetRange}{\param{int}{ minValue}, \param{int}{ maxValue}} + +Sets the minimum and maximum slider values. + +\wxheading{See also} + +\helpref{wxSlider::GetMin}{wxslidergetmin}, \helpref{wxSlider::GetMax}{wxslidergetmax} + \membersection{wxSlider::SetSelection}\label{wxslidersetselection} -\func{void}{SetSelection}{\param{const int }{startPos}, \param{const int }{endPos}} +\func{void}{SetSelection}{\param{int }{startPos}, \param{int }{endPos}} Sets the selection. @@ -302,7 +288,7 @@ Windows 95 only. \membersection{wxSlider::SetThumbLength}\label{wxslidersetthumblength} -\func{void}{SetThumbLength}{\param{const int }{len}} +\func{void}{SetThumbLength}{\param{int }{len}} Sets the slider thumb length. @@ -320,7 +306,7 @@ Windows 95 only. \membersection{wxSlider::SetTick}\label{wxslidersettick} -\func{void}{SetTick}{\param{const int}{ tickPos}} +\func{void}{SetTick}{\param{int}{ tickPos}} Sets a tick position. @@ -336,9 +322,30 @@ Windows 95 only. \helpref{wxSlider::SetTickFreq}{wxslidersettickfreq} +\membersection{wxSlider::SetTickFreq}\label{wxslidersettickfreq} + +\func{void}{SetTickFreq}{\param{int }{n}, \param{int }{pos}} + +Sets the tick mark frequency and position. + +\wxheading{Parameters} + +\docparam{n}{Frequency. For example, if the frequency is set to two, a tick mark is displayed for +every other increment in the slider's range.} + +\docparam{pos}{Position. Must be greater than zero. TODO: what is this for?} + +\wxheading{Remarks} + +Windows 95 only. + +\wxheading{See also} + +\helpref{wxSlider::GetTickFreq}{wxslidergettickfreq} + \membersection{wxSlider::SetValue}\label{wxslidersetvalue} -\func{void}{SetValue}{\param{const int}{ value}} +\func{void}{SetValue}{\param{int}{ value}} Sets the slider position.