Make new text frame broken in AppleWorks 6
Make new text frame broken in AppleWorks 6
- Subject: Make new text frame broken in AppleWorks 6
- From: Doug McNutt <email@hidden>
- Date: Fri, 27 Dec 2002 08:35:26 -0700
Subject was: Scripting makes AppleWorks 6 crash
Mark Butcher recommended
http://www.tandb.com.au/appleworks/
Malcolm Fitzgerald suggested capturing the reference with set
They were helpful, but the problem needs to be fixed at Apple - er - Claris.
Procedure:
Create a new drawing document
Use the "A" tool to create a text frame and put something into it.
It ought to be assigned index: 1
Turn on the AppleScript Event Log, with results enabled, and run this:
tell application "AppleWorks 6"
set Greeting to "Hello world"
set theTF1 to make new text frame at end of drawing layer of front document with properties {bounds:{10, 10, 410, 40}}
delay 2
set theTF2 to make new text frame at end of drawing layer of front document with properties {bounds:{10, 50, 410, 90}}
delay 2
get properties of theTF2
set text body of theTF2 to Greeting
delay 2
get properties of theTF1
set text body of theTF1 to Greeting
get text frames of drawing layer of front document
end tell
You will create two text frames which will be initially labelled index 2 and index 3 but you will be able to change the text body only in index 3 - theTF2.
The original frame with index 1 and your typed-in text will have vanished. Getting every text frame will return only two of them, and index 3 will have become index 2. It appears that make new is badly broken. It overlays the largest existing index rather than adding one to the count. (Using C++ instead of ++C ?) "Obvious" English syntax like "after the end" or "beyond the last" are not accepted. Just saying "in drawing layer" causes AppleWorks to crash as does "at front in drawing layer". Both of those seem to attempt creation of text frame 1 overlaying whatever is already text frame 1 and leaving things in an untidy state.
This is apparently not new to OS 10.2.3 or to AppleWorks 6.2.4, see:
Newsgroups: alt.comp.lang.applescript
Subject: AppleWorks 6: 'make new text frame' bug ?
Date: Tue, 22 Aug 2000 23:08:45 +0100
--
--> If you are presented a number as a percentage, and you do not clearly understand the numerator and the denominator involved, you are surely being lied to. <--
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.