1 Cone©
2
3LEAF(1) Cone: COnsole Newsreader And E LEAF(1)
4
5
6
8 leaf - Lightweight Editor of Ascii(and more) Files
9
11 leaf [-f] [-d dictionary] [+n] [filename]
12
14 leaf is a simple console text file editor, with paragraph word-wrapping
15 and spell checking. leaf is based on the text editor in the Cone mail
16 reader and composer. leaf opens filename, positioning the cursor on
17 the first line, or line #n, if specified.
18
19 This is not really the best editor for program sources. leaf is meant
20 to be used as a quick editor for writing short notes and memos. As text
21 is typed, words will automatically flow to wrap within a typical
22 80-character terminal display, even on larger display (due to leaf's
23 heritage as an editor for E-mail messages, which are traditionally
24 formatted to fit an 80-character display). Word wrapping is "lazy":
25 only long text lines are wrapped. Short text lines are not folded
26 together. Individual paragraphs are separated by blank lines of text.
27 Press CTRL-J to optimally rejustify the paragraph under the cursor. The
28 bottom two lines on the screen list which keys to press for other
29 functions.
30
31 Flowed text
32 The -f option enables “flowed text” formatting convention. Plain text
33 files have no explicit means for joining multiple lines into logical
34 paragraph. Each line of text is an individual line, and a blank line
35 marks the end of a paragraph.
36
37 In a “flowed text” formatted file, each line in a paragraph except the
38 last one ends with a space character. This makes no visual difference,
39 it's just a marker that this line should be merged with the next line.
40 The last line in the paragraph does not end in a space character.
41
42 The trailing space character is logically removed from each flowed
43 line, and all flowed lines are merged into a logical paragraph that can
44 be adjusted to any display width. It's important to note that text
45 written in non-ideographic languages, where individual words are
46 separated by spaces, will have two space characters at the end of every
47 line: the space character that separates the last word on the line from
48 the first word on the next line, and the a second space character that
49 marks the line as a flowed line.
50
51 Because the trailing space marking a flowed line is logically removed,
52 without the second space character there will not be a logical space
53 between the two words, and if the paragraph's width is adjusted for
54 display the two words may get combined together.
55
56 The -f option puts leaf into flowed text mode, removing spaces from
57 each flowed line of text in an opened file. A flowed line is marked on
58 the screen with a "<" character in the right margin (or a small "next
59 line" character on a UTF-8 display). When saving a file leaf
60 automatically adds a trailing space to each line that's marked as
61 flowed.
62
63 The flowed text mode stays in effect for each file opened in leaf. When
64 opening another file, press CTRL-F to turn flowed mode on or off for
65 the next file. This change stays in effect until it gets toggled again.
66
67 Pressing CTRL-J optimally rejustifies the text in flowed text mode.
68 leaf heuristically determines the start and the end of the paragraph,
69 readjusts the width of the paragraph, and marks each line as flowed,
70 except the last paragraph line. leaf uses a unicode-based algorithm
71 for determining whether the last character line needs a space
72 character, in addition to the flowed space marker.
73
74 Note
75 leaf is frequently used to edit plain text email message content.
76 Because email messages assign some semantical meaning to lines of
77 text that start with spaces or ">" characters, CTRL-J will not
78 rejustify lines of text that begin with a ">" or a space. These
79 lines will be considered paragraph boundaries, in addition to blank
80 lines.
81
82 Spell checking
83 The -d option sets the name of the dictionary used for spell checking
84 (overriding the default spell checking dictionary set by the DICTIONARY
85 environment variable). +n sets the initial cursor position to line #n.
86
88 emacs(1), vi(1)
89
91 Sam Varshavchik
92
93
94
95Cone© 08/25/2016 LEAF(1)