Sg2.9
have increment by mm instand...
Recent RSS
have increment by mm instand of point
From:  Doeke Wartena
Date:  12. April 2010, 14:05

At the moment the values start with 0,353 mm and 2,117 mm instand of 1 and 6.
Also the increment is 0,035 mm instand of 0.1 mm.
How can i fix that?

I know i can use 17.008 instand of 6 for example but that will make my code a lot harder to read and it isn't a nice way as a fix anyway so are there any other ways?

//////////////

var gap;
var mask;
var frame;

var values = {
gap: 0 ,
mask: 1,
frame: 6,
}

var items = {
gap: {
type: 'number', label: 'gap',
value: gap, range: [0, 1200], increment: 0.1,
steppers: true, units: 'millimeter'
},
mask: {
type: 'number', label: 'mask',
value: mask, range: [0, 1200], increment: 0.1,
steppers: true, units: 'millimeter'
},
frame: {
type: 'list', label: 'frame',
value: 1, fractionDigits: 0,
options: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]

},

create: {
type: 'button', value: 'Create',
onClick: function() {

}
}

};

var palette = new Palette('mask animation', items, values);

Re: have increment by mm instand of point
Date:  12. April 2010, 16:13

When you set units to mm, it only shows the value converted to mm, but the actual value is still in points.

1 millimeter = 2.83464567 points

Therefore, if you would want to start at 1mm:

var values = {
	gap: 0 ,
	mask: 2.83464567
}
Scripts
08.08.14, 15:24
15.05.14, 14:23
02.03.14, 19:16
18.11.13, 14:48
22.03.13, 03:05
22.02.13, 15:45
Posts
10.01.17, 16:37
19.02.16, 06:03
19.02.16, 06:00
17.01.16, 11:00
12.01.16, 13:10
25.11.15, 08:19
Script of the Moment
Crumpler 23.07.10