| Derived from | CFType |
| Framework | ApplicationServices/CoreText |
| Declared in | CTTextTab.h |
The CTTextTab opaque type represents a tab in a paragraph style, storing an alignment type and location.
Core Text supports four alignment types: left, center, right, and decimal. These alignment types are absolute, not based on the line sweep direction of text. For example, tabbed text is always positioned to the left of a right-aligned tab, whether the line sweep direction is left to right or right to left. A tab's location, on the other hand, is relative to the back margin. A tab set at 1.5 inches, for example, is at 1.5 inches from the right in right-to-left text.
Creates and initializes a new text tab object.
CTTextTabRef CTTextTabCreate( CTTextAlignment alignment, double location, CFDictionaryRef options );
The tab's alignment. This is used to determine the position of text inside the tab column. This parameter must be set to a valid CTTextAlignment value or this function returns NULL.
The tab's ruler location, relative to the back margin.
Options to pass in when the tab is created. Currently, the only option available is kCTTabColumnTerminatorsAttributeName. This parameter is optional and can be set to NULL if not needed.
A reference to a CTTextTab object if the call was successful; otherwise, NULL.
CTTextTab.hReturns the text alignment of the tab.
CTTextAlignment CTTextTabGetAlignment( CTTextTabRef tab );
The tab whose text alignment is obtained.
The tab's text alignment value.
CTTextTab.hReturns the tab's ruler location.
double CTTextTabGetLocation( CTTextTabRef tab );
The tab whose location is obtained.
The tab's ruler location relative to the back margin.
CTTextTab.hReturns the dictionary of attributes associated with the tab.
CFDictionaryRef CTTextTabGetOptions( CTTextTabRef tab );
The tab whose attributes are obtained.
The dictionary of attributes associated with the tab, or if no dictionary is present, NULL.
CTTextTab.hReturns the Core Foundation type identifier of the text tab object.
CFTypeID CTTextTabGetTypeID( void );
CTTextTab.hA reference to a text tab object.
typedef const struct __CTTextTab *CTTextTabRef;
CTTextTab.hSpecifies the terminating character for a tab column.
const CFStringRef kCTTabColumnTerminatorsAttributeName;
kCTTabColumnTerminatorsAttributeNameSpecifies the terminating character for a tab column.
Available in Mac OS X v10.5 and later.
Declared in CTTextTab.h
The value associated with this attribute is a CFCharacterSet object. The character set is used to determine the terminating character for a tab column. The tab and newline characters are implied even if they don't exist in the character set. This attribute can be used to implement decimal tabs, for instance. This attribute is optional.
CTTextTab.h
Last updated: 2007-05-01