macro to create UIfield widget with label
macro UIfieldTypein {
ilink UIparent;
ilink flabel;
ilink fval;
ilink fmin;
ilink fmax;
UIpanel panel {
parent => UIparent;
width = 250;
height => <-.field.height;
x => <-.x;
y => <-.y;
width => <-.width;
height => <-.height;
};
UIlabel label {
parent => panel;
label => flabel;
y => (<-.field.height - .height) / 2;
width => <-.panel.width / 2;
};
UIfield field {
parent => panel;
min => fmin;
max => fmax;
value => fval;
x => <-.panel.width / 2;
y = 0;
width => <-.panel.width / 2;
};
int+IPort2+OPort2 x;
int+IPort2+OPort2 y;
int+IPort2+OPort2 width = 200;
int+IPort2+OPort2 height = 40;
};
UIfieldTypein is a macro that creates a UIfield widget that already includes a UIlabel and an enclosing UIpanel.
An input port to connect to the parent widget that contains the UIfieldTypein.
An input port to connect to a string object that names the UIfieldTypein.
An input port to connect to the float object that defines a float value.
Input ports to connect to float objects that define the minimum and maximum allowed in the UIfieldTypein.
Main.Filters.set_null
v/modules.v