BIDI > Support of Bidirectional and Contextual Languages > Bidirectional Attributes and the Class IlvGraphic
 
Bidirectional Attributes and the Class IlvGraphic
This section presents the bidirectional attributes related to the IlvGraphic class.
Rogue Wave Views Bidi provides a number of functions for handling the bidirectional attributes associated with a graphic object. These functions are declared in the <ilviews/bidi/bidi.h> header file.
These functions come from a previous version of Rogue Wave Views Bidi. Most of them are now obsolete since they have been replaced with the methods of the IlvBidiInterface class, which can be accessed from the IlvGraphic class.
In these functions, the display parameter designates the IlvDisplay object for which the graphic object has been created and from which it can retrieve the default bidirectional attributes if required.
Get Functions
The following function determines whether the graphic object passed as its parameter uses the default bidirectional attributes.
IlInt
IlvHasDefaultBidiValues(IlvDisplay* display, const IlvGraphic* obj);
The return values are as follows:
*1 - The object uses default bidirectional attributes.
*-1 - The object uses bidirectional attributes that have values that are identical to those of the default attributes.
*0 - The object uses other bidirectional attributes.
This function is now obsolete and is equivalent to obj->hasDefaultBidiAttributes().
The following functions return the value of the corresponding bidirectional attribute for the specified graphic object:
IlvSwapping
IlvGetSwapping(IlvDisplay* display, IlvGraphic* obj);
IlvNumerals
IlvGetNumerals(IlvDisplay* display, IlvGraphic* obj);
IlvLayoutDirection
IlvGetLayoutDirection(IlvDisplay* display, IlvGraphic* obj);
IlvShaping
IlvGetShaping(IlvDisplay* display, IlvGraphic* obj);
IlvWordBreak
IlvGetWordBreak(IlvDisplay* display, IlvGraphic* obj);
They are now obsolete and are equivalent to the following member functions, respectively:
obj->getBidiAttributes(&num, 0, 0, 0, 0);
obj->getBidiAttributes(0, &swap, 0, 0, 0);
obj->getBidiAttributes(0, 0, &dir, 0, 0);
obj->getBidiAttributes(0, 0, 0, &shape, 0);
obj->getBidiAttributes(0, 0, 0, 0, &wbreak);
Set Functions
The following functions set the corresponding bidirectional attribute to val for the specified object, which is created for display:
void
IlvSetSwapping(IlvDisplay* display,
IlvGraphic* obj,
IlvSwapping val);
void
IlvSetNumerals(IlvDisplay* display,
IlvGraphic* obj,
IlvNumerals val);
void
IlvSetLayoutDirection(IlvDisplay* display,
IlvGraphic* obj,
IlvLayoutDirection val);
void
IlvSetShaping(IlvDisplay* display,
IlvGraphic* obj,
IlvShaping val);
void
IlvSetWordBreak(IlvDisplay* display,
IlvGraphic* obj,
IlvWordBreak val);

Version 6.0
Copyright © 2015, Rogue Wave Software, Inc. All Rights Reserved.