aboutsummaryrefslogtreecommitdiffstats
path: root/doc/expert/pre_brea
blob: 5e17b9c12ffca439c7f2d178d2f80f678dc3082b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
@Section
   @Title { "@Break" }
   @Tag { break }
@Begin
@PP
The @@Break symbol influences the appearance of paragraphs (Section
{@NumberOf concatenation}), offering a fixed set of styles:
@IL

@LI {
2i @Wide { |1rt @Code adjust @@Break @I object }
adjust.break @Index { @Code adjust @@Break }
|2m Break the paragraphs of {@I object} into lines, and apply @@PAdjust
(Section {@NumberOf hadjust}) to every line except the last in
each paragraph;
}

@LI {
2i @Wide { |1rt @Code outdent @@Break @I object }
outdent.break @Index { @Code outdent @@Break }
|2m Like {@Code adjust}, except that @Code "2.0f @Wide {} &0i" is
inserted at the beginning of every line except the first, creating
an outdented paragraph (the outdent width may be changed -- see below);
}

@LI {
2i @Wide { |1rt @Code ragged @@Break @I object }
ragged.break @Index { @Code ragged @@Break }
|2m Break the paragraphs of {@I object} into lines, but do not adjust
the lines (`ragged right');
}

@LI {
2i @Wide { |1rt @Code cragged @@Break @I object }
cragged.break @Index { @Code cragged @@Break }
|2m Like {@Code ragged}, except that each line will be centred with
respect to the others;
}

@LI {
2i @Wide { |1rt @Code rragged @@Break @I object }
rragged.break @Index { @Code rragged @@Break }
|2m Like {@Code ragged}, except that each line will be right-justified with
respect to the others (`ragged left');
}

@LI {
2i @Wide { |1rt @Code oragged @@Break @I object }
oragged.break @Index { @Code oragged @@Break }
|2m The obvious combination of {@Code ragged} and {@Code outdent};
}

@LI {
2i @Wide { |1rt @Code lines @@Break @I object }
lines.break @Index { @Code lines @@Break }
|2m Break the paragraphs of {@I object} into lines at the same points
that they are broken into lines in the input, and also at concatenation
symbols of the form {@Code "&"}{@I k}{@Code "b"} for any {@I k} greater
than 1.  Do not adjust the lines.  Any spaces at the start of a line
other than the first line will appear in the output;
}

@LI {
2i @Wide { |1rt @Code clines @@Break @I object }
clines.break @Index { @Code clines @@Break }
|2m Break the paragraphs of {@I object} into lines as for @Code "lines"
@@Break, then centre each line with respect to the others;
}

@LI {
2i @Wide { |1rt @Code rlines @@Break @I object }
rlines.break @Index { @Code rlines @@Break }
|2m Break the paragraphs of {@I object} into lines as for @Code "lines"
@@Break, then right-justify each line with respect to the others.
}

@LI {
2i @Wide { |1rt @Code olines @@Break @I object }
olines.break @Index { @Code olines @@Break }
|2m Break the paragraphs of {@I object} into lines as for @Code "lines"
@@Break, then as for outdenting.
}

@EL
If the paragraph was an entire component of a galley, so will each of
its lines be; otherwise the lines are enclosed in a {@Code "@OneRow"}
symbol after breaking.
@PP
The length of the gap used to separate the lines produced by paragraph
breaking is always {@Code 1v}, except when {@Code lines}, {@Code clines},
or {@Code rlines} encounter a completely blank line, for which see below.
However, the @Code v unit itself and the
v.unit.effect @SubIndex { effect on paragraph breaking }
gap mode may be changed:
@IL

@LI {
2i @Wide { |1rt @I gap @Code "@Break" @I object }
|2m Within {@I object}, take the value of the @Code "v" unit to be the
length of {@I gap};
}

@LI {
2i @Wide { |1rt + & @I gap @Code "@Break" @I object }
|2m Within {@I object}, take the value of the @Code "v" unit to be
larger by the length of @I gap than it would otherwise have been;
}

@LI {
2i @Wide { |1rt -- & @I gap @Code "@Break" @I object }
|2m Within {@I object}, take the value of the @Code "v" unit to be
smaller by the length of @I gap than it would otherwise have been.
}

@EL
In each case, the mode of @I gap is adopted within {@I object}.
@PP
When {@Code lines}, {@Code clines}, or {@Code rlines} encounter one or more
completely blank lines, a single vertical concatenation operator is inserted
to implement these, ensuring that the entire set of lines will disappear if
they happen to fall on a page or column break.  The gap width of the
concatenation operator is {@Code 1v} for the first newline as usual, plus
{@Code 1v} multiplied by the @I { blank line scale factor }, an arbitrary
decimal number with no units, for the remaining newlines.  This scale factor
is settable by
@ID {
@Code "{ blanklinescale" @I num @Code "} @Break" @I object
}
The default value is {@Code 1.0}, which gives blank lines their full
height.  However it often looks better if they are reduced somewhat.
A value as small as {@Code 0.6} looks good; it gives width {@Code 1.6v}
to the concatenation symbol inserted at a single blank line.  The
usual gap mode is of course appended.
@PP
The @@Break symbol also controls hyphenation:
@IL

@LI {
2i @Wide { |1rt @Code "hyphen @Break" @I object }
hyphen.break @Index { @Code hyphen @@Break }
|2m Permit hyphenation within the paragraphs of {@I object};
}

@LI {
2i @Wide { |1rt @Code "nohyphen @Break" @I object }
nohyphen.break @Index { @Code nohyphen @@Break }
|2m Prohibit hyphenation within the paragraphs of {@I object}; all
hyphenation gaps without exception revert to edge-to-edge mode.
}

@EL
The @@Break also has options which control widow and orphan lines:
@IL

@LI {
2i @Wide { |1rt @Code "unbreakablefirst @Break" @I object }
hyphen.break @Index { @Code hyphen @@Break }
|2m Prevent column and page breaks (i.e. prevent a galley from splitting)
between the first and second lines of the paragraphs of {@I object};
}

@LI {
2i @Wide { |1rt @Code "unbreakablelast @Break" @I object }
nohyphen.break @Index { @Code nohyphen @@Break }
|2m Prevent column and page breaks between the last and second
last lines of the paragraphs of {@I object}.
}

@EL
These options work by adding the @Code "u" (unbreakable) suffix to the
appropriate gaps during paragraph breaking, so their precise effect is
as described for this suffix.  These options may be countermanded by
@Code "breakablefirst @Break" and @Code "breakablelast @Break".
@PP
The width of the outdenting used in the @Code "outdent" style may be
changed like this:
@IL

@LI {
2i @Wide { |1rt @Code "{ setoutdent" @I width @Code "} @Break" @I object }
|2m Within {@I object}, whenever outdenting is required, use @I width
for the amount of outdenting.  Note that this does not itself cause a
switch to outdenting style.  The width may be preceded by @Code "+" or
@Code -- to indicate a change to the existing outdent value.
}

@EL
Margin kerning, in which small (usually punctuation) characters protrude
into the margin, may be obtained by @Code "marginkerning @Break" and turned
off by @Code { "nomarginkerning @Break" }.
@PP
Several options may be given to the @@Break symbol simultaneously, in
any order.  For example,
@ID @Code "{ adjust 1.2fx hyphen }  @Break  ..."
is a typical initial value.  There may be empty objects and @@Null objects
in the left parameter of @@Break; these are ignored.
@End @Section