Version: 2.0.1

Posted: 2005-08-10

Build Requirements: N/A

Runtime Requirements: Mac OS X Mac OS X 10.3 and later

View Source Code:

Download Sample (“TypeServicesForUnicode.zip”, 1.14M)
Download Sample (“TypeServicesForUnicode.dmg”, 1.44M)



Description

This is a sample program that demonstrates how to use the Apple Text Services For Unicode Imaging (ATSUI) technology in a Carbon Events based HIView architectured application.

This sample code has been updated to include a project that produces a universal binary. No code changes were required for it to run correctly on the Developer Transition Systems.

It contains a ready-to-use HIATSUIView which is a custom HIView

The HIATSUIView handles:

- getting and setting the text content

- getting and setting the styles

- getting and setting the selection

- various features like colors, wrapping, framing, justification, and transparency

- copying and dragging

- scrolling and auto-scrolling

- handling of double-clicks, triple-clicks, quadruple=clicks, click-and-drag, shift-clicking

The TypeForServices code handles:

- showing how to set the text

- showing how to set the text and styles

- showing how to rotate

- showing how to handle font variants

- showing how to handle font selection through the standard Font menu

- showing how to handle font selection through the standard Font panel

- showing how to instantiate the HIATSUIView from a nib

- showing how to read a text file and set the HIATSUIView content

- showing how to handle the clipboard

- showing how to handle background pictures

Document Revision History

Date Notes
2005-08-10Updated to produce a universal binary. No code changes were required.
2005-03-22Modernized the sample code to use HIViews and Carbon Events.
2003-06-05Shows how to use various ATSUI functions and features going from simple to very complex.

Did this document help you?
Yes: Tell us what works for you.
It’s good, but: Report typos, inaccuracies, and so forth.
It wasn’t helpful: Tell us what would have helped.