### ISliderDrawHandler

  The ISliderDrawHandler class draws slider and progress indicator control objects. You can draw the following:

  - Slider shaft
  - Ribbon strip
  - Slider arm
  - Slider background

  To use this handler, you must create the slider or progress indicator with the handleDrawItem style specified, or you must set this style by using IProgressIndicator::enableDrawItem after the slider or progress indicator is created. See IProgressIndicator Styles for information about the handleDrawItem style and enableDrawItem for information about that function.

  Create a handler derived from ISliderDrawHandler and attach it to a slider or progress indicator. You can do this by calling IHandler::handleEventsFor to pass the slider or progress indicator to the slider draw handler. See handleEventsFor for information about that function.

  When the slider draw handler receives a slider draw event, it creates an IDrawItemEvent object and routes that object to the appropriate ISliderDrawHandler virtual function. Override these virtual functions to supply your own specialized processing of a slider draw event. See IDrawItemEvent for information about that class.

  The return value from the virtual functions specifies whether the slider draw event should be passed on for additional processing, as follows:

  Return Value :ddhd.Meaning
  true
    The slider draw event requires no additional processing. Do not pass it to another handler.
  false
    The slider draw event requires additional processing. Pass the slider draw event to the next handler for additional processing, as follows:
    - If there is another handler for the slider or progress indicator, pass the slider draw event to the next handler.
    - If this is the last handler for the slider or progress indicator, call the IWindow::dispatch function to dispatch the slider draw event to the slider's or progress indicator's owner window. See dispatch for information about that function.
    - If this is the last handler for the owner window, call the IWindow::defaultProcedure function to process the slider draw event. See defaultProcedure for information about that function.

#### AIX Considerations

  Owner draw progress indicators and sliders are not supported in the AIX environment. This class is not available in that environment.

#### Windows Considerations

  Owner draw progress indicators and sliders are only supported for IProgressIndicator::pmCompatible progress indicators and sliders in the Windows environment.

### ISliderDrawHandler - Member Functions and Data by Group

### Constructors & Destructor

You can construct and destruct objects of this class.

~ISliderDrawHandler

      public:
      virtual ~ISliderDrawHandler()

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | No

ISliderDrawHandler

      public:
      ISliderDrawHandler()

  Used to construct objects of this class. This is the default constructor and accepts no parameters.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | No

### Event Dispatching

Event-dispatching members evaluate an event to determine if it is appropriate for this handler object to process it. If it is, it calls the virtual function used to process the event.

dispatchHandlerEvent

      protected:
      virtual bool dispatchHandlerEvent(IEvent& event)

  If a slider draw event is received, the appropriate virtual function is called.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | No

Windows Considerations

  In the Windows environment, only PM compatible progress indicators and sliders support the handleDrawItem style. This function will never be called for native Windows progress indicators and sliders.

### Event Processing

Event-processing members must be supplied to process slider drawing events You can override these virtual members in a derived class.

drawArm

      protected:
      virtual bool drawArm(IDrawItemEvent& event)

  Draws the slider's arm. The application overrides this function to handle the drawing.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | No

Windows Considerations

  In the Windows environment, only PM compatible progress indicators and sliders support the handleDrawItem style. This function will never be called for native Windows progress indicators and sliders.

drawBackground

      protected:
      virtual bool drawBackground(IDrawItemEvent& event)

  Draws the slider's background. The application overrides this function to handle the drawing.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | No

Windows Considerations

  In the Windows environment, only PM compatible progress indicators and sliders support the handleDrawItem style. This function will never be called for native Windows progress indicators and sliders.

drawRibbonStrip

      protected:
      virtual bool drawRibbonStrip(IDrawItemEvent& event)

  Draws the slider's ribbon strip. The application overrides this function to handle the drawing.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | No

Windows Considerations

  In the Windows environment, only PM compatible progress indicators and sliders support the handleDrawItem style. This function will never be called for native Windows progress indicators and sliders.

drawShaft

      protected:
      virtual bool drawShaft(IDrawItemEvent& event)

  Draws the slider's shaft. The application overrides this function to handle the drawing.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | No

Windows Considerations

  In the Windows environment, only PM compatible progress indicators and sliders support the handleDrawItem style. This function will never be called for native Windows progress indicators and sliders.

### ISliderDrawHandler - Inherited Member Functions and Data

#### Inherited Public Functions

  IHandler

  -     virtual ~IHandler()

  -     virtual IString asDebugInfo() const

  -     virtual IString asString() const

  -     virtual IHandler& disable()

  -     virtual IHandler& enable(bool enable = true)

  -     virtual IHandler& handleEventsFor(IWindow* window)

  -     IHandler()

  -     bool isEnabled() const

  -     virtual IHandler& stopHandlingEventsFor(IWindow* window)

#### Inherited Public Data

  - None

#### Inherited Protected Functions

  IHandler

  -     virtual IEventResult defaultProcedure(IEvent& event)

  -     virtual bool dispatchHandlerEvent(IEvent& event) = 0

#### Inherited Protected Data

  - None