[comp.sys.mac.programmer] how to use the 'styl' resource

peirce@outpost.UUCP (Michael Peirce) (12/07/90)

I was playing with ResEdit 2.1b3.  In it they have a combined TEXT/styl
editor that allows you to create styled text with a TEXT resource
containing the characters and a styl resource containing the style
information.

I'm trying to use this in my program, I tried using TESetText to insert
the characters, followed by a SetStyleHandle to set the style, then a TECalText.

The TECalText crashes (it looks like the lnTab [line height table
handle] has garbage in it).

So obviously this isn't how you use the styl resource.  Does anyone
know how to make use of this so I can grab styled text from my resource
fork?

-- michael


--  Michael Peirce         --   {apple,decwrl}!claris!outpost!peirce
--  Peirce Software        --   Suite 301, 719 Hibiscus Place
--  Macintosh Programming  --   San Jose, California 95117
--         and Consulting  --   (408) 244-6554