home *** CD-ROM | disk | FTP | other *** search
/ DP Tool Club 17 / CD_ASCQ_17_101194.iso / vrac / sleek41.zip / SLEEK.DOC < prev    next >
Text File  |  1994-07-31  |  12KB  |  350 lines

  1.  
  2. SLEEK (SLK.EXE), a file-reformatting utility
  3. Version: 4.1
  4. July 30, 1994            
  5.  
  6. SLEEK is Copyright 1991, 1994 by 
  7. Lambert Klein
  8. P.O. Box 611
  9. Wayne MI  48184-611
  10. Voice telephone: (313) 467-8070         Fax:   (313) 467-8373
  11.  
  12. GEnie:       L.Klein1
  13. CompuServe:  72010,624
  14. Internet:    72010.624@compuserve.com
  15. AOL:         LKlein3990
  16.  
  17. Member, Association of Shareware Professionals
  18.  
  19. =======================================================
  20.  
  21.               ┌─────────┐
  22.         ┌─────┴───┐     │               (R)
  23.       ──│         │o    │──────────────────
  24.         │   ┌─────┴╨──┐ │  Association of
  25.         │   │         │─┘  Shareware
  26.         └───│    o    │    Professionals
  27.       ──────│    ║    │────────────────────
  28.             └────╨────┘    MEMBER
  29.  
  30. "This program is produced by a member of the Association of
  31. Shareware Professionals (ASP). ASP wants to make sure that
  32. the shareware principle works for you. If you are unable to
  33. resolve a shareware-related problem with an ASP member by
  34. contacting the member directly, ASP may be able to help. The
  35. ASP Ombudsman can help you resolve a dispute or problem with
  36. an ASP member, but does not provide technical support for
  37. members' products. Please write to the ASP Ombudsman at 545
  38. Grover Road Muskegon MI 49442 or send a Compuserve message
  39. via easyplex to ASP Ombudsman 70007,3536."
  40.  
  41. ============================================================
  42. SLK.EXE is shareware. If you try it out, find it useful and
  43. go on using it - please register it. Registration is only
  44. $10.00.
  45. ============================================================
  46.  
  47.         PURPOSE
  48.  
  49. SLEEK is a high-speed text reformatter. Its purpose is to
  50. alter the lengths of lines in plain-text files, such as
  51. those created by text editors like PC-Write or Qedit (or
  52. files saved "unformatted" - but with "hard" line endings
  53. within paragraphs - by word processing programs such as
  54. Microsoft Word).
  55.  
  56. ---------------------------------------------------------
  57. Documentation for SLEEK (SLK.EXE), v. 4.1.        Page 1
  58. (c) Copyright 1991, 1994 Lambert Klein
  59.  
  60.  
  61. The program is useful for reformatting text files with
  62. relatively short line lengths, perhaps (as with this file)
  63. because the writer assumed you'd be using a typical dot-
  64. matrix printer setup to print them. But if you're using, say,
  65. compressed mode for printing, you might prefer that the lines
  66. be longer (thereby saving some paper). SLEEK can help with
  67. this by increasing the line lengths to your specifications.
  68.  
  69.         WHAT IT DOES
  70.  
  71. You can tell SLEEK to format line lengths out to a specified
  72. column, from 10 to 60,000. If you do not specify any column
  73. width, SLEEK changes all paragraphs in a text file to a
  74. single long line (with exceptions as noted below).
  75.  
  76. The latter function is useful to people who must take text
  77. files containing many "hard" line breaks and import them
  78. into a desktop publishing (DTP) program or open them with a
  79. program like Microsoft Word. It is almost always desirable
  80. to allow DTP programs, or Word and others like it, to make
  81. their own decisions about line breaks. "Hard" returns inside
  82. paragraphs in typical plain-text files block automatic line-
  83. wrapping - a major pain in the neck for the DTP program
  84. user. The solution is often either tedious manual
  85. reformatting or multiple passes through the file with a
  86. search/replace program (or with a DTP program's search/
  87. replace routine).
  88.  
  89. SLEEK, which is written entirely in assembly language, does
  90. its work quickly. For example, on a RAM disk on a 486-33
  91. computer, SLEEK has been observed to process a 105K text
  92. file - removing ALL hard breaks within paragraphs - in less
  93. than one second (if it had been re-breaking lines to
  94. SPECIFIED lengths, it would probably have taken several
  95. seconds to process the file). (Of course, as they say: Your
  96. mileage may vary.)
  97.  
  98.         HOW IT WORKS
  99.  
  100. SLEEK first trims extra spaces from the ends of lines. Then,
  101. on any line to be merged with the one below it, the "newline
  102. character" at the end of the line (actually, a carriage
  103. return followed by a line feed) is removed and replaced by a
  104. single space.
  105.  
  106. Reformatting stops at the end of a paragraph - which, from
  107. SLEEK's point of view, occurs when there are two or more
  108. "newlines" in a row - and begins again at the top of the
  109. next paragraph. (SLEEK does not do anything to blank lines.)
  110.  
  111. ---------------------------------------------------------
  112. Documentation for SLEEK (SLK.EXE), v. 4.1.        Page 2
  113. (c) Copyright 1991, 1994 Lambert Klein
  114.  
  115.  
  116. Another exception: Reformatting does NOT occur on any lines
  117. that begin with one or more spaces OR tab characters. Thus,
  118. you can use leading spaces or tabs to help control how the
  119. output file will look. (See the examples later in this
  120. documentation.) NOTE: The -D switch is an exception for the above.
  121.  
  122. What about hyphens? Hyphens are used in a couple of
  123. different ways within plain-text files: to force-hyphenate
  124. words and/or to create simulated "EM" or "EN" dashes.
  125.  
  126. If SLEEK, in reformatting a text file, must join a line with
  127. the one below it, and if the first line ends with a hyphen
  128. followed by a space, the space will be RETAINED when the two
  129. lines are joined. This is to ensure that if the hyphen-
  130. followed-by-space is part of a dash - just like that - the
  131. same positioning of spaces and hyphen(s) will be retained in
  132. the output file.
  133.  
  134. On the other hand, if a line ends with a manually-
  135. hyphenated word (just like that), SLEEK will NOT add a space
  136. after the hyphen if the line is joined with the one below
  137. it - unless there is ALREADY a space to the right of the
  138. hyphen in the input file (which would normally be a mistake
  139. in a situation like that).
  140.  
  141. SLEEK will never force a break INSIDE a word, but if it is
  142. shortening lines: When it encounters a hyphenated word it
  143. will, if possible, break the word at the hyphen, leaving the
  144. hyphen on the upper line.
  145.  
  146.         PROGRAM SYNTAX
  147.  
  148. SLK d:\path\filename /nn
  149.  
  150. where:
  151.  
  152. "d:\path\" represents OPTIONAL path information to tell
  153. SLEEK the location of the file to be processed (the input
  154. file);
  155.  
  156. "filename" is the name of the input file; and
  157.  
  158. "/nn" is an OPTIONAL command-line "switch" telling SLEEK at
  159. what column to re-break the lines in the file. For example,
  160. "/50" would tell SLEEK to reformat the lines out to column
  161. 50. The "nn" value can be 0, or in a range from 10 to 60000.
  162.  
  163. If you use "/0," SLEEK will use its maximum line-length
  164. setting (60,000). If you completely OMIT the "/nn"
  165. information, you're also in effect telling SLEEK to use its
  166.  
  167. ---------------------------------------------------------
  168. Documentation for SLEEK (SLK.EXE), v. 4.1.        Page 3
  169. (c) Copyright 1991, 1994 Lambert Klein
  170.  
  171.  
  172. maximum line-length setting (in which case the effect is to
  173. make all paragraphs in the file into a single long line -
  174. unless they begin with one or more spaces or tabs, or unless
  175. they are longer than 60,000 characters - not too likely).
  176.  
  177. If you use a "/nn" setting of from 1 to 9, SLEEK will
  178. default to a setting of 10.
  179.  
  180. NOTE: The alternate command-line switch character (a hyphen)
  181.       is supported in this version of SLEEK.
  182.  
  183.         OUTPUT FILES
  184.  
  185. SLEEK never over-writes your original file. It creates an
  186. output file having the same "base" name as the input file,
  187. but with the extension ".SLK." Thus: INPUT.DOC --> INPUT.SLK.
  188.  
  189. If you include a path in the input file name, that path will
  190. also be used for the output file.
  191.  
  192. Thus:  D:\INPUT.DOC --> D:\INPUT.SLK, even if you are not
  193. logged onto D:\ at the time you give the SLEEK command.
  194.  
  195. CAUTION: The program will OVER-WRITE an existing .SLK file
  196.          without query. If you run SLEEK on a file called
  197.          INPUT.DOC twice: The second time around, the new
  198.          INPUT.SLK will replace the first.
  199.  
  200.          *NEVER* use for input a file whose extension is
  201.          ".SLK". The result is that you'll lose the input
  202.          file completely; it will be written back to disk
  203.          as a zero-length file.
  204.  
  205.         OTHER LIMITATIONS
  206.  
  207. The present version of SLK does not accept wildcards in the
  208. input file name.
  209.  
  210. Files whose line endings consist ONLY of a carriage-return
  211. character (as with text files written on a Macintosh) are
  212. not suitable as input files until you add a line feed to
  213. each carriage return. Files whose lines end with ONLY a
  214. line feed character (as with text files written on a Unix
  215. system) will be processed almost, but not quite, as
  216. described above (the results are not entirely predictable).
  217. For best results, ensure that all "newlines" are carriage-
  218. return/line-feed pairs.
  219.  
  220. NOTE: SLK.EXE *CAN* read past a CTRL-Z (end-of-file)
  221.       character in an input file. It will not remove the
  222.       CTRL-Z and will go on processing lines below it.
  223. ---------------------------------------------------------
  224. Documentation for SLEEK (SLK.EXE), v. 4.1.        Page 4
  225. (c) Copyright 1991, 1994 Lambert Klein
  226.  
  227.  
  228.         EXAMPLES
  229.  
  230. Suppose the input file (call it TEST.DOC) looks like this:
  231.  
  232. Line one.
  233. Line two.
  234. Line three.
  235. Line four.
  236.  
  237. Line five.
  238. Line six.
  239.  
  240. ... and you use this command line:
  241.  
  242.         SLK test.doc
  243.  
  244. (no line length specified) The output file, TEST.SLK, will
  245. look like this:
  246.  
  247. Line one. Line two. Line three. Line four.
  248.  
  249. Line five. Line six.
  250.  
  251. Suppose instead the input file looks like the output file
  252. shown immediately above, and you use this command line:
  253.  
  254.         SLK test.doc /31
  255.  
  256. The result is:
  257.  
  258. Line one. Line two. Line three.
  259. Line four.
  260.  
  261. Line five. Line six.
  262.  
  263. If the input file TEST.DOC looks like this:
  264.  
  265. Line one. Line two.
  266.   Line three.
  267.   Line four.
  268. Line five.
  269.   Line six.
  270. Line seven.
  271.  
  272. Line eight.
  273. Line nine.
  274.  
  275. ... and you give this command (again, with no line-length
  276. information):
  277.  
  278.         SLK test.doc
  279.  
  280. ... then the output file, TEST.SLK, looks like this:
  281. ---------------------------------------------------------
  282. Documentation for SLEEK (SLK.EXE), v. 4.1.        Page 5
  283. (c) Copyright 1991, 1994 Lambert Klein
  284.  
  285. Line one. Line two.
  286.   Line three.
  287.   Line four. Line five.
  288.   Line six. Line seven.
  289.  
  290.  Line eight. Line nine.
  291.  
  292. That illustrates how lines beginning with spaces are NOT
  293. merged with adjacent lines just above them and ARE merged
  294. with lines just below them - unless the lines below ALSO
  295. begin with one or more spaces.
  296.  
  297. * New to version 4 is the -d switch. *
  298. This option will remove all leading spaces. Especially useful
  299. when the text file has a left margin.
  300.  
  301. SLK filename -65 -d
  302.  
  303. I hope you find SLEEK useful. If you have any comments,
  304. suggestions, bug reports, and so on, please send them to me
  305. at the address shown above. See the file PROGRAMS.TXT, also
  306. in the archive SLEEK.ZIP, for information on my other
  307. shareware, including PrintPlus, my menu-driven dot-matrix
  308. printer control program.
  309.  
  310. You can now register Sleek on CompuServe. just:
  311.  
  312. Go SWREG
  313.  
  314. Program title:          SLEEK
  315. Registration ID:        814
  316.  
  317.  
  318.  
  319. Any registered or trademarked product names mentioned in
  320. this documentation are the property of their respective
  321. owners or publishers.
  322.  
  323. (Documentation assistant: Mike Arst, Compuserve 70403,1337)
  324.  
  325.  
  326. ---------------------------------------------------------
  327. Documentation for SLEEK (SLK.EXE), v. 4.1.        Page 6
  328. (c) Copyright 1991, 1994 Lambert Klein
  329.  
  330.      CREDIT CARD ORDERS ONLY -
  331.  
  332.      You can order with MC, Visa, Amex, or Discover from Public (software)
  333.      Library by calling 800-2424-PsL or 713-524-6394 or by FAX to 713-524-
  334.      6398 or by CIS Email to 71355,470. You can also mail credit card
  335.      orders to PsL at P.O.Box 35705, Houston, TX 77235-5705.
  336.  
  337.      THE ABOVE NUMBERS ARE FOR ORDERS ONLY.
  338.  
  339.      Any questions about the status of the shipment of the order, refunds,
  340.      registration options, product details, technical support, volume
  341.      discounts, dealer pricing, site licenses, etc, must be directed to
  342.      Lambert Klein, Voice: 313-467-8070, Fax: 313-467-8373, Email or mail.
  343.  
  344.      To insure that you get the latest version, PsL will notify us the day
  345.      of your order and we will ship the product directly to you. 
  346.  
  347. Any non-credit card orders may be made directly with the Author.
  348.  
  349.  
  350.