|
Convert Labels |
|
2000.05.31 |
http://www.barefeetware.com/appleworks/convert_labels/ |
|
Description |
This AppleWorks script converts any labels from explicit text to paragraph style or vise versa. AppleWorks has a great paragraph labeling system including numeric, Roman, bullets and so on. Use this script to transfer labeled paragraphs to and from other programs, such as email. |
|
Enhancement |
This is one of 40 scripts in the Enhancement Pack for AppleWorks. |
|
Detail
The Convert Labels item is in the Word Processing sub-menu of AppleWorks Scripts Menu. To use it:Advanced
This version converts bullets , numeric 1. 2. 3., roman numerals i. ii. iii..
- Open or create a word processing document containing paragraph labels (set by AppleWorks Format: Paragraph menu) or typed text prefixes such as 1. , 2. .
- Select the Convert Labels menu item.
- The script will locate the first label in the document to determine the type (paragraph format label or typed text label). Click OK to continue.
- The Script will change each label in the document to the indicated type.
If you prepare a document in AppleWorks using its paragraph formatting labels, changing point order is very easy. If you drag point labeled 5 to follow point labeled 2, then it is relabeled as 3 and all others are also corrected. However, if you then need to copy the text to an email or other program, the labels are not part of that text so are effectively removed. Before copying or saving as text, run this Convert Labels script to convert the paragraph formatted labels to editable text.Requirements
When converting from paragraph formatted labels to text, the paragraph formatting is not removed by this script, so there appear to be two labels for each paragraph. This is deliberate so you can check the accuracy of the conversion. When you copy or save as text, the paragraph formatting is stripped, so is no longer redundant.
If you receive an email or text document with explicitly typed number prefixes in paragraphs (eg a series of numbered points), you can run the Convert Labels script to replace them with AppleWorks paragraph formatted labels. The explicit text is removed and the paragraph is indented so the labels are visible.
The Export for Xpress script includes the same conversion of paragraph formatted labels to text.
Operates on the text body of the active word processing document.Download
This script works with AppleWorks 6, but not AppleWorks 5 since it gives no access to the label of a paragraph format.
Only registered users are permitted to use the supplied files after 14 days or edit them.
This script is included in the Enhancement Pack for AppleWorks, not supplied separately.Scripting
This script is read only. Here is a small section:Please email us any queries about this page.
set textLabel to text 1 thru (trailStartN - 1) in leadText
if paragraphIndex > previousindex + 1 then
set stepN to 1
set previousLabel to none
end if
considering case
if textLabel is in {"1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24"} then
set thisLabel to numeric label
else if textLabel is "" then
set thisLabel to bullet label