Unit: | SDL_geomap | Class: |
none |
Declaration: |
TLMTextProperties = record
Text : TLMText;
Size : integer;
FontName : TFontName;
FontStyles : TFontStyles;
FGColor : TColor;
BGColor : TColor;
Transparent : boolean;
dx : integer;
dy : integer;
Direction : integer;
HAlignment : TAlignment;
VAlignment : TVerticalAlignment;
end;
|
The type definition TLMTextProperties declares the properties of the caption of a landmark. The following table gives an overview of the available properties (subfields of the record):
Field |
Explanation |
Text |
The text displayed at the landmark position |
Size |
The size of the text in points. |
FontName |
The font name. If the FontName gets an invalid string assigned the standard system font is used by default. |
FontStyles |
The style of the font. Valid set members are fsBold, fsItalic, fsUnderline, and fsStrikeOut |
FGColor |
The color of the caption text. |
BGColor |
The color of the caption background. The BGColor entry is ignored if Transparent is TRUE. |
Transparent |
The landmark caption becomes transparent if set TRUE. |
dx, dy |
The offset in pixels between the landmark position and the reference point of the caption. The positive direction for dx is from left to right, for dy it is top to bottom. |
Direction |
The direction of the text in degrees. Zero degrees is from left to right, 90 degrees is from bottom to top. |
HAlignment |
Horizontal alignment of the caption (relative to the reference point). Allowed values: taLeftJustify, taCenter, taRightJustify |
VAlignment |
Vertical alignment of the caption (relative to the reference point). Allows values are vaTop, vaCenter, and vaBottom. |
The following figure shows two landmarks, their captions and the corresponding reference points (indicated by a small black circle). The location of the reference point depends on the HAlignment and VAlignment parameters. The left landmark uses HAlignment := taLeftJustify and VAlignment := vaTop, the right landmark uses HAlignment := taCenter and VAlignment := vaTop. Please note that the offset [dx,dy] is always in pixel coordinates and that dx is always the horizontal offset, and dy the vertical offset, regardless of the direction of the label.
|