• download
  • documentation
  • forums
  • demo
  • contact
  • blog

meteora

javascript widgets

Documentation

  • Autocomplete
  • Bubble
  • Calendar
  • Carousel
  • Datagrid
  • Dialog
  • Editor
  • Effect
  • Filebrowser
  • Form
  • Jsonrpc
  • Menu
  • Notebook
  • Picbox
  • Popup
  • Searchlist
  • Selection
  • Spinbutton
  • Tablesort
  • Toolbox
  • Treeview

What does this control do?

This control is an input element and a pair of buttons to increment or decrease its value.

For an usage example check out the Meteora.Spinbutton demo.

How to use

In order to use this control, paste this line of javascript right at the beginning of your script tag:

Meteora.uses('Meteora.Spinbutton');

You'll need to associate an input with this control.

<input id="spinbutton_input">

You may then by able to invoke the Datagrid this way:

new Spinbutton(
  // ELEMENT
  'spinbutton_input',
  {
    // OPTIONS
    'defaultValue': 0.0,
    'maxValue': 1,
    'minValue': 0,
    'step': 0.1
  }
);

Options

defaultValue: float

The value the input will display by default.

minValue: float

The lowest value.

maxValue: float

The maximum value.

step: float

Step for increasing or decreasing.

cycle: boolean

Set true is you want to cycle extreme values.

values: array

An array of values, the index of the array will be the Spinbutton's value. Useful for displaying week days.

onChange: event

Function to call when the user changes the value of the Spinbutton.

Methods

setValue(number)

Sets a value for the Spinbutton's input.

Copyright © 2007-2009 Astrata Software.