Sfairadora

  • Reference Guide

draw_text

var_bmp <- draw_text(x, y, text)
var_bmp <- draw_text(x, y, text, rcf)
The var_bmp parameter is an l-value referring to a variable of the type Bitmap. The function draws a text (a formatted string) to the bitmap.

Parameters

var_bmp
An l-value of the type Bitmap to which the function draws.
x
The left border at which is the text to be drawn.
y
The position of the base line at which is the text to be drawn.
text
The text to be drawn – the type Rich_string. (Note: a plain string (the type String) is automatically converted to the type Rich_string.)
rcf
The character format (the type Rich_cformat) specifying the values of the attributes not specified in the text.

Return Value

The return value is an l-value referring to the modified bitmap.

Example

bmp <- draw_text(10, 100,
rtf_to_rich_string("Matthew {\b Mark} \i Luke"),
rcf_font("Times New Roman"));

See Also