home *** CD-ROM | disk | FTP | other *** search
/ CP/M / CPM_CDROM.iso / cpminfo / cpm-cc05.art < prev    next >
Text File  |  1994-07-13  |  17KB  |  306 lines

  1.  
  2. ==============================================================================
  3. [   THE KAY*FOG RBBS  |  CPM-CC05.ART  |  posted 01/18/86  |  303 lines 17k  ]
  4.  
  5.           The CP/M Connection                   Originally published in    
  6.                   by                               Computer Currents       
  7.              Ted Silveira                           2550 9th Street        
  8.   (copyright and all rights reserved)             Berkeley, CA  94710      
  9.  
  10.  
  11.                                  May 7, 1985
  12.                               WORDSTAR UTILITIES
  13.  
  14.      If the most common thing people do with computers is shuffle disks, 
  15. then the second-most common thing they do is shuffle text--word-processing 
  16. and all its related activities.  In the CP/M public domain, there are 
  17. enough text-handling programs to fill several columns, but since WordStar 
  18. is word-processing to most CP/M users, let's start with a batch of 
  19. utilities made especially for WordStar.
  20.  
  21.  
  22. MAGE31, RESQ12
  23.  
  24.      It was almost midnight, and I had a deadline.  Outside it was windy 
  25. and raining.  The work was going so slowly and I was so tired that I 
  26. stupidly hadn't saved anything for at least an hour.  Suddenly the lights 
  27. dimmed, only briefly but long enough.  When I hit the next key, nothing 
  28. happened--the screen still showed my text, intact, but the computer was 
  29. frozen, locked up, out to lunch, total amnesia.  The results:  two minutes 
  30. of frantic pounding on the keyboard, five minutes of stunned silence, a 
  31. resigned push of the reset button, and an hour spent redoing my lost work.
  32.  
  33.      Even if you've never been struck by this disaster, don't push your 
  34. luck.  Anyone who works with WordStar needs either MAGE31 or RESQ12, two 
  35. programs that recover text after disk errors, locked-up computers, or 
  36. almost any disaster short of a complete power failure.  A few months after 
  37. my midnight disaster, I was hit by the same problem, but this time, I had 
  38. MAGE31.  Total time lost:  2 minutes.
  39.  
  40.      The secret is that when you have to restart your computer by hitting 
  41. ^C or even the reset button, your computer doesn't erase the part of your 
  42. text that's in memory.  It just forgets the text is there.  So MAGE31 and 
  43. RESQ12 go to the section of memory where your text should be and save what 
  44. they find into a disk file.  You can then combine that file with the 
  45. incomplete text file (filetype $$$) you'll find on your disk or with your 
  46. latest complete version.
  47.  
  48.      MAGE31 is slightly easier to use than RESQ12 but also slightly harder 
  49. to set up because it must be adapted to the different versions of WordStar 
  50. (3.3, 3.0, 2.26).  If you find a copy of MAGE31.COM that's set for your 
  51. WordStar, you're in business.  Otherwise, you must get the assembly 
  52. language file (MAGE31.ASM) and adapt it to your WordStar by changing an 
  53. address in the file and reassembling it.  The ASM file includes directions.  
  54. Once it's set, MAGE31 is quick, simple, and foolproof.
  55.  
  56.      RESQ12 does the same job in a slightly different way.  When you run 
  57. RESQ12, it asks for a string (a combination of characters or words) from 
  58. your lost text.  It searches upward in memory until it finds that string, 
  59. moves back downward to what it thinks is the start of your text, and then 
  60. saves everything from that point to the end of your text.  In practice, it 
  61. works quickly and pretty accurately (assuming the string really is in your 
  62. text).  Unlike MAGE31, RESQ12 comes ready-to-run and also works with 
  63. programs other than WordStar.
  64.  
  65.      If you use WordStar, make sure you have one or the other of these 
  66. programs.
  67.  
  68.  
  69. PAIRX
  70.  
  71.      WordStar nightmare #2:  You start printing a long file.  You watch the 
  72. first half-page come out, just to make sure everything's OK, then wander 
  73. off to do something else.  You return half an hour later to discover your 
  74. printer has been underlining every word from page 2 on--you left out a 
  75. single ^S needed to stop the underlining.
  76.  
  77.      PAIRX, by Eric Gans, is a simple, fast solution to that problem.  It 
  78. checks WordStar files to make sure that the commands for underlining (^S), 
  79. boldface (^B), double-strike (^D), strike-out (^X), superscript (^T), and 
  80. subscript (^V) all come in matched pairs.  If it finds any of these 
  81. characters unmatched (turned on without being turned off), it gives you the 
  82. page and line number of the isolated character.  As it comes, PAIRX expects 
  83. to find a match within one line, but the documentation explains how to 
  84. increase this range, if you want to.
  85.  
  86.      PAIRX isn't as essential as MAGE31 or RESQ12, but it saves time, 
  87. frustration, and tractor-feed paper.
  88.  
  89.  
  90. FILTER PROGRAMS
  91.  
  92.      WordStar document files are not just ordinary files--they have many 
  93. special characters in them to represent the soft carriage returns, soft 
  94. hyphens, soft spaces, and print control characters that make WordStar's 
  95. formatting so versatile.  These special characters can cause problems if 
  96. you transfer a WordStar file to another word processor, an unprepared 
  97. typesetter, or many bulletin boards and information services.  So there are 
  98. many programs available to "harden" WordStar's soft format by filtering out 
  99. the special characters, resulting in a file (often called a standard ASCII 
  100. file) acceptable in even the most conservative circles.  And because there 
  101. are so many WordStar users, there are also filter programs to "soften" 
  102. standard ASCII files, converting them to WordStar document files so they 
  103. can be reformatted with all WordStar's tricks.
  104.  
  105.      HRDSFT, by Kenneth Toy, is a lovely program.  It's small (2K) and 
  106. fast, and it can either harden or soften a file.  It does the standard job 
  107. of hardening, converting all soft characters to normal ones and removing 
  108. all control characters except carriage returns, line feeds, and tabs.  
  109.  
  110.      It also does a good job of softening a hard file, converting all hard 
  111. carriage returns to soft ones unless followed by a space, a tab, a period 
  112. (dot commands), or another carriage return.  This method works pretty well 
  113. on single-spaced text, though some things, like columns of numbers at the 
  114. left margin can trip it up (that's true of all softeners).  HRDSFT has two 
  115. weak points, which it shares with similar programs:  it doesn't soften 
  116. double-spaced text properly, and it doesn't harden soft hyphens but simply 
  117. removes them.  HRDSFT also can't handle files larger than will fit in 
  118. memory, about 48K or so (but I rarely have files that long).
  119.  
  120.      ENSOFT and UNSOFT are a matched set of filters; ENSOFT softens and 
  121. UNSOFT hardens.  Both work well but have problems with the same things 
  122. HRDSFT does:  double-spaced text, soft hyphens, and occasional odd formats.  
  123. They are bigger (about 8K each) than HRDSFT but can handle files of any 
  124. length.
  125.  
  126.      FILT6, by Irv Hoff, is a hardener only; it turns any text file into a 
  127. standard ASCII file by cleaning out all special characters and all control 
  128. characters except carriage returns, line feeds, and tabs.  It works with 
  129. any word processor's files but has special WordStar options, such as 
  130. retaining or removing dot commands.  You can also have it replace spaces 
  131. with tabs wherever possible (which saves space in long files) or replace 
  132. tabs with spaces (some programs choke on tabs).  FILT6 also has special 
  133. options for handling assembly language files, which make it handy for 
  134. programmers.
  135.  
  136.      I keep HRDSFT on my word processing disks, because it's smaller and 
  137. faster than ENSOFT/UNSOFT, and FILT6 on my programming and communications 
  138. disks, because of it extra options.
  139.  
  140.  
  141. REPCS, CHGCHR
  142.  
  143.      These two programs solve one of WordStar's nagging problems--how to 
  144. search and replace ^S.  WordStar's find and find/replace functions can 
  145. search for almost any character, including control characters.  
  146. Unfortunately, they can't search for the ^S WordStar uses for underlining 
  147. because the search command uses ^S as its match-any-character wildcard.  So 
  148. you can't, for example, use the search command to find every word in a file 
  149. that you've underlined.
  150.  
  151.      REPCS (sometimes called REPLACE), by Maryanne Weston and Donald Hay, 
  152. solves that problem.  It will search a WordStar file and replace every ^S 
  153. with the character @.  You can then use WordStar's search command to find 
  154. the @ and either delete it or change it to something else.  That's all 
  155. REPCS does, though you can use DDT to patch the search and replacement 
  156. characters to new values.
  157.  
  158.      The more versatile CHGCHR, by Al de la Torre, will search a file for 
  159. any character and replace it with any other, including non-printing control 
  160. characters like ^S.  You specify the search character and replacement 
  161. character on the command line when you run the program, and CHGCHR does the 
  162. rest.  CHGCHR is not limited to working on WordStar files.
  163.  
  164.      You probably won't need these programs often, but I've known people 
  165. driven to distraction trying to find every ^S in a long WordStar file 
  166. without them.
  167.  
  168.  
  169. FTNT14 
  170.  
  171.      Unlike Perfect Writer and some other word processors, WordStar can't 
  172. do footnotes on its own.  There is, however, a public domain footnoting 
  173. program, FTNT14 by Eric Meyer.  FTNT14 has so many features and subtleties 
  174. I can't cover them all, but here's a quick rundown.
  175.  
  176.      FTNT14 will extract notes from a WordStar file and print them as 
  177. either footnotes or endnotes.  It will number them automatically (even 
  178. starting over on each page, if you want), format them in various ways, 
  179. carry long footnotes over to the bottom of the next page, and allow you to 
  180. use separate print commands (like condensed printing) in the notes.
  181.  
  182.      FTNT14 will also handle internal page references for up to 52 
  183. locations within your text.  You can refer to a chapter, table, or other 
  184. location from any point in the text and have FTNT14 insert the correct page 
  185. reference when it finally formats your text.
  186.  
  187.      FTNT14 also does what Meyer calls "figure block" formatting.  This 
  188. command allows you to specify a certain number of lines of text (a table, 
  189. perhaps, or an example) as a figure block.  When FTNT14 encounters this 
  190. command, it will print the figure block at the top of the following page, 
  191. but unlike WordStar's .CP command, FTNT14 will fill in the rest of the 
  192. space on the current page with text from after the block.  In other words, 
  193. there won't be any gaping whole at the bottom of the page the figure block 
  194. came from.  That's neat.
  195.  
  196.      FTNT14 works in two passes, one to extract the notes and one to create 
  197. a formatted file for final printing.  It obeys all WordStar control 
  198. characters and most dot commands.  It makes minor changes in the behavior 
  199. of a few dot commands (to accommodate the notes) and won't let you use dot 
  200. commands that affect vertical page format:  top and bottom margins, heading 
  201. and footing margins, line height.  
  202.  
  203.      Formatting footnotes, especially in a long file, is a touchy, complex 
  204. business, but FTNT14 does its job well.  It's a class program.
  205.  
  206.  
  207. INDEX PROGRAMS
  208.  
  209.      Along with footnotes, go indexes.  There are three public domain 
  210. indexing programs available for WordStar, and though none is as classy as 
  211. FTNT14, all can save you some drudgery.
  212.  
  213.      WINDEX12, by Eric Gans, is the newest and slickest of the three.  It 
  214. works on WordStar document files only, can index both words and phrases, 
  215. and correctly handles words divided by soft hyphens.  It can index up to 
  216. 254 keywords, handles files of any length and references up to 9999 pages, 
  217. and, like the other programs, alphabetizes the index.
  218.  
  219.      Unlike the following two programs, WINDEX12 doesn't require you to 
  220. mark the words to be indexed in your text.  Instead, you build a separate 
  221. file containing the keywords (up to 254 of them) you want indexed, or you 
  222. enter the keywords from your keyboard at indexing time.  That does make 
  223. your job easier, but it also means you may miss some phrases you waned to 
  224. index, unless you search through the file on your own.  It also means that 
  225. you can't make WINDEX12 ignore certain occurrences of a word.
  226.  
  227.      INDEX101, by Tom Jennings, has you mark the words and phrases you want 
  228. indexed by using the unused WordStar control characters ^PK and ^PP.  
  229. (Actually, ^PP is used if you're trying out WordStar's undocumented and 
  230. very buggy proportional spacing, in which case you'll have to remove the 
  231. ^PP characters after you index.)
  232.  
  233.      INDEX101 adds the index to the end of your WordStar file, unlike the 
  234. other two programs, which write the index to a separate file.  It also 
  235. erases the old index each time you run the program.  
  236.  
  237.      GENINDEX also has you mark the words to be indexed in your text, using 
  238. ^PQ for major references (printed boldface) and ^PW for minor references 
  239. (printed normally).  These control characters are two of WordStar's user-
  240. definable print control characters; you'll have conflicts if you're already 
  241. using these (to control a dot matrix printer, for example).
  242.  
  243.      GENINDEX writes its index into a separate file and updates (rather 
  244. than erases) any old index it finds.  However, GENINDEX doesn't work on 
  245. normal WordStar document files, only on files that have been printed-to-
  246. disk using the "disk file output" option of WordStar's print command.
  247.  
  248.      I rarely index anything, so my experience is limited, but WINDEX12 is 
  249. the easiest program to use.  It's also the program to use if you want to 
  250. index every occurrence of a keyword.  INDEX101 gives you more control if 
  251. you don't want to index every occurrence of a keyword and probably also if 
  252. you're going to index many phrases.  None of the three programs puts out an 
  253. index that's really ready to print; you'll want to do some cleaning up.  
  254.  
  255.  
  256. [FTNT14]
  257.  
  258.      Unlike Perfect Writer and some other word processors, WordStar can't 
  259. do footnotes on its own.  There is, however, a public domain footnoting 
  260. program, FTNT14 by Eric Meyer.  FTNT14 has so many features and subtleties 
  261. I can't cover them all, but here's a quick rundown.
  262.  
  263.      FTNT14 will extract notes from a WordStar file and print them as 
  264. either footnotes or endnotes.  It will number them automatically (even 
  265. starting over on each page, if you want), format them in various ways, 
  266. carry long footnotes over to the bottom of the next page, and allow you to 
  267. use separate print commands (like condensed printing) in the notes.
  268.  
  269.      FTNT14 will also handle internal page references for up to 52 
  270. locations within your text.  You can refer to a chapter, table, or other 
  271. location from any point in the text and have FTNT14 insert the correct page 
  272. reference when it finally formats your text.
  273.  
  274.      In addition, FTNT14 does what Meyer calls "figure block" formatting, 
  275. which allows you to specify a certain number of lines of text (a table, 
  276. perhaps, or an example) as a block.  This command causes FTNT14 to print 
  277. the block at the top of the following page, but unlike WordStar's .CP 
  278. command, FTNT14's figure block command fills in the rest of the space on 
  279. the current page with text from after the block.  In other words, there 
  280. won't be any gaping hole at the bottom of the page the figure block came 
  281. from.  That's neat.
  282.  
  283.      FTNT14 works in two passes, one to extract the notes and one to create 
  284. a formatted file for final printing.  It obeys all WordStar control 
  285. characters and most dot commands.  It makes minor changes in the behavior 
  286. of a few dot commands (to accommodate the notes) and won't let you use dot 
  287. commands that affect vertical page format:  top and bottom margins, heading 
  288. and footing margins, line height.  
  289.  
  290.      Formatting footnotes, especially in a long file, is a touchy, complex 
  291. business, but FTNT14 does its job well.  It's a class program.
  292.  
  293.  
  294.      All these programs are available in the usual channels, except 
  295. WINDEX12, which is so new that it's only available on RCP/Ms at the moment.  
  296. Next issue, I'll cover some text utilities for use with any word processor.
  297.  
  298. ------------------------------------------------------------------------------
  299.       Ted Silveira is a freelance writer and contributing editor to several
  300.    computer-oriented publications.  He appreciates suggestions or feedback
  301.    and can be reached through the KAY*FOG RBBS (415)285-2687 and CompuServe
  302.    (72135,1447) or by mail to 2756 Mattison Lane, Santa Cruz, CA 95065.
  303.  
  304. -------------------------  End of CPM-CC05.ART Text  -------------------------
  305.  
  306.