Index: trunk/flexbisonparse/wikiparse.y |
— | — | @@ -37,7 +37,12 @@ |
38 | 38 | tablerow table comment blocksnotbl blocknotbl textnoitaltbl textnoboldtbl |
39 | 39 | textnoboittbl textnotbl textelementnotbl textelementnoboldtbl textelementnoitaltbl |
40 | 40 | textelementnoboittbl paragraphnotbl linketcnotbl italorboldnotbl boldnoitalicstbl |
41 | | - italicsnoboldtbl pipeseriesnotbl |
| 41 | + italicsnoboldtbl pipeseriesnotbl textelementnoblittbp textelementnobltbpp |
| 42 | + textelementnoittbpp textelementnotblpipe textelementnobitp textelementnobldp |
| 43 | + textelementnoitp textelementnopipe textnoboittblpipe textnoboldtblpipe |
| 44 | + textnoitaltblpipe textnotblpipe textnoboitpipe textnoboldpipe textnoitalpipe |
| 45 | + textnopipe italorboldnopipe italorboldnotblp boldnoitalicspp boldnoitaltblpp |
| 46 | + italicsnoboldpp italnoboldtblpp |
42 | 47 | TEXT EXTENSION |
43 | 48 | %type <ad> ATTRIBUTE |
44 | 49 | %type <num> HEADING ENDHEADING TABLEBEGIN TABLECELL TABLEHEAD TABLEROW EQUALS ATTRAPO ATTRQ |
— | — | @@ -127,81 +132,81 @@ |
128 | 133 | | listseries LISTBULLET { debugf ("listseries#4 "); $$ = nodeAddChild ($1, newNode (ListBullet)); } |
129 | 134 | | listseries LISTNUMBERED { debugf ("listseries#5 "); $$ = nodeAddChild ($1, newNode (ListNumbered)); } |
130 | 135 | |
131 | | -linketc : OPENDBLSQBR text CLOSEDBLSQBR |
| 136 | +linketc : OPENDBLSQBR textnopipe CLOSEDBLSQBR |
132 | 137 | { debugf ("linketc#1 "); $$ = nodeAddChild (newNodeI (LinkEtc, 0), nodeAddChild (newNode (LinkTarget), $2)); } |
133 | | - | OPENDBLSQBR text PIPE CLOSEDBLSQBR |
| 138 | + | OPENDBLSQBR textnopipe PIPE CLOSEDBLSQBR |
134 | 139 | { debugf ("linketc#2 "); $$ = nodeAddChild (newNodeI (LinkEtc, 1), nodeAddChild (newNode (LinkTarget), $2)); } |
135 | | - | OPENDBLSQBR text pipeseries CLOSEDBLSQBR |
| 140 | + | OPENDBLSQBR textnopipe pipeseries CLOSEDBLSQBR |
136 | 141 | { debugf ("linketc#3 "); $$ = nodeAddChild2 (newNodeI (LinkEtc, 0), nodeAddChild (newNode (LinkTarget), $2), $3); } |
137 | | - | OPENDBLSQBR text pipeseries PIPE CLOSEDBLSQBR |
| 142 | + | OPENDBLSQBR textnopipe pipeseries PIPE CLOSEDBLSQBR |
138 | 143 | { debugf ("linketc#4 "); $$ = nodeAddChild2 (newNodeI (LinkEtc, 1), nodeAddChild (newNode (LinkTarget), $2), $3); } |
139 | | - | OPENLINK text CLOSEDBLSQBR |
| 144 | + | OPENLINK textnopipe CLOSEDBLSQBR |
140 | 145 | { debugf ("linketc#5 "); $$ = nodeAddChild (newNodeI (LinkEtc, 2), nodeAddChild (newNode (LinkTarget), $2)); } |
141 | | - | OPENLINK text PIPE CLOSEDBLSQBR |
| 146 | + | OPENLINK textnopipe PIPE CLOSEDBLSQBR |
142 | 147 | { debugf ("linketc#6 "); $$ = nodeAddChild (newNodeI (LinkEtc, 3), nodeAddChild (newNode (LinkTarget), $2)); } |
143 | | - | OPENLINK text pipeseries CLOSEDBLSQBR |
| 148 | + | OPENLINK textnopipe pipeseries CLOSEDBLSQBR |
144 | 149 | { debugf ("linketc#7 "); $$ = nodeAddChild2 (newNodeI (LinkEtc, 2), nodeAddChild (newNode (LinkTarget), $2), $3); } |
145 | | - | OPENLINK text pipeseries PIPE CLOSEDBLSQBR |
| 150 | + | OPENLINK textnopipe pipeseries PIPE CLOSEDBLSQBR |
146 | 151 | { debugf ("linketc#8 "); $$ = nodeAddChild2 (newNodeI (LinkEtc, 3), nodeAddChild (newNode (LinkTarget), $2), $3); } |
147 | 152 | /* ... and now everything again with the CLOSEDBLSQBR missing, |
148 | 153 | * to take care of invalid mark-up. */ |
149 | | - | OPENDBLSQBR text |
| 154 | + | OPENDBLSQBR textnopipe |
150 | 155 | { debugf ("linketc#9 "); $$ = makeTextBlock (newNodeS (TextToken, "[["), $2); } |
151 | | - | OPENDBLSQBR text PIPE |
| 156 | + | OPENDBLSQBR textnopipe PIPE |
152 | 157 | { debugf ("linketc#10 "); $$ = makeTextBlock2 (newNodeS (TextToken, "[["), $2, newNodeS (TextToken, "|")); } |
153 | | - | OPENDBLSQBR text pipeseries |
| 158 | + | OPENDBLSQBR textnopipe pipeseries |
154 | 159 | { debugf ("linketc#11 "); $$ = makeTextBlock2 (newNodeS (TextToken, "[["), $2, convertPipeSeriesToText ($3)); } |
155 | | - | OPENDBLSQBR text pipeseries PIPE |
| 160 | + | OPENDBLSQBR textnopipe pipeseries PIPE |
156 | 161 | { debugf ("linketc#12 "); $$ = makeTextBlock3 (newNodeS (TextToken, "[["), $2, convertPipeSeriesToText ($3), newNodeS (TextToken, "|")); } |
157 | | - | OPENLINK text |
| 162 | + | OPENLINK textnopipe |
158 | 163 | { debugf ("linketc#13 "); $$ = makeTextBlock (newNodeS (TextToken, "[[:"), $2); } |
159 | | - | OPENLINK text PIPE |
| 164 | + | OPENLINK textnopipe PIPE |
160 | 165 | { debugf ("linketc#14 "); $$ = makeTextBlock2 (newNodeS (TextToken, "[[:"), $2, newNodeS (TextToken, "|")); } |
161 | | - | OPENLINK text pipeseries |
| 166 | + | OPENLINK textnopipe pipeseries |
162 | 167 | { debugf ("linketc#15 "); $$ = makeTextBlock2 (newNodeS (TextToken, "[[:"), $2, convertPipeSeriesToText ($3)); } |
163 | | - | OPENLINK text pipeseries PIPE |
| 168 | + | OPENLINK textnopipe pipeseries PIPE |
164 | 169 | { debugf ("linketc#16 "); $$ = makeTextBlock3 (newNodeS (TextToken, "[[:"), $2, convertPipeSeriesToText ($3), newNodeS (TextToken, "|")); } |
165 | 170 | |
166 | | -linketcnotbl : OPENDBLSQBR textnotbl CLOSEDBLSQBR |
| 171 | +linketcnotbl : OPENDBLSQBR textnotblpipe CLOSEDBLSQBR |
167 | 172 | { debugf ("linketcnotbl#1 "); $$ = nodeAddChild (newNodeI (LinkEtc, 0), nodeAddChild (newNode (LinkTarget), $2)); } |
168 | | - | OPENDBLSQBR textnotbl PIPE CLOSEDBLSQBR |
| 173 | + | OPENDBLSQBR textnotblpipe PIPE CLOSEDBLSQBR |
169 | 174 | { debugf ("linketcnotbl#2 "); $$ = nodeAddChild (newNodeI (LinkEtc, 1), nodeAddChild (newNode (LinkTarget), $2)); } |
170 | | - | OPENDBLSQBR textnotbl pipeseriesnotbl CLOSEDBLSQBR |
| 175 | + | OPENDBLSQBR textnotblpipe pipeseriesnotbl CLOSEDBLSQBR |
171 | 176 | { debugf ("linketcnotbl#3 "); $$ = nodeAddChild2 (newNodeI (LinkEtc, 0), nodeAddChild (newNode (LinkTarget), $2), $3); } |
172 | | - | OPENDBLSQBR textnotbl pipeseriesnotbl PIPE CLOSEDBLSQBR |
| 177 | + | OPENDBLSQBR textnotblpipe pipeseriesnotbl PIPE CLOSEDBLSQBR |
173 | 178 | { debugf ("linketcnotbl#4 "); $$ = nodeAddChild2 (newNodeI (LinkEtc, 1), nodeAddChild (newNode (LinkTarget), $2), $3); } |
174 | | - | OPENLINK textnotbl CLOSEDBLSQBR |
| 179 | + | OPENLINK textnotblpipe CLOSEDBLSQBR |
175 | 180 | { debugf ("linketcnotbl#5 "); $$ = nodeAddChild (newNodeI (LinkEtc, 2), nodeAddChild (newNode (LinkTarget), $2)); } |
176 | | - | OPENLINK textnotbl PIPE CLOSEDBLSQBR |
| 181 | + | OPENLINK textnotblpipe PIPE CLOSEDBLSQBR |
177 | 182 | { debugf ("linketcnotbl#6 "); $$ = nodeAddChild (newNodeI (LinkEtc, 3), nodeAddChild (newNode (LinkTarget), $2)); } |
178 | | - | OPENLINK textnotbl pipeseriesnotbl CLOSEDBLSQBR |
| 183 | + | OPENLINK textnotblpipe pipeseriesnotbl CLOSEDBLSQBR |
179 | 184 | { debugf ("linketcnotbl#7 "); $$ = nodeAddChild2 (newNodeI (LinkEtc, 2), nodeAddChild (newNode (LinkTarget), $2), $3); } |
180 | | - | OPENLINK textnotbl pipeseriesnotbl PIPE CLOSEDBLSQBR |
| 185 | + | OPENLINK textnotblpipe pipeseriesnotbl PIPE CLOSEDBLSQBR |
181 | 186 | { debugf ("linketcnotbl#8 "); $$ = nodeAddChild2 (newNodeI (LinkEtc, 3), nodeAddChild (newNode (LinkTarget), $2), $3); } |
182 | 187 | /* ... and now everything again with the CLOSEDBLSQBR missing, |
183 | 188 | * to take care of invalid mark-up. */ |
184 | | - | OPENDBLSQBR textnotbl |
| 189 | + | OPENDBLSQBR textnotblpipe |
185 | 190 | { debugf ("linketcnotbl#9 "); $$ = makeTextBlock (newNodeS (TextToken, "[["), $2); } |
186 | | - | OPENDBLSQBR textnotbl PIPE |
| 191 | + | OPENDBLSQBR textnotblpipe PIPE |
187 | 192 | { debugf ("linketcnotbl#10 "); $$ = makeTextBlock2 (newNodeS (TextToken, "[["), $2, newNodeS (TextToken, "|")); } |
188 | | - | OPENDBLSQBR textnotbl pipeseriesnotbl |
| 193 | + | OPENDBLSQBR textnotblpipe pipeseriesnotbl |
189 | 194 | { debugf ("linketcnotbl#11 "); $$ = makeTextBlock2 (newNodeS (TextToken, "[["), $2, convertPipeSeriesToText ($3)); } |
190 | | - | OPENDBLSQBR textnotbl pipeseriesnotbl PIPE |
| 195 | + | OPENDBLSQBR textnotblpipe pipeseriesnotbl PIPE |
191 | 196 | { debugf ("linketcnotbl#12 "); $$ = makeTextBlock3 (newNodeS (TextToken, "[["), $2, convertPipeSeriesToText ($3), newNodeS (TextToken, "|")); } |
192 | | - | OPENLINK textnotbl |
| 197 | + | OPENLINK textnotblpipe |
193 | 198 | { debugf ("linketcnotbl#13 "); $$ = makeTextBlock (newNodeS (TextToken, "[[:"), $2); } |
194 | | - | OPENLINK textnotbl PIPE |
| 199 | + | OPENLINK textnotblpipe PIPE |
195 | 200 | { debugf ("linketcnotbl#14 "); $$ = makeTextBlock2 (newNodeS (TextToken, "[[:"), $2, newNodeS (TextToken, "|")); } |
196 | | - | OPENLINK textnotbl pipeseriesnotbl |
| 201 | + | OPENLINK textnotblpipe pipeseriesnotbl |
197 | 202 | { debugf ("linketcnotbl#15 "); $$ = makeTextBlock2 (newNodeS (TextToken, "[[:"), $2, convertPipeSeriesToText ($3)); } |
198 | | - | OPENLINK textnotbl pipeseriesnotbl PIPE |
| 203 | + | OPENLINK textnotblpipe pipeseriesnotbl PIPE |
199 | 204 | { debugf ("linketcnotbl#16 "); $$ = makeTextBlock3 (newNodeS (TextToken, "[[:"), $2, convertPipeSeriesToText ($3), newNodeS (TextToken, "|")); } |
200 | 205 | |
201 | | -pipeseries : PIPE text { debugf ("pipeseries#1 "); $$ = nodeAddChild (newNode (LinkOption), $2); } |
202 | | - | PIPE text pipeseries { debugf ("pipeseries#2 "); $$ = nodeAddSibling (nodeAddChild (newNode (LinkOption), $2), $3); } |
| 206 | +pipeseries : PIPE textnopipe { debugf ("pipeseries#1 "); $$ = nodeAddChild (newNode (LinkOption), $2); } |
| 207 | + | pipeseries PIPE textnopipe { debugf ("pipeseries#2 "); $$ = nodeAddSibling ($1, nodeAddChild (newNode (LinkOption), $3)); } |
203 | 208 | |
204 | | -pipeseriesnotbl : PIPE textnotbl { debugf ("pipeseriesnotbl#1 "); $$ = nodeAddChild (newNode (LinkOption), $2); } |
205 | | - | PIPE textnotbl pipeseriesnotbl { debugf ("pipeseriesnotbl#2 "); $$ = nodeAddSibling (nodeAddChild (newNode (LinkOption), $2), $3); } |
| 209 | +pipeseriesnotbl : PIPE textnotblpipe { debugf ("pipeseriesnotbl#1 "); $$ = nodeAddChild (newNode (LinkOption), $2); } |
| 210 | + | pipeseriesnotbl PIPE textnotblpipe { debugf ("pipeseriesnotbl#2 "); $$ = nodeAddSibling ($1, nodeAddChild (newNode (LinkOption), $3)); } |
206 | 211 | |
207 | 212 | textorempty : /* empty */ { debugf ("textorempty#1 "); $$ = newNodeS (TextToken, ""); } |
208 | 213 | | text { debugf ("textorempty#2 "); $$ = $1; } |
— | — | @@ -272,9 +277,6 @@ |
273 | 278 | | APO3 textnoboldtbl APO2 textnoboittbl APO5 |
274 | 279 | { debugf ("italorboldnotbl#6 "); $$ = nodeAddChild (newNode (Bold), |
275 | 280 | makeTextBlock ($2, nodeAddChild (newNode (Italics), $4))); } |
276 | | - /* Peculiar case, especially for French l'''homme'' => l'<italics>homme</italics> */ |
277 | | - /* We have to use textnoboldtbl here, even though textnoitaltbl would be logical. */ |
278 | | - /* We use processNestedItalics to fix the weirdness produced by this. */ |
279 | 281 | | APO3 textnoboldtbl APO2 textnoboittbl |
280 | 282 | { debugf ("italorboldnotbl#7 "); $$ = processNestedItalics (makeTextBlock2 (newNodeS |
281 | 283 | (TextToken, "'"), nodeAddChild (newNode (Italics), $2), $4)); } |
— | — | @@ -308,6 +310,102 @@ |
309 | 311 | { debugf ("italorboldnotbl#17 "); |
310 | 312 | $$ = makeTextBlock (newNodeS (TextToken, "'''''"), $2); } |
311 | 313 | |
| 314 | +italorboldnopipe: APO2 textnoitalpipe APO2 |
| 315 | + { debugf ("italicsorbold#1 "); $$ = nodeAddChild (newNode (Italics), $2); } |
| 316 | + | APO2 textnoitalpipe APO3 textnoboitpipe APO5 |
| 317 | + { debugf ("italicsorbold#2 "); $$ = nodeAddChild (newNode (Italics), |
| 318 | + makeTextBlock ($2, nodeAddChild (newNode (Bold), $4))); } |
| 319 | + | APO2 textnoitalpipe APO3 textnoboitpipe |
| 320 | + { debugf ("italicsorbold#3 "); $$ = |
| 321 | + makeTextBlock2 (nodeAddChild (newNode (Italics), $2), newNodeS (TextToken, "'"), $4); } |
| 322 | + | APO2 textnoitalpipe |
| 323 | + { debugf ("italicsorbold#4 "); $$ = makeTextBlock (newNodeS (TextToken, "''"), $2); } |
| 324 | + | APO3 textnoboldpipe APO3 |
| 325 | + { debugf ("italicsorbold#5 "); $$ = nodeAddChild (newNode (Bold), $2); } |
| 326 | + | APO3 textnoboldpipe APO2 textnoboitpipe APO5 |
| 327 | + { debugf ("italicsorbold#6 "); $$ = nodeAddChild (newNode (Bold), |
| 328 | + makeTextBlock ($2, nodeAddChild (newNode (Italics), $4))); } |
| 329 | + | APO3 textnoboldpipe APO2 textnoboitpipe |
| 330 | + { debugf ("italicsorbold#7 "); $$ = processNestedItalics (makeTextBlock2 (newNodeS |
| 331 | + (TextToken, "'"), nodeAddChild (newNode (Italics), $2), $4)); } |
| 332 | + | APO3 textnoboldpipe APO2 |
| 333 | + { debugf ("italicsorbold#8 "); $$ = processNestedItalics (makeTextBlock (newNodeS |
| 334 | + (TextToken, "'"), nodeAddChild (newNode (Italics), $2))); } |
| 335 | + | APO3 textnoboldpipe |
| 336 | + { debugf ("italicsorbold#9 "); $$ = makeTextBlock (newNodeS (TextToken, "'''"), $2); } |
| 337 | + | APO5 textnoboitpipe APO5 |
| 338 | + { debugf ("italicsorbold#10 "); $$ = nodeAddChild (newNode (Italics), |
| 339 | + nodeAddChild (newNode (Bold), $2)); } |
| 340 | + | APO5 textnoboitpipe APO3 textnoitalpipe APO2 |
| 341 | + { debugf ("italicsorbold#11 "); $$ = nodeAddChild (newNode (Italics), |
| 342 | + makeTextBlock (nodeAddChild (newNode (Bold), $2), $4)); } |
| 343 | + | APO5 textnoboitpipe APO3 textnoitalpipe |
| 344 | + { debugf ("italicsorbold#12 "); $$ = makeTextBlock2 (newNodeS (TextToken, "''"), |
| 345 | + nodeAddChild (newNode (Bold), $2), $4); } |
| 346 | + | APO5 textnoboitpipe APO3 |
| 347 | + { debugf ("italicsorbold#13 "); $$ = makeTextBlock (newNodeS (TextToken, "''"), |
| 348 | + nodeAddChild (newNode (Bold), $2)); } |
| 349 | + | APO5 textnoboitpipe APO2 textnoboldpipe APO3 |
| 350 | + { debugf ("italicsorbold#14 "); $$ = nodeAddChild (newNode (Bold), |
| 351 | + makeTextBlock (nodeAddChild (newNode (Italics), $2), $4)); } |
| 352 | + | APO5 textnoboitpipe APO2 textnoboldpipe |
| 353 | + { debugf ("italicsorbold#15 "); $$ = makeTextBlock2 (newNodeS (TextToken, "'''"), |
| 354 | + nodeAddChild (newNode (Italics), $2), $4); } |
| 355 | + | APO5 textnoboitpipe APO2 |
| 356 | + { debugf ("italicsorbold#16 "); $$ = makeTextBlock (newNodeS (TextToken, "'''"), |
| 357 | + nodeAddChild (newNode (Italics), $2)); } |
| 358 | + | APO5 textnoboitpipe |
| 359 | + { debugf ("italicsorbold#17 "); |
| 360 | + $$ = makeTextBlock (newNodeS (TextToken, "'''''"), $2); } |
| 361 | + |
| 362 | +italorboldnotblp: APO2 textnoitaltblpipe APO2 |
| 363 | + { debugf ("italorboldnotbl#1 "); $$ = nodeAddChild (newNode (Italics), $2); } |
| 364 | + | APO2 textnoitaltblpipe APO3 textnoboittblpipe APO5 |
| 365 | + { debugf ("italorboldnotbl#2 "); $$ = nodeAddChild (newNode (Italics), |
| 366 | + makeTextBlock ($2, nodeAddChild (newNode (Bold), $4))); } |
| 367 | + | APO2 textnoitaltblpipe APO3 textnoboittblpipe |
| 368 | + { debugf ("italorboldnotbl#3 "); $$ = |
| 369 | + makeTextBlock2 (nodeAddChild (newNode (Italics), $2), newNodeS (TextToken, "'"), $4); } |
| 370 | + | APO2 textnoitaltblpipe |
| 371 | + { debugf ("italorboldnotbl#4 "); $$ = makeTextBlock (newNodeS (TextToken, "''"), $2); } |
| 372 | + | APO3 textnoboldtblpipe APO3 |
| 373 | + { debugf ("italorboldnotbl#5 "); $$ = nodeAddChild (newNode (Bold), $2); } |
| 374 | + | APO3 textnoboldtblpipe APO2 textnoboittblpipe APO5 |
| 375 | + { debugf ("italorboldnotbl#6 "); $$ = nodeAddChild (newNode (Bold), |
| 376 | + makeTextBlock ($2, nodeAddChild (newNode (Italics), $4))); } |
| 377 | + | APO3 textnoboldtblpipe APO2 textnoboittblpipe |
| 378 | + { debugf ("italorboldnotbl#7 "); $$ = processNestedItalics (makeTextBlock2 (newNodeS |
| 379 | + (TextToken, "'"), nodeAddChild (newNode (Italics), $2), $4)); } |
| 380 | + | APO3 textnoboldtblpipe APO2 |
| 381 | + { debugf ("italorboldnotbl#8 "); $$ = processNestedItalics (makeTextBlock (newNodeS |
| 382 | + (TextToken, "'"), nodeAddChild (newNode (Italics), $2))); } |
| 383 | + | APO3 textnoboldtblpipe |
| 384 | + { debugf ("italorboldnotbl#9 "); $$ = makeTextBlock (newNodeS (TextToken, "'''"), $2); } |
| 385 | + | APO5 textnoboittblpipe APO5 |
| 386 | + { debugf ("italorboldnotbl#10 "); $$ = nodeAddChild (newNode (Italics), |
| 387 | + nodeAddChild (newNode (Bold), $2)); } |
| 388 | + | APO5 textnoboittblpipe APO3 textnoitaltblpipe APO2 |
| 389 | + { debugf ("italorboldnotbl#11 "); $$ = nodeAddChild (newNode (Italics), |
| 390 | + makeTextBlock (nodeAddChild (newNode (Bold), $2), $4)); } |
| 391 | + | APO5 textnoboittblpipe APO3 textnoitaltblpipe |
| 392 | + { debugf ("italorboldnotbl#12 "); $$ = makeTextBlock2 (newNodeS (TextToken, "''"), |
| 393 | + nodeAddChild (newNode (Bold), $2), $4); } |
| 394 | + | APO5 textnoboittblpipe APO3 |
| 395 | + { debugf ("italorboldnotbl#13 "); $$ = makeTextBlock (newNodeS (TextToken, "''"), |
| 396 | + nodeAddChild (newNode (Bold), $2)); } |
| 397 | + | APO5 textnoboittblpipe APO2 textnoboldtblpipe APO3 |
| 398 | + { debugf ("italorboldnotbl#14 "); $$ = nodeAddChild (newNode (Bold), |
| 399 | + makeTextBlock (nodeAddChild (newNode (Italics), $2), $4)); } |
| 400 | + | APO5 textnoboittblpipe APO2 textnoboldtblpipe |
| 401 | + { debugf ("italorboldnotbl#15 "); $$ = makeTextBlock2 (newNodeS (TextToken, "'''"), |
| 402 | + nodeAddChild (newNode (Italics), $2), $4); } |
| 403 | + | APO5 textnoboittblpipe APO2 |
| 404 | + { debugf ("italorboldnotbl#16 "); $$ = makeTextBlock (newNodeS (TextToken, "'''"), |
| 405 | + nodeAddChild (newNode (Italics), $2)); } |
| 406 | + | APO5 textnoboittblpipe |
| 407 | + { debugf ("italorboldnotbl#17 "); |
| 408 | + $$ = makeTextBlock (newNodeS (TextToken, "'''''"), $2); } |
| 409 | + |
312 | 410 | italicsnobold : APO2 textnoboit APO2 |
313 | 411 | { debugf ("italicsnobold#1 "); $$ = nodeAddChild (newNode (Italics), $2); } |
314 | 412 | | APO2 textnoboit |
— | — | @@ -318,6 +416,16 @@ |
319 | 417 | | APO3 textnoboit |
320 | 418 | { debugf ("boldnoitalics#2 "); $$ = makeTextBlock (newNodeS (TextToken, "'''"), $2); } |
321 | 419 | |
| 420 | +italicsnoboldpp : APO2 textnoboitpipe APO2 |
| 421 | + { debugf ("italicsnobold#1 "); $$ = nodeAddChild (newNode (Italics), $2); } |
| 422 | + | APO2 textnoboitpipe |
| 423 | + { debugf ("italicsnobold#2 "); $$ = makeTextBlock (newNodeS (TextToken, "''"), $2); } |
| 424 | + |
| 425 | +boldnoitalicspp : APO3 textnoboitpipe APO3 |
| 426 | + { debugf ("boldnoitalics#1 "); $$ = nodeAddChild (newNode (Bold), $2); } |
| 427 | + | APO3 textnoboitpipe |
| 428 | + { debugf ("boldnoitalics#2 "); $$ = makeTextBlock (newNodeS (TextToken, "'''"), $2); } |
| 429 | + |
322 | 430 | italicsnoboldtbl: APO2 textnoboittbl APO2 |
323 | 431 | { debugf ("italicsnobold#1 "); $$ = nodeAddChild (newNode (Italics), $2); } |
324 | 432 | | APO2 textnoboittbl |
— | — | @@ -328,6 +436,16 @@ |
329 | 437 | | APO3 textnoboittbl |
330 | 438 | { debugf ("boldnoitalics#2 "); $$ = makeTextBlock (newNodeS (TextToken, "'''"), $2); } |
331 | 439 | |
| 440 | +italnoboldtblpp : APO2 textnoboittblpipe APO2 |
| 441 | + { debugf ("italicsnobold#1 "); $$ = nodeAddChild (newNode (Italics), $2); } |
| 442 | + | APO2 textnoboittblpipe |
| 443 | + { debugf ("italicsnobold#2 "); $$ = makeTextBlock (newNodeS (TextToken, "''"), $2); } |
| 444 | + |
| 445 | +boldnoitaltblpp : APO3 textnoboittblpipe APO3 |
| 446 | + { debugf ("boldnoitalics#1 "); $$ = nodeAddChild (newNode (Bold), $2); } |
| 447 | + | APO3 textnoboittblpipe |
| 448 | + { debugf ("boldnoitalics#2 "); $$ = makeTextBlock (newNodeS (TextToken, "'''"), $2); } |
| 449 | + |
332 | 450 | table : TABLEBEGIN attributes tablerows TABLEEND |
333 | 451 | { debugf ("table#1 "); $$ = nodeAddChild2 (newNode (Table), $2, $3); } |
334 | 452 | | TABLEBEGIN attributes tablerows |
— | — | @@ -425,6 +543,22 @@ |
426 | 544 | | textnoboldtbl textelementnoboldtbl { debugf ("textnoboldtbl#2 "); $$ = makeTextBlock ($1, $2); } |
427 | 545 | textnoboittbl : textelementnoboittbl { debugf ("textnoboittbl#1 "); $$ = $1; } |
428 | 546 | | textnoboittbl textelementnoboittbl { debugf ("textnoboittbl#2 "); $$ = makeTextBlock ($1, $2); } |
| 547 | +textnopipe : textelementnopipe { debugf ("textnopipe#1 "); $$ = $1; } |
| 548 | + | textnopipe textelementnopipe { debugf ("textnopipe#2 "); $$ = makeTextBlock ($1, $2); } |
| 549 | +textnoitalpipe : textelementnoitp { debugf ("textnoitalpipe#1 "); $$ = $1; } |
| 550 | + | textnoitalpipe textelementnoitp { debugf ("textnoitalpipe#2 "); $$ = makeTextBlock ($1, $2); } |
| 551 | +textnoboldpipe : textelementnobldp { debugf ("textnoboldpipe#1 "); $$ = $1; } |
| 552 | + | textnoboldpipe textelementnobldp { debugf ("textnoboldpipe#2 "); $$ = makeTextBlock ($1, $2); } |
| 553 | +textnoboitpipe : textelementnobitp { debugf ("textnoboitpipe#1 "); $$ = $1; } |
| 554 | + | textnoboitpipe textelementnobitp { debugf ("textnoboitpipe#2 "); $$ = makeTextBlock ($1, $2); } |
| 555 | +textnotblpipe : textelementnotblpipe { debugf ("textnotblpipe#1 "); $$ = $1; } |
| 556 | + | textnotblpipe textelementnotblpipe { debugf ("textnotblpipe#2 "); $$ = makeTextBlock ($1, $2); } |
| 557 | +textnoitaltblpipe : textelementnoittbpp { debugf ("textnoitaltblpipe#1 "); $$ = $1; } |
| 558 | + | textnoitaltblpipe textelementnoittbpp { debugf ("textnoitaltblpipe#2 "); $$ = makeTextBlock ($1, $2); } |
| 559 | +textnoboldtblpipe : textelementnobltbpp { debugf ("textnoboldtblpipe#1 "); $$ = $1; } |
| 560 | + | textnoboldtblpipe textelementnobltbpp { debugf ("textnoboldtblpipe#2 "); $$ = makeTextBlock ($1, $2); } |
| 561 | +textnoboittblpipe : textelementnoblittbp { debugf ("textnoboittblpipe#1 "); $$ = $1; } |
| 562 | + | textnoboittblpipe textelementnoblittbp { debugf ("textnoboittblpipe#2 "); $$ = makeTextBlock ($1, $2); } |
429 | 563 | |
430 | 564 | textelement : TEXT { debugf ("textelement#1 "); $$ = $1; } |
431 | 565 | | EXTENSION { debugf ("textelement#2 "); $$ = $1; } |
— | — | @@ -442,6 +576,7 @@ |
443 | 577 | | comment { debugf ("textelement#15 "); $$ = $1; } |
444 | 578 | | linketc { debugf ("textelement#16 "); $$ = $1; } |
445 | 579 | | italicsorbold { debugf ("textelement#17 "); $$ = $1; } |
| 580 | + | CLOSEDBLSQBR { debugf ("textelement#18 "); $$ = newNodeS (TextToken, "]]"); } |
446 | 581 | |
447 | 582 | textelementnoital : TEXT { debugf ("textelementnoital#1 "); $$ = $1; } |
448 | 583 | | EXTENSION { debugf ("textelementnoital#2 "); $$ = $1; } |
— | — | @@ -454,6 +589,7 @@ |
455 | 590 | | comment { debugf ("textelementnoital#10 "); $$ = $1; } |
456 | 591 | | linketc { debugf ("textelementnoital#11 "); $$ = $1; } |
457 | 592 | | boldnoitalics { debugf ("textelementnoital#12 "); $$ = $1; } |
| 593 | + | CLOSEDBLSQBR { debugf ("textelementnoital#13 "); $$ = newNodeS (TextToken, "]]"); } |
458 | 594 | |
459 | 595 | textelementnobold : TEXT { debugf ("textelementnobold#1 "); $$ = $1; } |
460 | 596 | | EXTENSION { debugf ("textelementnobold#2 "); $$ = $1; } |
— | — | @@ -466,6 +602,7 @@ |
467 | 603 | | comment { debugf ("textelementnobold#10 "); $$ = $1; } |
468 | 604 | | linketc { debugf ("textelementnobold#11 "); $$ = $1; } |
469 | 605 | | italicsnobold { debugf ("textelementnobold#12 "); $$ = $1; } |
| 606 | + | CLOSEDBLSQBR { debugf ("textelementnobold#13 "); $$ = newNodeS (TextToken, "]]"); } |
470 | 607 | |
471 | 608 | textelementnoboit : TEXT { debugf ("textelementnoboit#1 "); $$ = $1; } |
472 | 609 | | EXTENSION { debugf ("textelementnoboit#2 "); $$ = $1; } |
— | — | @@ -477,6 +614,7 @@ |
478 | 615 | | TABLEHEAD { debugf ("textelementnoboit#9 "); $$ = convertTableHeadToText ($1); } |
479 | 616 | | comment { debugf ("textelementnoboit#10 "); $$ = $1; } |
480 | 617 | | linketc { debugf ("textelementnoboit#11 "); $$ = $1; } |
| 618 | + | CLOSEDBLSQBR { debugf ("textelementnoboit#12 "); $$ = newNodeS (TextToken, "]]"); } |
481 | 619 | |
482 | 620 | textelementnotbl : TEXT { debugf ("textelementnotbl#1 "); $$ = $1; } |
483 | 621 | | EXTENSION { debugf ("textelementnotbl#2 "); $$ = $1; } |
— | — | @@ -488,6 +626,7 @@ |
489 | 627 | | comment { debugf ("textelementnotbl#9 "); $$ = $1; } |
490 | 628 | | linketcnotbl { debugf ("textelementnotbl#10 "); $$ = $1; } |
491 | 629 | | italorboldnotbl { debugf ("textelementnotbl#11 "); $$ = $1; } |
| 630 | + | CLOSEDBLSQBR { debugf ("textelementnotbl#12 "); $$ = newNodeS (TextToken, "]]"); } |
492 | 631 | |
493 | 632 | textelementnoitaltbl: TEXT { debugf ("textelementnoitaltbl#1 "); $$ = $1; } |
494 | 633 | | EXTENSION { debugf ("textelementnoitaltbl#2 "); $$ = $1; } |
— | — | @@ -495,6 +634,7 @@ |
496 | 635 | | comment { debugf ("textelementnoitaltbl#5 "); $$ = $1; } |
497 | 636 | | linketcnotbl { debugf ("textelementnoitaltbl#6 "); $$ = $1; } |
498 | 637 | | boldnoitalicstbl{ debugf ("textelementnoitaltbl#7 "); $$ = $1; } |
| 638 | + | CLOSEDBLSQBR { debugf ("textelementnoitaltbl#8 "); $$ = newNodeS (TextToken, "]]"); } |
499 | 639 | |
500 | 640 | textelementnoboldtbl: TEXT { debugf ("textelementnoboldtbl#1 "); $$ = $1; } |
501 | 641 | | EXTENSION { debugf ("textelementnoboldtbl#2 "); $$ = $1; } |
— | — | @@ -502,13 +642,94 @@ |
503 | 643 | | comment { debugf ("textelementnoboldtbl#5 "); $$ = $1; } |
504 | 644 | | linketcnotbl { debugf ("textelementnoboldtbl#6 "); $$ = $1; } |
505 | 645 | | italicsnoboldtbl{ debugf ("textelementnoboldtbl#7 "); $$ = $1; } |
| 646 | + | CLOSEDBLSQBR { debugf ("textelementnoboldtbl#8 "); $$ = newNodeS (TextToken, "]]"); } |
506 | 647 | |
507 | 648 | textelementnoboittbl: TEXT { debugf ("textelementnoboittbl#1 "); $$ = $1; } |
508 | 649 | | EXTENSION { debugf ("textelementnoboittbl#2 "); $$ = $1; } |
509 | 650 | | PIPE { debugf ("textelementnoboittbl#3 "); $$ = newNodeS (TextToken, "|"); } |
510 | 651 | | comment { debugf ("textelementnoboittbl#5 "); $$ = $1; } |
511 | 652 | | linketcnotbl { debugf ("textelementnoboittbl#6 "); $$ = $1; } |
| 653 | + | CLOSEDBLSQBR { debugf ("textelementnoboittbl#7 "); $$ = newNodeS (TextToken, "]]"); } |
512 | 654 | |
| 655 | +textelementnopipe : TEXT { debugf ("textelementnopipe#1 "); $$ = $1; } |
| 656 | + | EXTENSION { debugf ("textelementnopipe#2 "); $$ = $1; } |
| 657 | + | APO2 { debugf ("textelementnopipe#5 "); $$ = newNodeS (TextToken, "''"); } |
| 658 | + | APO3 { debugf ("textelementnopipe#6 "); $$ = newNodeS (TextToken, "'''"); } |
| 659 | + | APO5 { debugf ("textelementnopipe#7 "); $$ = newNodeS (TextToken, "'''''"); } |
| 660 | + | EQUALS { debugf ("textelementnopipe#8 "); $$ = newNodeS (TextToken, addSpaces ("=", $1)); } |
| 661 | + | TABLEBEGIN { debugf ("textelementnopipe#9 "); $$ = newNodeS (TextToken, addSpaces ("{|", $1)); } |
| 662 | + | TABLEEND { debugf ("textelementnopipe#10 "); $$ = newNodeS (TextToken, "|}"); } |
| 663 | + | TABLEROW { debugf ("textelementnopipe#11 "); $$ = convertTableRowToText ($1); } |
| 664 | + | TABLECELL { debugf ("textelementnopipe#12 "); $$ = convertTableCellToText ($1); } |
| 665 | + | TABLEHEAD { debugf ("textelementnopipe#13 "); $$ = convertTableHeadToText ($1); } |
| 666 | + | ATTRIBUTE { debugf ("textelementnopipe#14 "); $$ = convertAttributeDataToText ($1); } |
| 667 | + | comment { debugf ("textelementnopipe#15 "); $$ = $1; } |
| 668 | + | linketc { debugf ("textelementnopipe#16 "); $$ = $1; } |
| 669 | + | italorboldnopipe{ debugf ("textelementnopipe#17 "); $$ = $1; } |
| 670 | + |
| 671 | +textelementnoitp : TEXT { debugf ("textelementnoitp#1 "); $$ = $1; } |
| 672 | + | EXTENSION { debugf ("textelementnoitp#2 "); $$ = $1; } |
| 673 | + | TABLEBEGIN { debugf ("textelementnoitp#5 "); $$ = newNodeS (TextToken, addSpaces ("{|", $1)); } |
| 674 | + | TABLEEND { debugf ("textelementnoitp#6 "); $$ = newNodeS (TextToken, "|}"); } |
| 675 | + | TABLEROW { debugf ("textelementnoitp#7 "); $$ = convertTableRowToText ($1); } |
| 676 | + | TABLECELL { debugf ("textelementnoitp#8 "); $$ = convertTableCellToText ($1); } |
| 677 | + | TABLEHEAD { debugf ("textelementnoitp#9 "); $$ = convertTableHeadToText ($1); } |
| 678 | + | comment { debugf ("textelementnoitp#10 "); $$ = $1; } |
| 679 | + | linketc { debugf ("textelementnoitp#11 "); $$ = $1; } |
| 680 | + | boldnoitalicspp { debugf ("textelementnoitp#12 "); $$ = $1; } |
| 681 | + |
| 682 | +textelementnobldp : TEXT { debugf ("textelementnobldp#1 "); $$ = $1; } |
| 683 | + | EXTENSION { debugf ("textelementnobldp#2 "); $$ = $1; } |
| 684 | + | TABLEBEGIN { debugf ("textelementnobldp#5 "); $$ = newNodeS (TextToken, addSpaces ("{|", $1)); } |
| 685 | + | TABLEEND { debugf ("textelementnobldp#6 "); $$ = newNodeS (TextToken, "|}"); } |
| 686 | + | TABLEROW { debugf ("textelementnobldp#7 "); $$ = convertTableRowToText ($1); } |
| 687 | + | TABLECELL { debugf ("textelementnobldp#8 "); $$ = convertTableCellToText ($1); } |
| 688 | + | TABLEHEAD { debugf ("textelementnobldp#9 "); $$ = convertTableHeadToText ($1); } |
| 689 | + | comment { debugf ("textelementnobldp#10 "); $$ = $1; } |
| 690 | + | linketc { debugf ("textelementnobldp#11 "); $$ = $1; } |
| 691 | + | italicsnoboldpp { debugf ("textelementnobldp#12 "); $$ = $1; } |
| 692 | + |
| 693 | +textelementnobitp : TEXT { debugf ("textelementnobitp#1 "); $$ = $1; } |
| 694 | + | EXTENSION { debugf ("textelementnobitp#2 "); $$ = $1; } |
| 695 | + | TABLEBEGIN { debugf ("textelementnobitp#5 "); $$ = newNodeS (TextToken, addSpaces ("{|", $1)); } |
| 696 | + | TABLEEND { debugf ("textelementnobitp#6 "); $$ = newNodeS (TextToken, "|}"); } |
| 697 | + | TABLEROW { debugf ("textelementnobitp#7 "); $$ = convertTableRowToText ($1); } |
| 698 | + | TABLECELL { debugf ("textelementnobitp#8 "); $$ = convertTableCellToText ($1); } |
| 699 | + | TABLEHEAD { debugf ("textelementnobitp#9 "); $$ = convertTableHeadToText ($1); } |
| 700 | + | comment { debugf ("textelementnobitp#10 "); $$ = $1; } |
| 701 | + | linketc { debugf ("textelementnobitp#11 "); $$ = $1; } |
| 702 | + |
| 703 | +textelementnotblpipe: TEXT { debugf ("textelementnotblpipe#1 "); $$ = $1; } |
| 704 | + | EXTENSION { debugf ("textelementnotblpipe#2 "); $$ = $1; } |
| 705 | + | PIPE { debugf ("textelementnotblpipe#3 "); $$ = newNodeS (TextToken, "|"); } |
| 706 | + | APO2 { debugf ("textelementnotblpipe#5 "); $$ = newNodeS (TextToken, "''"); } |
| 707 | + | APO3 { debugf ("textelementnotblpipe#6 "); $$ = newNodeS (TextToken, "'''"); } |
| 708 | + | APO5 { debugf ("textelementnotblpipe#7 "); $$ = newNodeS (TextToken, "'''''"); } |
| 709 | + | EQUALS { debugf ("textelementnotblpipe#8 "); $$ = newNodeS (TextToken, addSpaces ("=", $1)); } |
| 710 | + | comment { debugf ("textelementnotblpipe#9 "); $$ = $1; } |
| 711 | + | linketcnotbl { debugf ("textelementnotblpipe#10 "); $$ = $1; } |
| 712 | + | italorboldnotblp{ debugf ("textelementnotblpipe#11 "); $$ = $1; } |
| 713 | + |
| 714 | +textelementnoittbpp : TEXT { debugf ("textelementnoittbpp#1 "); $$ = $1; } |
| 715 | + | EXTENSION { debugf ("textelementnoittbpp#2 "); $$ = $1; } |
| 716 | + | PIPE { debugf ("textelementnoittbpp#3 "); $$ = newNodeS (TextToken, "|"); } |
| 717 | + | comment { debugf ("textelementnoittbpp#5 "); $$ = $1; } |
| 718 | + | linketcnotbl { debugf ("textelementnoittbpp#6 "); $$ = $1; } |
| 719 | + | boldnoitaltblpp { debugf ("textelementnoittbpp#7 "); $$ = $1; } |
| 720 | + |
| 721 | +textelementnobltbpp : TEXT { debugf ("textelementnobltbpp#1 "); $$ = $1; } |
| 722 | + | EXTENSION { debugf ("textelementnobltbpp#2 "); $$ = $1; } |
| 723 | + | PIPE { debugf ("textelementnobltbpp#3 "); $$ = newNodeS (TextToken, "|"); } |
| 724 | + | comment { debugf ("textelementnobltbpp#5 "); $$ = $1; } |
| 725 | + | linketcnotbl { debugf ("textelementnobltbpp#6 "); $$ = $1; } |
| 726 | + | italnoboldtblpp { debugf ("textelementnobltbpp#7 "); $$ = $1; } |
| 727 | + |
| 728 | +textelementnoblittbp: TEXT { debugf ("textelementnoblittbp#1 "); $$ = $1; } |
| 729 | + | EXTENSION { debugf ("textelementnoblittbp#2 "); $$ = $1; } |
| 730 | + | PIPE { debugf ("textelementnoblittbp#3 "); $$ = newNodeS (TextToken, "|"); } |
| 731 | + | comment { debugf ("textelementnoblittbp#5 "); $$ = $1; } |
| 732 | + | linketcnotbl { debugf ("textelementnoblittbp#6 "); $$ = $1; } |
| 733 | + |
513 | 734 | zeroormorenewlines : /* empty */ { debugf ("zeroormorenewlines#1 "); $$ = 0; } |
514 | 735 | | oneormorenewlines { debugf ("zeroormorenewlines#2 "); $$ = 0; } |
515 | 736 | oneormorenewlines : NEWLINE { debugf ("oneormorenewlines#1 "); $$ = 0; } |