class DDrawingString is a DDrawingPrimitive that represents a string in the viewer window.
More...
class DDrawingString is a DDrawingPrimitive that represents a string in the viewer window.
The length of the string is restricted to 256 characters.
| def dectris.albula.DDrawingString.DDrawingString |
( |
|
x, |
|
|
|
y, |
|
|
|
text, |
|
|
|
red, |
|
|
|
green, |
|
|
|
blue, |
|
|
|
alpha = 255 |
|
) |
| |
Construct DDrawingString by passing its position, its text content and its color.
- Parameters
-
| x | Float. X position. |
| y | Float. Y position. |
| text | String. Text to be displayed. Maximum 256 characters. |
| red | Integer between 0 and 255 |
| green | Integer between 0 and 255 |
| blue | Integer between 0 and 255 |
| alpha | Integer between 0 and 255. alpha defines the opacity of the displayed primitive. |
| def dectris.albula.DDrawingString.setText |
( |
|
text | ) |
|
Set text of the string.
Maximum 256 characters.
- Parameters
-
| def dectris.albula.DDrawingString.setX |
( |
|
x | ) |
|
Set X position of the string.
- Parameters
-
| def dectris.albula.DDrawingString.setY |
( |
|
y | ) |
|
Set Y position of the string.
- Parameters
-
| def dectris.albula.DDrawingString.text |
( |
| ) |
|
Text to be displayed.
- Returns
- String.
| def dectris.albula.DDrawingString.x |
( |
| ) |
|
X position of the string.
- Returns
- Float
| def dectris.albula.DDrawingString.y |
( |
| ) |
|
Y position of the string.
- Returns
- Float