-
Notifications
You must be signed in to change notification settings - Fork 16
/
knob.jquery.txt
40 lines (36 loc) · 3.5 KB
/
knob.jquery.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
KNOB
JQ.knob(OBJ) #JQ is an <input>
#Nice control to choose a number (DOUBLE|UINT), looking circular.
#Works on mobile, and using keyboard.
#OBJ can also be as HTML attribute data-VAR="VAL"
#OBJ:
# - min|max NUM (def: 0|100)
# - step NUM (def: 1)
# - angleOffset NUM (def: 0): starting angle
# - angleArc NUM (def: 360): total angle
# - readOnly BOOL (def: false): only change through programatic change
# - rotation STR (def: "clockwise")
# - cursor BOOL|NUM: if true, different style (show only current part of circle, not all way
# through). NUM: select thickness.
# - thickness NUM: of the bar
# - width NUM: of the circle
# - lineCap "butt|round" (def: "butt")
# - displayInput BOOL (def: true): show current number
# - displayPrevious BOOL (def: false): show previous range
# - fgColor|bgColor|inputColor COLOR_STR
# - font FONT_STR (font family)
# - fontWeight NUM
# - release(NUM): when stopped changing
# - change(NUM): continuously when changing
# - cancel(): on Esc
# - format(STR)->STR: to change model and view values
# - draw(): when initializing the canvas, to personalize the look. Look at code to
# check how this can be implemented.
#Can dynamically change OBJ with:
# - JQ.val(NUM).trigger("change")
# - JQ.trigger("configure",OBJ)
ANGULAR-KNOB #Angular directive for Knob. MODULE is "ui.knob"
#Called <knob knob-data="EXPR" knob-options="OBJ_EXPR">
#Version 1.0.3