EZ
Up Prev Next Contents


3.8 Sliders

A slider widget is a sunken rectangle on which a button moves in one dimension, either vertically or horizontally. A slider appears as a linear scale with optional numerical labes and an optional short label. Sliders are typically used to edit a numerical value. The user adjust the value by clicking mouse button 1 or button 2 in the slider, or by dragging the slider button with mouse button 1. If a slider has callbacks, they are invoked whenever its numeric value changes.

Widget Info

Symbolic widget type EZ_WIDGET_VERTICAL_SLIDER
Default class name "VerticalSlider"
Default instance name "verticalSlider"

Symbolic widget type EZ_WIDGET_HORIZONTAL_SLIDER
Default class name "HorizontalSlider"
Default instance name "horizontalSlider"

Widget Interface Routines

void EZ_SetSliderValue(EZ_Widget *widget, float value);

set the slider value.

float EZ_GetSliderValue(EZ_Widget *widget);

retrieve the slider value.

void EZ_SetSliderRange(EZ_Widget *widget, float f, float t);

set the range of a slider.

Screenshot

Resources

Config_Option ResourceName DefaultValue
EZ_CLASS class "VerticalSlider"
or "HorizontalSlider"
EZ_NAME name "verticalSlider"
or "horizontalSlider"

EZ_X x
EZ_Y y
EZ_WIDTH width
EZ_HEIGHT height

EZ_LOCATION location
EZ_SIZE size
EZ_GEOMETRY geometry

EZ_WIDTH_HINT widthHint
EZ_HEIGHT_HINT heightHint
EZ_SIZE_HINT sizeHint

EZ_BORDER_WIDTH borderWidth 0
EZ_BORDER_TYPE borderType none
EZ_FOCUS_PAD focusPad 2

EZ_PADX padx 8
EZ_PADY pady 6
EZ_IPADX iPadx 0
EZ_IPADY iPady 0

EZ_EXPAND expand false
EZ_PROPAGATE propagate true
EZ_TRANSIENT transient false

EZ_FONT_ID fontID 3
EZ_FONT_NAME fontName "*Bold*"
EZ_LABEL_STRING labelString null
EZ_TEXT_LINE_LENGTH textLineLength 30

EZ_CURSOR cursor "XC_left_ptr"
EZ_BUBBLE_STRING bubbleString null

EZ_CALLBACK N/A null null
EZ_MOTION_CALLBACK N/A null null
EZ_DESTROY_CALLBACK N/A null null
EZ_EVENT_HANDLER N/A null null

EZ_FOREGROUND foreground "black"
EZ_BACKGROUND background "gray74
EZ_BG_IMAGE_FILE bgImageFile null
EZ_BG_PIXMAP N/A none

EZ_BG_IMAGE_FILE_B bgImageFileB null
EZ_BG_PIXMAP_B N/A none
EZ_CLIENT_PTR_DATA N/A null
EZ_CLIENT_INT_DATA clientIntData 0

EZ_DND_DRAG_CURSOR dndDragCursor none
EZ_DND_BUBBLE_STRING dndBubbleString null

EZ_BACKING_STORE backingStore false

EZ_SLIDER_LENGTH sliderLength 100
EZ_SLIDER_WIDTH sliderWidth 16
EZ_SLIDER_BORDER_WIDTH sliderBorderWidth 2
EZ_SLIDER_RESOLUTION sliderResolution -1.0
EZ_SLIDER_RANGE sliderRange 0.0 1.0
EZ_SLIDER_INIT_VALUE sliderInitialValue 0.0
EZ_SLIDER_DISPLAY_VALUE sliderDisplayValue true
EZ_GRIP_BUTTON_STYLE gripButtonStyle 0


Up Prev Next Contents

HTML Documentation Maintainance:Arturo Espinosa <arturo@nuclecu.unam.mx>