Variance property (LEADDlgImgDoc Control)

C++ Builder example

Delphi 4.0 example

 

Builder Syntax

L_INT32 Variance

Delphi Syntax

Variance: L_INT32

Overview

Refer to Using Imaging Common Dialogs.

Remarks

Gets or sets the amount of variance.

This property is associated with the following dialog boxes

LineRemove dialog box

In this case it represents the amount of width change that is tolerated between adjacent line slices. If LINE_USE_DPI is set in ProcessFlags property, units are in thousandths of an inch, otherwise units are in pixels. This property is valid only if LINE_USE_VARIANCE is set in ProcessFlags. For example, the following horizontal line is 30 pixels in length (X represents a pixel)

 

XXXXXXXXXX 

 

XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

 

XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

 

XXXXXXXXXX 

 

XXXXXXXXXX 

 

If Variance is 2 pixels (i.e. tolerate width changes of 2 pixels or less), the first 10 columns and the last 10 columns of the line will be removed. The middle 10 columns will be unchanged. This helps preserve characters that intersect a line that is being removed.

BorderRemove dialog box

In this case it represents the amount of variance tolerated in the border. If the border varies significantly in thickness, you should use a higher value for Variance. Range is 0 to 10.

See Also

Elements:

ShowLineRemoveDlg method, ShowBorderRemoveDlg method.

Topics:

Imaging Common Dialogs: Properties, Methods, and Events