Path: utzoo!attcan!uunet!mailrus!iuvax!cica!tut.cis.ohio-state.edu!zaphod.mps.ohio-state.edu!think!paperboy!snorkelwacker!apple!well!brecher From: brecher@well.sf.ca.us (Steve Brecher) Newsgroups: comp.sys.mac.programmer Subject: Re: I hate it when Apple does this . . . Message-ID: <16680@well.sf.ca.us> Date: 14 Mar 90 08:39:17 GMT References: <420@fornax.UUCP> <88@ndcvb.cc.nd.edu> <422@fornax.UUCP> Reply-To: brecher@well.sf.ca.us (Steve Brecher) Distribution: na Organization: Software Supply, Sunnyvale, CA Lines: 16 In article <422@fornax.UUCP> mcdonald@fornax.UUCP (Ken Mcdonald) writes: > [IM] specifically states that to extract or set the text in a statText > or editText item, one should pass the handle produced by GetDItem to > GetIText or SetIText. This is what made me think that the handle > returned is not a simple handle to a string--if it were, why the need > for SetIText/GetI Text? It is not a handle to a (Pascal) string; it is a handle to raw text, with no preceding length byte. The length of the text is given by GetHandleSize. What GetIText does is to make a Pascal string from the text; SetIText does the converse. -- brecher@well.sf.ca.us (Steve Brecher)