TRVStyle.GetAsPixels, GetAsHTMLPixels, GetAsStandardPixels, GetAsTwips, GetAsEMU, GetAsDifferentUnits, GetAsRVUnits

<< Click to display table of contents >>

TRVStyle.GetAsPixels, GetAsHTMLPixels, GetAsStandardPixels, GetAsTwips, GetAsEMU, GetAsDifferentUnits, GetAsRVUnits

The methods return Value converted from Units to different units of measurement.

function GetAsPixels(Value: TRVStyleLength;
  PixelsPerInch, MinNonZeroValue: TRVCoord): TRVCoord;

function GetAsHTMLPixels(Value: TRVStyleLength): TRVPixel96Length;

function GetAsStandardPixels(Value: TRVStyleLength): TRVPixelLength;

 

function GetAsTwips(Value: TRVStyleLength): Integer;

function GetAsEMU(Value: TRVStyleLength): Integer;

function GetAsDifferentUnits(Value: TRVStyleLength

  Units: TRVStyleUnits): TRVStyleLength;

function GetAsRVUnits(Value: TRVStyleLength;

  RVUnits: TRVUnits): TRVLength;

(introduced in versions 13, 18)

Method

Converts to

GetAsPixels

Pixels.

1 pixel = 1/PixelsPerInch of an inch (where PixelsPerInch is specified as a parameter)

GetAsHTMLPixels

Pixels.

1 pixel = 1/96 of an inch.

GetAsStandardPixels

Pixels.

1 pixel = 1/UnitsPixelsPerInch of an inch.

GetAsTwips

Twips.

1 twip = 1/20 of an inch.

GetAsEMU

EMU.

1 EMU = 1/914400 of an inch = 1/36000 mm.

GetAsDifferentUnits

Units (specified in the parameter).

When converting to/from pixels, UnitsPixelsPerInch is used as DPI.

GetAsRVUnits

RVUnits (specified in the parameter).

When converting to/from pixels, UnitsPixelsPerInch is used as DPI.

When GetAsPixels converts a nonzero Value to pixels, the result cannot be less than MinNonZeroValue (parameter) (or -MinNonZeroValue for a negative Value). For other methods converting nonzero Value to pixels, the result cannot be less than 1 (or -1 for a negative Value).

See also:

*ToUnits methods;

ConvertTo* methods;

Units of measurement in TRichView