Article View: comp.sys.mac
Article #26868Help! TextEdit Programming Problem - "nLines"
From: Greg Rogers
Date: Tue, 29 Mar 1988 07:44
Date: Tue, 29 Mar 1988 07:44
18 lines
1366 bytes
1366 bytes
Can any Mac wizard shed some light on a programming problem I'm having? My edit record (TERec) seems to completely loose track of the number of lines of text as I'm adding characters to the text. In other words TERec.nLines jumps ahead by hundreds of lines as I add characters using TEInsert. The number of lines that nLines jumps by doesn't seem to follow any pattern. Line after line of text is inserted properly and then out of the blue, nLines jumps. This seems to occur after a carriage return ($0D) is inserted, but only infrequently. I also follow TEInsert with TEScroll after each ($0D) is inserted but this seems unrelated. Calling TECalText fixes the edit record with nLines returning to normal, and all characters intact. Is there some bug related to carriage returns and TEInsert or TEScroll in these toolbox routines? I would really appreciate any information as I can't find any explaination for this behavior. Thanks, Greg Rogers
Technical Details
Message-ID:
<2653@tekig4.TEK.COM>Path:
arc1-ca.pugleaf.net!utzoo!mnetor!uunet!tektronix!tekig5!tekig4!gregrReferences:
<18317@think.UUCP>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!mnetor!uunet!tektronix!tekig5!tekig4!gregr From: gregr@tekig4.TEK.COM (Greg Rogers) Newsgroups: comp.sys.mac Subject: Help! TextEdit Programming Problem - "nLines" Message-ID: <2653@tekig4.TEK.COM> Date: 29 Mar 88 07:44:14 GMT References: <18317@think.UUCP> Reply-To: gregr@tekig4.UUCP (Greg Rogers) Organization: Tektronix, Inc., Beaverton, OR. Lines: 18