hmFree_GetArrayWidth
hmFree_GetArrayWidth(TextArray;Font;Fontsize;Fontstyle) -> width
Parameter Type Description
TextArray Text-Array -> Text array
Font Text -> Fontname
Fontsize Longint -> Fontsize
Fontstyle Longint -> Fontstyle
width Longint <- string width in pixels
The command hmFree_GetArrayWidth returns the maximal width of each text in the text array, defined by font, fontsize and fontstyle. You can use the predefinied constants of 4D in the parameter Fontstyle.
The following example returns the maximal text width of all elements in the text array:
C_LONGINT($vl_width)
$vl_width:=hmFree_GetArrayWidth($tt_texts;"Arial";10;Bold+Italic)