Path: utzoo!attcan!uunet!shelby!unix!mxmora From: mxmora@unix.SRI.COM (Matt Mora) Newsgroups: comp.sys.mac.programmer Subject: Re: The 'styl' resource Message-ID: <21789@unix.SRI.COM> Date: 1 Mar 91 17:17:36 GMT References: <3732.27CD8EBC@blkcat.fidonet.org> Reply-To: mxmora@unix.sri.com (Matt Mora) Organization: SRI International, Menlo Park, CA Lines: 31 In article <3732.27CD8EBC@blkcat.fidonet.org> Ken.Knight@f421.n109.z1.fidonet.org (Ken Knight) writes: >I think this has been asked before here, but I haven't seen a real >answer myself. There is, in ResEdit 2.x a resource called 'styl' >defined. It appears to be a resource that lets you store/retrieve >styled TextEdit (text, style runs, and so on) data. Are there any calls >like GetStylResource/PutStyleResource that can retrieve and write out >these 'styl' resources? Just what is the format of a 'styl' resource? Below are some calls to the new textedit routines described in IM Vol5. starting on page 259. TEGetStyle(offset, style, lineHeight, fontAscent, te); TEGetHeight(endLine, startLine, te); TEStylPaste(te); TESetStyle(mode, style, redraw, te); TEStylNew(destRect, viewRect); TEReplaceStyle(mode, oldStyle, newStyle, redraw, te); GetStylHandle(te); GetStylScrap(te); SetStylHandle(h, te); TEStylInsert(text, length, h, te); TEGetPoint(offset, te); TEGetHeight(endLine, startLine, te); -- ___________________________________________________________ Matthew Mora | my Mac Matt_Mora@sri.com SRI International | my unix mxmora@unix.sri.com ___________________________________________________________