4D v16.3

OBJECT Get text orientation

Home

 
4D v16.3
OBJECT Get text orientation

OBJECT Get text orientation 


 

OBJECT Get text orientation ( {* ;} object ) -> Function result 
Parameter Type   Description
Operator in If specified, object is an object name (string) If omitted, object is a field or variable
object  Form object in Object name (if * is specified) or
Field or variable (if * is omitted)
Function result  Longint in Angle of text rotation

The OBJECT Get text orientation command returns the current orientation value applied to the text of the object(s) designated by the object and * parameters.

You can set the "Orientation" option for an object in Design mode using the Property List, or using the OBJECT SET TEXT ORIENTATION command.

Passing the optional * parameter indicates that the object parameter is an object name (string). If you do not pass this parameter, it indicates that the object parameter is a field or variable. In this case, you pass a field or variable reference instead of a string (field or variable object only).

The value returns corresponds to one of the following constants, found in the "Form Objects (Properties)"  theme:

Constant Type Value Comment
Orientation 0° Longint 0 No rotation (default value)
Orientation 180° Longint 180 Orientation of text to 180° clockwise
Orientation 90° left Longint 270 Orientation of text to 90° counter-clockwise
Orientation 90° right Longint 90 Orientation of text to 90° clockwise

Example  

Given the following object (where a "90° left" orientation was applied in the Form editor):

When the form is executed, if you call the following statement:

 OBJECT SET TEXT ORIENTATION(*;"myText";Orientation 180°)

... then the object appears as follows:

 $vOrt:=OBJECT Get text orientation(*;"myText") //$vOrt=180



See also 

OBJECT SET TEXT ORIENTATION

 
PROPERTIES 

Product: 4D
Theme: Objects (Forms)
Number: 1283

 
HISTORY 

Created: 4D v14

 
ARTICLE USAGE

4D Language Reference ( 4D v16)
4D Language Reference ( 4D v16.1)
4D Language Reference ( 4D v16.2)
4D Language Reference ( 4D v16.3)