Class: TScrollbarState

Declaration: Scrollbar.h

Taxonomy Categories:

Member Functions:


Interface Category:

API.

Inherits From:

MCollectible

Inherited By:

None.

Purpose:

TScrollbarState stores and manipulates the state information associated with a scroll bar. It is used by TScrollBar to manage details such as line size, page size, and scroll bar tracking.

Instantiation:

Allocate on the heap or the stack.

Deriving Classes:

Derive classes from TScrollbarState to add your own scroll bar features.

Concurrency:

Not multithread safe.

Resource Use:

No special requirements.

Other Considerations:

None.

Member Function: TScrollbarState::TScrollbarState

  1. TScrollbarState ()
  2. TScrollbarState (const TScrollbarState &)

Interface Category:

API.

Purpose:

  1. Default constructor.
  2. Copy constructor.

Calling Context:

  1. Called by the stream-in operators.
  2. Called to copy an object.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::~TScrollbarState

virtual ~ TScrollbarState ()

Interface Category:

API.

Purpose:

Destructor.

Calling Context:

Called to destroy an object.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::operator=

TScrollbarState & operator =(const TScrollbarState &)

Interface Category:

API.

Purpose:

Assignment operator.

Calling Context:

Called when an object is assigned to another compatible object.

Parameters:

Return Value:

A non-const reference to the left-hand side object.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::operator>>=

virtual TStream & operator >>=(TStream &) const

Interface Category:

API.

Purpose:

Stream-out operator.

Calling Context:

Called to stream out data.

Parameters:

Return Value:

Returns a reference to the stream to which the object streams itself.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::operator<<=

virtual TStream & operator <<= (TStream &)

Interface Category:

API.

Purpose:

Stream-in operator.

Calling Context:

Called to stream in data.

Parameters:

Return Value:

Returns a reference to the stream from which the object streams itself.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::SetControlLayout

virtual void SetControlLayout (MControl :: ELayout layout)

Interface Category:

API.

Purpose:

Sets the control layout for this scroll bar state.

Calling Context:

Call this function directly to set the control layout for this scroll bar state.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::GetControlLayout

virtual MControl :: ELayout GetControlLayout () const

Interface Category:

API.

Purpose:

Gets the control layout for this scroll bar state.

Calling Context:

Call this function directly to get the control layout for this scroll bar state.

Parameters:

Return Value:

A const reference to the control layout for this scroll bar.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::SetLineSize

virtual void SetLineSize (double newValue)

Interface Category:

API.

Purpose:

Sets the float value increment or decrement that results when the scroll bar's arrow buttons are pressed.

Calling Context:

Call this function directly to set the float value increment or decrement that will result when the scroll bar's arrow buttons are pressed.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::GetLineSize

virtual double GetLineSize () const

Interface Category:

API.

Purpose:

Returns the line size.

Calling Context:

Call this function directly to obtain the line size.

Parameters:

Return Value:

The line size.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::SetPageSize

virtual void SetPageSize (double newValue)

Interface Category:

API.

Purpose:

Sets the float value increment or decrement that will result when the user clicks in the scroll bar trough.

Calling Context:

Call this function directly to set the the float value increment or decrement that will result when the user clicks in the scroll bar trough.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::GetPageSize

virtual double GetPageSize () const

Interface Category:

API.

Purpose:

Returns the current page size.

Calling Context:

Call this function directly to obtain the current page size.

Parameters:

Return Value:

The current page size of the scrollable area.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::SetFloatValue

virtual void SetFloatValue (double newValue)

Interface Category:

API.

Purpose:

Sets the value for the scroll bar state.

Calling Context:

Call this function directly to set the value for the scroll bar state.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::GetFloatValue

virtual double GetFloatValue () const

Interface Category:

API.

Purpose:

Returns the value for the scroll bar state.

Calling Context:

Call this function directly to obtain the float value for the scroll bar state.

Parameters:

Return Value:

The current float value for the scroll bar state.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::SetFloatConstraints

virtual void SetFloatConstraints (double minimum, double maximum, double intervalSize)

Interface Category:

API.

Purpose:

Sets the constraints currently applied to this float control state's value. The first two parameters indicate the range within which this float control state's value must fall. The third parameter indicates the discrete interval by which to constrain this float control state's value. For example, if the interval is 1.0, then the float control state's value is constrained to whole numbers. An interval of 0.0 indicates that there is no interval constraint.

Calling Context:

Called from ConstrainValue. You can also call this function directly.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::GetFloatConstraints

virtual void GetFloatConstraints (double & minimum, double & maximum, double & intervalSize) const

Interface Category:

API.

Purpose:

Gets the constraints currently applied to this float control state's value. The first two parameters indicate the range within which this float control state's value must fall. The third parameter indicates the discrete interval by which to constrain this float control state's value. For example, if the interval is 1.0, then the float control state's value is constrained to whole numbers. An interval of 0.0 indicates that there is no interval constraint.

Calling Context:

Called from ConstrainValue. You can also call this function directly.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::SetScrollbarTrackingEnabled

virtual void SetScrollbarTrackingEnabled (bool shouldTrack)

Interface Category:

API.

Purpose:

Enables or disables scroll bar tracking.

Calling Context:

Call this function directly to enable or disable scroll bar tracking.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TScrollbarState::IsScrollbarTrackingEnabled

virtual bool IsScrollbarTrackingEnabled () const

Interface Category:

API.

Purpose:

Determines if scroll bar tracking is enabled.

Calling Context:

Call this function directly to determine if scroll bar tracking is enabled.

Parameters:

Return Value:

Returns true if scroll bar tracking is enabled.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.