de.lessvoid.nifty.controls.scrollbar
Interface ScrollbarView


public interface ScrollbarView

The ScrollbarView is used to update the visual representation of the scrollbar.

Author:
void

Method Summary
 int filter(int pixelX, int pixelY)
          Filter the correct value for the given view (horizontal or vertical) from the given mouse coordinates.
 int getAreaSize()
          Get the size of the Scrollbar area.
 int getMinHandleSize()
          Returns the minimum size this View can show the handle without distortion.
 void setHandle(int pos, int size)
          Set the position and the size of the handle.
 void valueChanged(float value)
          That's a callback that is called when the value has been changed.
 

Method Detail

getAreaSize

int getAreaSize()
Get the size of the Scrollbar area. This is the area in pixel that is available to scroll around.

Returns:
pixel size value

getMinHandleSize

int getMinHandleSize()
Returns the minimum size this View can show the handle without distortion. The handle will never be smaller than this value.

Returns:
minimum handle size

setHandle

void setHandle(int pos,
               int size)
Set the position and the size of the handle.

Parameters:
pos - position
size - size

valueChanged

void valueChanged(float value)
That's a callback that is called when the value has been changed.

Parameters:
value - the new value

filter

int filter(int pixelX,
           int pixelY)
Filter the correct value for the given view (horizontal or vertical) from the given mouse coordinates.

Parameters:
pixelX - x position
pixelY - y position
Returns:
x or y specific to implementation


Copyright © 2011. All Rights Reserved.