Declaration
property Units: TIEUnits;
Description
Specifies the measurement unit displayed on the ruler.
Default: ieuPixels
Note:
◼Changing
Units will automatically set
LabelFrequency and
Frequency to a relevant value
◼Use
TImageEnView.SetScale to adjust the scale
ImageEnView1.LockUpdate();
ImageEnView1.RulerParams.Units := ieuInches;
ImageEnView1.RulerParams.LabelFrequency := 1/4; // Labels every quarter inch
ImageEnView1.RulerParams.Frequency := 1/32; // Ticks every 1/32 inch
ImageEnView1.UnlockUpdate();
// SET SCALE
// Set display to inches (with 100 pixels represent 1 inch)
ImageEnView1.LockUpdate();
ImageEnView1.SetScale( 100, 1, ieuInches );
ImageEnView1.RulerParams.Units := ieuInches;
ImageEnView1.UnlockUpdate();
// ALTERNATIVELY: Adjust via DPI
// Set display to inches (with 100 pixels represent 1 inch)
ImageEnView1.LockUpdate();
ImageEnView1.IO.Params.Dpi := 100;
ImageEnView1.RulerParams.Units := ieuInches;
ImageEnView1.UnlockUpdate();
// Set display to CM (with 100 pixels represent 10cm)
ImageEnView1.LockUpdate();
ImageEnView1.SetScale( 100, 10, ieuCentimeters );
ImageEnView1.RulerParams.Units := ieuCentimeters;
ImageEnView1.UnlockUpdate();
See Also
◼DefaultMeasureUnit