2.284 .reffont

This attribute is the identifier of the font to which the x- and y-grid shall refer.

The dialog object also has the attribute .reffont. This allows to control the positioning of windows.

Definition

  • Data type

    object [ font ]

  • Access

    get, set

  • changed event

    yes

Remarks

  • The grid attributes .reffont, .xraster and .yraster are only significant if the application is to be realized on as many different hardware environments as possible. These attributes specifies a basic unit for the object size which is independent of the previously used pixel units. The letter size of the reference font selected or the input the user makes without specifying a font, are used as the new unit. All dimensions or positions then refer to this unit.

    Identifier

    Data Type

    Meaning

    .reffont

    object (font)

    Identifier of the font to which the units shall refer.

    .xraster

    integer

    Basic unit on x-axis

    .yraster

    integer

    Basic unit on y-axis

  • If a reference font is given, the DM automatically calculates the values for .xraster and .yraster, i.e. a .reffont specification overwrites the specifications of .xraster and .yraster.

Example

.xraster    8;
.yraster    16;
...
.posraster  true;
.xleft      10;
.ytop       4;

The thus defined object has the position 80, 64 on pixel coordinates, because the position was given in relation to the bases 8 and 16.

See also

Attributes .xraster, .yraster