From: Fletcher T. Penney Date: Sun, 16 Jul 2017 01:35:49 +0000 (-0400) Subject: FIXED: Fix table wrapping with default alignment X-Git-Tag: 6.2.0^2~33 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=317bf7b29d9bcd01e0bc786da581bb44c62a1ecd;p=multimarkdown FIXED: Fix table wrapping with default alignment --- diff --git a/Sources/libMultiMarkdown/html.c b/Sources/libMultiMarkdown/html.c index b3687f5..2e06bb0 100644 --- a/Sources/libMultiMarkdown/html.c +++ b/Sources/libMultiMarkdown/html.c @@ -803,6 +803,7 @@ void mmd_export_token_html(DString * out, const char * source, token * t, scratc case 'l': print_const("\n"); break; + case 'N': case 'L': print_const("\n"); break; diff --git a/Sources/libMultiMarkdown/latex.c b/Sources/libMultiMarkdown/latex.c index 3f86e04..8912c49 100644 --- a/Sources/libMultiMarkdown/latex.c +++ b/Sources/libMultiMarkdown/latex.c @@ -754,6 +754,9 @@ void mmd_export_token_latex(DString * out, const char * source, token * t, scrat case 'C': print_char(scratch->table_alignment[i]); break; + case 'N': + print_char('L'); + break; default: print_char('l'); break; diff --git a/Sources/libMultiMarkdown/scanners.c b/Sources/libMultiMarkdown/scanners.c index 6ebb019..e1a5e7c 100644 --- a/Sources/libMultiMarkdown/scanners.c +++ b/Sources/libMultiMarkdown/scanners.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.14.3 on Mon May 1 19:25:34 2017 */ +/* Generated by re2c 0.14.3 on Sat Jul 15 21:20:00 2017 */ /** MultiMarkdown 6 -- Lightweight markup processor to produce HTML, LaTeX, and more. @@ -69671,8 +69671,8 @@ size_t scan_alignment_string(const char * c) { case '\t': case ' ': goto yy1385; case '-': - case '=': goto yy1389; - case ':': goto yy1388; + case '=': goto yy1388; + case ':': goto yy1389; case 0xC2: goto yy1386; case 0xC3: case 0xC4: @@ -69732,11 +69732,11 @@ yy1385: yych = *(marker = ++c); switch (yych) { case '\t': - case ' ': goto yy1440; + case ' ': goto yy1446; case '-': - case '=': goto yy1398; - case ':': goto yy1439; - case 0xC2: goto yy1442; + case '=': goto yy1425; + case ':': goto yy1445; + case 0xC2: goto yy1448; default: goto yy1384; } yy1386: @@ -69814,16 +69814,17 @@ yy1387: yy1388: yych = *(marker = ++c); switch (yych) { + case '+': goto yy1427; case '-': - case '=': goto yy1412; + case '=': goto yy1425; + case ':': goto yy1424; default: goto yy1384; } yy1389: yych = *(marker = ++c); switch (yych) { case '-': - case '=': goto yy1398; - case ':': goto yy1397; + case '=': goto yy1397; default: goto yy1384; } yy1390: @@ -70148,50 +70149,57 @@ yy1396: default: goto yy1387; } yy1397: - yych = *++c; - switch (yych) { - case '+': goto yy1406; - default: goto yy1401; - } -yy1398: ++c; yych = *c; switch (yych) { + case 0x00: + case '\n': + case '|': goto yy1402; + case '\t': + case ' ': goto yy1399; + case '\r': goto yy1404; + case '+': goto yy1406; case '-': - case '=': goto yy1398; - case ':': goto yy1397; + case '=': goto yy1397; + case ':': goto yy1405; + case 0xC2: goto yy1401; default: goto yy1387; } -yy1400: +yy1399: ++c; yych = *c; -yy1401: switch (yych) { case 0x00: case '\n': - case '|': goto yy1403; + case '|': goto yy1402; case '\t': - case ' ': goto yy1400; - case '\r': goto yy1405; - case 0xC2: goto yy1402; + case ' ': goto yy1399; + case '\r': goto yy1404; + case 0xC2: goto yy1401; default: goto yy1387; } -yy1402: +yy1401: ++c; yych = *c; switch (yych) { - case 0xA0: goto yy1400; + case 0xA0: goto yy1399; default: goto yy1387; } -yy1403: +yy1402: ++c; +yy1403: + { return ALIGN_LEFT; } yy1404: - { return ALIGN_RIGHT; } + yych = *++c; + switch (yych) { + case '\n': goto yy1402; + default: goto yy1403; + } yy1405: yych = *++c; switch (yych) { - case '\n': goto yy1403; - default: goto yy1404; + case '+': goto yy1412; + default: goto yy1415; } yy1406: ++c; @@ -70216,7 +70224,7 @@ yy1408: yy1409: ++c; yy1410: - { return ALIGN_WRAP | ALIGN_RIGHT; } + { return ALIGN_WRAP | ALIGN_LEFT; } yy1411: yych = *++c; switch (yych) { @@ -70229,20 +70237,17 @@ yy1412: switch (yych) { case 0x00: case '\n': - case '|': goto yy1417; + case '|': goto yy1421; case '\t': - case ' ': goto yy1414; - case '\r': goto yy1419; - case '+': goto yy1421; - case '-': - case '=': goto yy1412; - case ':': goto yy1420; - case 0xC2: goto yy1416; + case ' ': goto yy1412; + case '\r': goto yy1423; + case 0xC2: goto yy1420; default: goto yy1387; } yy1414: ++c; yych = *c; +yy1415: switch (yych) { case 0x00: case '\n': @@ -70263,7 +70268,7 @@ yy1416: yy1417: ++c; yy1418: - { return ALIGN_LEFT; } + { return ALIGN_CENTER; } yy1419: yych = *++c; switch (yych) { @@ -70271,126 +70276,153 @@ yy1419: default: goto yy1418; } yy1420: + ++c; + yych = *c; + switch (yych) { + case 0xA0: goto yy1412; + default: goto yy1387; + } +yy1421: + ++c; +yy1422: + { return ALIGN_WRAP | ALIGN_CENTER; } +yy1423: yych = *++c; switch (yych) { + case '\n': goto yy1421; + default: goto yy1422; + } +yy1424: + yych = *++c; + switch (yych) { + case '+': goto yy1439; + default: goto yy1434; + } +yy1425: + ++c; + yych = *c; + switch (yych) { case '+': goto yy1427; - default: goto yy1430; + case '-': + case '=': goto yy1425; + case ':': goto yy1424; + default: goto yy1387; } -yy1421: +yy1427: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '|': goto yy1424; + case '|': goto yy1430; case '\t': - case ' ': goto yy1421; - case '\r': goto yy1426; - case 0xC2: goto yy1423; + case ' ': goto yy1427; + case '\r': goto yy1432; + case 0xC2: goto yy1429; default: goto yy1387; } -yy1423: +yy1429: ++c; yych = *c; switch (yych) { - case 0xA0: goto yy1421; + case 0xA0: goto yy1427; default: goto yy1387; } -yy1424: +yy1430: ++c; -yy1425: - { return ALIGN_WRAP | ALIGN_LEFT; } -yy1426: +yy1431: + { return ALIGN_WRAP; } +yy1432: yych = *++c; switch (yych) { - case '\n': goto yy1424; - default: goto yy1425; + case '\n': goto yy1430; + default: goto yy1431; } -yy1427: +yy1433: ++c; yych = *c; +yy1434: switch (yych) { case 0x00: case '\n': case '|': goto yy1436; case '\t': - case ' ': goto yy1427; + case ' ': goto yy1433; case '\r': goto yy1438; case 0xC2: goto yy1435; default: goto yy1387; } -yy1429: +yy1435: ++c; yych = *c; -yy1430: switch (yych) { - case 0x00: - case '\n': - case '|': goto yy1432; - case '\t': - case ' ': goto yy1429; - case '\r': goto yy1434; - case 0xC2: goto yy1431; + case 0xA0: goto yy1433; default: goto yy1387; } -yy1431: +yy1436: ++c; - yych = *c; +yy1437: + { return ALIGN_RIGHT; } +yy1438: + yych = *++c; switch (yych) { - case 0xA0: goto yy1429; - default: goto yy1387; + case '\n': goto yy1436; + default: goto yy1437; } -yy1432: +yy1439: ++c; -yy1433: - { return ALIGN_CENTER; } -yy1434: - yych = *++c; + yych = *c; switch (yych) { - case '\n': goto yy1432; - default: goto yy1433; + case 0x00: + case '\n': + case '|': goto yy1442; + case '\t': + case ' ': goto yy1439; + case '\r': goto yy1444; + case 0xC2: goto yy1441; + default: goto yy1387; } -yy1435: +yy1441: ++c; yych = *c; switch (yych) { - case 0xA0: goto yy1427; + case 0xA0: goto yy1439; default: goto yy1387; } -yy1436: +yy1442: ++c; -yy1437: - { return ALIGN_WRAP | ALIGN_CENTER; } -yy1438: +yy1443: + { return ALIGN_WRAP | ALIGN_RIGHT; } +yy1444: yych = *++c; switch (yych) { - case '\n': goto yy1436; - default: goto yy1437; + case '\n': goto yy1442; + default: goto yy1443; } -yy1439: +yy1445: yych = *++c; switch (yych) { case '-': - case '=': goto yy1412; + case '=': goto yy1397; default: goto yy1387; } -yy1440: +yy1446: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy1440; + case ' ': goto yy1446; case '-': - case '=': goto yy1398; - case ':': goto yy1439; - case 0xC2: goto yy1442; + case '=': goto yy1425; + case ':': goto yy1445; + case 0xC2: goto yy1448; default: goto yy1387; } -yy1442: +yy1448: ++c; yych = *c; switch (yych) { - case 0xA0: goto yy1440; + case 0xA0: goto yy1446; default: goto yy1387; } } @@ -70411,7 +70443,7 @@ size_t scan_destination(const char * c) { case 0x00: case '\t': case '\r': - case ' ': goto yy1457; + case ' ': goto yy1463; case 0x01: case 0x02: case 0x03: @@ -70533,9 +70565,9 @@ size_t scan_destination(const char * c) { case '|': case '}': case '~': - case 0x7F: goto yy1448; - case '<': goto yy1446; - case 0xC2: goto yy1449; + case 0x7F: goto yy1454; + case '<': goto yy1452; + case 0xC2: goto yy1455; case 0xC3: case 0xC4: case 0xC5: @@ -70564,8 +70596,8 @@ size_t scan_destination(const char * c) { case 0xDC: case 0xDD: case 0xDE: - case 0xDF: goto yy1451; - case 0xE0: goto yy1452; + case 0xDF: goto yy1457; + case 0xE0: goto yy1458; case 0xE1: case 0xE2: case 0xE3: @@ -70580,27 +70612,27 @@ size_t scan_destination(const char * c) { case 0xEC: case 0xED: case 0xEE: - case 0xEF: goto yy1453; - case 0xF0: goto yy1454; + case 0xEF: goto yy1459; + case 0xF0: goto yy1460; case 0xF1: case 0xF2: - case 0xF3: goto yy1455; - case 0xF4: goto yy1456; - default: goto yy1445; + case 0xF3: goto yy1461; + case 0xF4: goto yy1462; + default: goto yy1451; } -yy1445: +yy1451: { return 0; } -yy1446: +yy1452: yyaccept = 1; yych = *(marker = ++c); - goto yy1468; -yy1447: + goto yy1474; +yy1453: { return (size_t)( c - start ); } -yy1448: +yy1454: yyaccept = 1; yych = *(marker = ++c); - goto yy1459; -yy1449: + goto yy1465; +yy1455: yych = *++c; switch (yych) { case 0x80: @@ -70665,18 +70697,18 @@ yy1449: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1448; - case 0xA0: goto yy1457; - default: goto yy1450; + case 0xBF: goto yy1454; + case 0xA0: goto yy1463; + default: goto yy1456; } -yy1450: +yy1456: c = marker; if (yyaccept == 0) { - goto yy1445; + goto yy1451; } else { - goto yy1447; + goto yy1453; } -yy1451: +yy1457: yych = *++c; switch (yych) { case 0x80: @@ -70742,10 +70774,10 @@ yy1451: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1448; - default: goto yy1450; + case 0xBF: goto yy1454; + default: goto yy1456; } -yy1452: +yy1458: yych = *++c; switch (yych) { case 0xA0: @@ -70779,10 +70811,10 @@ yy1452: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1451; - default: goto yy1450; + case 0xBF: goto yy1457; + default: goto yy1456; } -yy1453: +yy1459: yych = *++c; switch (yych) { case 0x80: @@ -70848,10 +70880,10 @@ yy1453: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1451; - default: goto yy1450; + case 0xBF: goto yy1457; + default: goto yy1456; } -yy1454: +yy1460: yych = *++c; switch (yych) { case 0x90: @@ -70901,10 +70933,10 @@ yy1454: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1453; - default: goto yy1450; + case 0xBF: goto yy1459; + default: goto yy1456; } -yy1455: +yy1461: yych = *++c; switch (yych) { case 0x80: @@ -70970,10 +71002,10 @@ yy1455: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1453; - default: goto yy1450; + case 0xBF: goto yy1459; + default: goto yy1456; } -yy1456: +yy1462: yych = *++c; switch (yych) { case 0x80: @@ -70991,17 +71023,17 @@ yy1456: case 0x8C: case 0x8D: case 0x8E: - case 0x8F: goto yy1453; - default: goto yy1450; + case 0x8F: goto yy1459; + default: goto yy1456; } -yy1457: +yy1463: yych = *++c; - goto yy1445; -yy1458: + goto yy1451; +yy1464: yyaccept = 1; marker = ++c; yych = *c; -yy1459: +yy1465: switch (yych) { case 0x01: case 0x02: @@ -71125,8 +71157,8 @@ yy1459: case '|': case '}': case '~': - case 0x7F: goto yy1458; - case 0xC2: goto yy1460; + case 0x7F: goto yy1464; + case 0xC2: goto yy1466; case 0xC3: case 0xC4: case 0xC5: @@ -71155,8 +71187,8 @@ yy1459: case 0xDC: case 0xDD: case 0xDE: - case 0xDF: goto yy1461; - case 0xE0: goto yy1462; + case 0xDF: goto yy1467; + case 0xE0: goto yy1468; case 0xE1: case 0xE2: case 0xE3: @@ -71171,15 +71203,15 @@ yy1459: case 0xEC: case 0xED: case 0xEE: - case 0xEF: goto yy1463; - case 0xF0: goto yy1464; + case 0xEF: goto yy1469; + case 0xF0: goto yy1470; case 0xF1: case 0xF2: - case 0xF3: goto yy1465; - case 0xF4: goto yy1466; - default: goto yy1447; + case 0xF3: goto yy1471; + case 0xF4: goto yy1472; + default: goto yy1453; } -yy1460: +yy1466: ++c; yych = *c; switch (yych) { @@ -71245,10 +71277,10 @@ yy1460: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1458; - default: goto yy1450; + case 0xBF: goto yy1464; + default: goto yy1456; } -yy1461: +yy1467: ++c; yych = *c; switch (yych) { @@ -71315,10 +71347,10 @@ yy1461: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1458; - default: goto yy1450; + case 0xBF: goto yy1464; + default: goto yy1456; } -yy1462: +yy1468: ++c; yych = *c; switch (yych) { @@ -71353,10 +71385,10 @@ yy1462: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1461; - default: goto yy1450; + case 0xBF: goto yy1467; + default: goto yy1456; } -yy1463: +yy1469: ++c; yych = *c; switch (yych) { @@ -71423,10 +71455,10 @@ yy1463: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1461; - default: goto yy1450; + case 0xBF: goto yy1467; + default: goto yy1456; } -yy1464: +yy1470: ++c; yych = *c; switch (yych) { @@ -71477,10 +71509,10 @@ yy1464: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1463; - default: goto yy1450; + case 0xBF: goto yy1469; + default: goto yy1456; } -yy1465: +yy1471: ++c; yych = *c; switch (yych) { @@ -71547,10 +71579,10 @@ yy1465: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1463; - default: goto yy1450; + case 0xBF: goto yy1469; + default: goto yy1456; } -yy1466: +yy1472: ++c; yych = *c; switch (yych) { @@ -71569,14 +71601,14 @@ yy1466: case 0x8C: case 0x8D: case 0x8E: - case 0x8F: goto yy1463; - default: goto yy1450; + case 0x8F: goto yy1469; + default: goto yy1456; } -yy1467: +yy1473: yyaccept = 1; marker = ++c; yych = *c; -yy1468: +yy1474: switch (yych) { case 0x01: case 0x02: @@ -71699,9 +71731,9 @@ yy1468: case '|': case '}': case '~': - case 0x7F: goto yy1467; - case '>': goto yy1458; - case 0xC2: goto yy1469; + case 0x7F: goto yy1473; + case '>': goto yy1464; + case 0xC2: goto yy1475; case 0xC3: case 0xC4: case 0xC5: @@ -71730,8 +71762,8 @@ yy1468: case 0xDC: case 0xDD: case 0xDE: - case 0xDF: goto yy1470; - case 0xE0: goto yy1471; + case 0xDF: goto yy1476; + case 0xE0: goto yy1477; case 0xE1: case 0xE2: case 0xE3: @@ -71746,15 +71778,15 @@ yy1468: case 0xEC: case 0xED: case 0xEE: - case 0xEF: goto yy1472; - case 0xF0: goto yy1473; + case 0xEF: goto yy1478; + case 0xF0: goto yy1479; case 0xF1: case 0xF2: - case 0xF3: goto yy1474; - case 0xF4: goto yy1475; - default: goto yy1447; + case 0xF3: goto yy1480; + case 0xF4: goto yy1481; + default: goto yy1453; } -yy1469: +yy1475: ++c; yych = *c; switch (yych) { @@ -71820,10 +71852,10 @@ yy1469: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1467; - default: goto yy1450; + case 0xBF: goto yy1473; + default: goto yy1456; } -yy1470: +yy1476: ++c; yych = *c; switch (yych) { @@ -71890,10 +71922,10 @@ yy1470: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1467; - default: goto yy1450; + case 0xBF: goto yy1473; + default: goto yy1456; } -yy1471: +yy1477: ++c; yych = *c; switch (yych) { @@ -71928,10 +71960,10 @@ yy1471: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1470; - default: goto yy1450; + case 0xBF: goto yy1476; + default: goto yy1456; } -yy1472: +yy1478: ++c; yych = *c; switch (yych) { @@ -71998,10 +72030,10 @@ yy1472: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1470; - default: goto yy1450; + case 0xBF: goto yy1476; + default: goto yy1456; } -yy1473: +yy1479: ++c; yych = *c; switch (yych) { @@ -72052,10 +72084,10 @@ yy1473: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1472; - default: goto yy1450; + case 0xBF: goto yy1478; + default: goto yy1456; } -yy1474: +yy1480: ++c; yych = *c; switch (yych) { @@ -72122,10 +72154,10 @@ yy1474: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1472; - default: goto yy1450; + case 0xBF: goto yy1478; + default: goto yy1456; } -yy1475: +yy1481: ++c; yych = *c; switch (yych) { @@ -72144,8 +72176,8 @@ yy1475: case 0x8C: case 0x8D: case 0x8E: - case 0x8F: goto yy1472; - default: goto yy1450; + case 0x8F: goto yy1478; + default: goto yy1456; } } @@ -72284,10 +72316,10 @@ size_t scan_title(const char * c) { case '|': case '}': case '~': - case 0x7F: goto yy1482; - case '"': goto yy1479; - case '\'': goto yy1480; - case '(': goto yy1481; + case 0x7F: goto yy1488; + case '"': goto yy1485; + case '\'': goto yy1486; + case '(': goto yy1487; case 0xC2: case 0xC3: case 0xC4: @@ -72317,8 +72349,8 @@ size_t scan_title(const char * c) { case 0xDC: case 0xDD: case 0xDE: - case 0xDF: goto yy1483; - case 0xE0: goto yy1485; + case 0xDF: goto yy1489; + case 0xE0: goto yy1491; case 0xE1: case 0xE2: case 0xE3: @@ -72333,17 +72365,17 @@ size_t scan_title(const char * c) { case 0xEC: case 0xED: case 0xEE: - case 0xEF: goto yy1486; - case 0xF0: goto yy1487; + case 0xEF: goto yy1492; + case 0xF0: goto yy1493; case 0xF1: case 0xF2: - case 0xF3: goto yy1488; - case 0xF4: goto yy1489; - default: goto yy1478; + case 0xF3: goto yy1494; + case 0xF4: goto yy1495; + default: goto yy1484; } -yy1478: +yy1484: { return 0; } -yy1479: +yy1485: yych = *(marker = ++c); switch (yych) { case 0x01: @@ -72521,10 +72553,10 @@ yy1479: case 0xF1: case 0xF2: case 0xF3: - case 0xF4: goto yy1509; - default: goto yy1478; + case 0xF4: goto yy1515; + default: goto yy1484; } -yy1480: +yy1486: yych = *(marker = ++c); switch (yych) { case 0x01: @@ -72702,10 +72734,10 @@ yy1480: case 0xF1: case 0xF2: case 0xF3: - case 0xF4: goto yy1501; - default: goto yy1478; + case 0xF4: goto yy1507; + default: goto yy1484; } -yy1481: +yy1487: yych = *(marker = ++c); switch (yych) { case 0x01: @@ -72883,13 +72915,13 @@ yy1481: case 0xF1: case 0xF2: case 0xF3: - case 0xF4: goto yy1491; - default: goto yy1478; + case 0xF4: goto yy1497; + default: goto yy1484; } -yy1482: +yy1488: yych = *++c; - goto yy1478; -yy1483: + goto yy1484; +yy1489: yych = *++c; switch (yych) { case 0x80: @@ -72955,13 +72987,13 @@ yy1483: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1482; - default: goto yy1484; + case 0xBF: goto yy1488; + default: goto yy1490; } -yy1484: +yy1490: c = marker; - goto yy1478; -yy1485: + goto yy1484; +yy1491: yych = *++c; switch (yych) { case 0xA0: @@ -72995,10 +73027,10 @@ yy1485: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1483; - default: goto yy1484; + case 0xBF: goto yy1489; + default: goto yy1490; } -yy1486: +yy1492: yych = *++c; switch (yych) { case 0x80: @@ -73064,10 +73096,10 @@ yy1486: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1483; - default: goto yy1484; + case 0xBF: goto yy1489; + default: goto yy1490; } -yy1487: +yy1493: yych = *++c; switch (yych) { case 0x90: @@ -73117,10 +73149,10 @@ yy1487: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1486; - default: goto yy1484; + case 0xBF: goto yy1492; + default: goto yy1490; } -yy1488: +yy1494: yych = *++c; switch (yych) { case 0x80: @@ -73186,10 +73218,10 @@ yy1488: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1486; - default: goto yy1484; + case 0xBF: goto yy1492; + default: goto yy1490; } -yy1489: +yy1495: yych = *++c; switch (yych) { case 0x80: @@ -73207,13 +73239,13 @@ yy1489: case 0x8C: case 0x8D: case 0x8E: - case 0x8F: goto yy1486; - default: goto yy1484; + case 0x8F: goto yy1492; + default: goto yy1490; } -yy1490: +yy1496: ++c; yych = *c; -yy1491: +yy1497: switch (yych) { case 0x01: case 0x02: @@ -73338,8 +73370,8 @@ yy1491: case '|': case '}': case '~': - case 0x7F: goto yy1490; - case ')': goto yy1498; + case 0x7F: goto yy1496; + case ')': goto yy1504; case 0xC2: case 0xC3: case 0xC4: @@ -73369,8 +73401,8 @@ yy1491: case 0xDC: case 0xDD: case 0xDE: - case 0xDF: goto yy1492; - case 0xE0: goto yy1493; + case 0xDF: goto yy1498; + case 0xE0: goto yy1499; case 0xE1: case 0xE2: case 0xE3: @@ -73385,15 +73417,15 @@ yy1491: case 0xEC: case 0xED: case 0xEE: - case 0xEF: goto yy1494; - case 0xF0: goto yy1495; + case 0xEF: goto yy1500; + case 0xF0: goto yy1501; case 0xF1: case 0xF2: - case 0xF3: goto yy1496; - case 0xF4: goto yy1497; - default: goto yy1484; + case 0xF3: goto yy1502; + case 0xF4: goto yy1503; + default: goto yy1490; } -yy1492: +yy1498: ++c; yych = *c; switch (yych) { @@ -73460,10 +73492,10 @@ yy1492: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1490; - default: goto yy1484; + case 0xBF: goto yy1496; + default: goto yy1490; } -yy1493: +yy1499: ++c; yych = *c; switch (yych) { @@ -73498,10 +73530,10 @@ yy1493: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1492; - default: goto yy1484; + case 0xBF: goto yy1498; + default: goto yy1490; } -yy1494: +yy1500: ++c; yych = *c; switch (yych) { @@ -73568,10 +73600,10 @@ yy1494: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1492; - default: goto yy1484; + case 0xBF: goto yy1498; + default: goto yy1490; } -yy1495: +yy1501: ++c; yych = *c; switch (yych) { @@ -73622,10 +73654,10 @@ yy1495: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1494; - default: goto yy1484; + case 0xBF: goto yy1500; + default: goto yy1490; } -yy1496: +yy1502: ++c; yych = *c; switch (yych) { @@ -73692,10 +73724,10 @@ yy1496: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1494; - default: goto yy1484; + case 0xBF: goto yy1500; + default: goto yy1490; } -yy1497: +yy1503: ++c; yych = *c; switch (yych) { @@ -73714,16 +73746,16 @@ yy1497: case 0x8C: case 0x8D: case 0x8E: - case 0x8F: goto yy1494; - default: goto yy1484; + case 0x8F: goto yy1500; + default: goto yy1490; } -yy1498: +yy1504: ++c; { return (size_t)( c - start ); } -yy1500: +yy1506: ++c; yych = *c; -yy1501: +yy1507: switch (yych) { case 0x01: case 0x02: @@ -73848,8 +73880,8 @@ yy1501: case '|': case '}': case '~': - case 0x7F: goto yy1500; - case '\'': goto yy1498; + case 0x7F: goto yy1506; + case '\'': goto yy1504; case 0xC2: case 0xC3: case 0xC4: @@ -73879,8 +73911,8 @@ yy1501: case 0xDC: case 0xDD: case 0xDE: - case 0xDF: goto yy1502; - case 0xE0: goto yy1503; + case 0xDF: goto yy1508; + case 0xE0: goto yy1509; case 0xE1: case 0xE2: case 0xE3: @@ -73895,15 +73927,15 @@ yy1501: case 0xEC: case 0xED: case 0xEE: - case 0xEF: goto yy1504; - case 0xF0: goto yy1505; + case 0xEF: goto yy1510; + case 0xF0: goto yy1511; case 0xF1: case 0xF2: - case 0xF3: goto yy1506; - case 0xF4: goto yy1507; - default: goto yy1484; + case 0xF3: goto yy1512; + case 0xF4: goto yy1513; + default: goto yy1490; } -yy1502: +yy1508: ++c; yych = *c; switch (yych) { @@ -73970,10 +74002,10 @@ yy1502: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1500; - default: goto yy1484; + case 0xBF: goto yy1506; + default: goto yy1490; } -yy1503: +yy1509: ++c; yych = *c; switch (yych) { @@ -74008,10 +74040,10 @@ yy1503: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1502; - default: goto yy1484; + case 0xBF: goto yy1508; + default: goto yy1490; } -yy1504: +yy1510: ++c; yych = *c; switch (yych) { @@ -74078,10 +74110,10 @@ yy1504: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1502; - default: goto yy1484; + case 0xBF: goto yy1508; + default: goto yy1490; } -yy1505: +yy1511: ++c; yych = *c; switch (yych) { @@ -74132,10 +74164,10 @@ yy1505: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1504; - default: goto yy1484; + case 0xBF: goto yy1510; + default: goto yy1490; } -yy1506: +yy1512: ++c; yych = *c; switch (yych) { @@ -74202,10 +74234,10 @@ yy1506: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1504; - default: goto yy1484; + case 0xBF: goto yy1510; + default: goto yy1490; } -yy1507: +yy1513: ++c; yych = *c; switch (yych) { @@ -74224,13 +74256,13 @@ yy1507: case 0x8C: case 0x8D: case 0x8E: - case 0x8F: goto yy1504; - default: goto yy1484; + case 0x8F: goto yy1510; + default: goto yy1490; } -yy1508: +yy1514: ++c; yych = *c; -yy1509: +yy1515: switch (yych) { case 0x01: case 0x02: @@ -74355,8 +74387,8 @@ yy1509: case '|': case '}': case '~': - case 0x7F: goto yy1508; - case '"': goto yy1498; + case 0x7F: goto yy1514; + case '"': goto yy1504; case 0xC2: case 0xC3: case 0xC4: @@ -74386,8 +74418,8 @@ yy1509: case 0xDC: case 0xDD: case 0xDE: - case 0xDF: goto yy1510; - case 0xE0: goto yy1511; + case 0xDF: goto yy1516; + case 0xE0: goto yy1517; case 0xE1: case 0xE2: case 0xE3: @@ -74402,15 +74434,15 @@ yy1509: case 0xEC: case 0xED: case 0xEE: - case 0xEF: goto yy1512; - case 0xF0: goto yy1513; + case 0xEF: goto yy1518; + case 0xF0: goto yy1519; case 0xF1: case 0xF2: - case 0xF3: goto yy1514; - case 0xF4: goto yy1515; - default: goto yy1484; + case 0xF3: goto yy1520; + case 0xF4: goto yy1521; + default: goto yy1490; } -yy1510: +yy1516: ++c; yych = *c; switch (yych) { @@ -74477,10 +74509,10 @@ yy1510: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1508; - default: goto yy1484; + case 0xBF: goto yy1514; + default: goto yy1490; } -yy1511: +yy1517: ++c; yych = *c; switch (yych) { @@ -74515,10 +74547,10 @@ yy1511: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1510; - default: goto yy1484; + case 0xBF: goto yy1516; + default: goto yy1490; } -yy1512: +yy1518: ++c; yych = *c; switch (yych) { @@ -74585,10 +74617,10 @@ yy1512: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1510; - default: goto yy1484; + case 0xBF: goto yy1516; + default: goto yy1490; } -yy1513: +yy1519: ++c; yych = *c; switch (yych) { @@ -74639,10 +74671,10 @@ yy1513: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1512; - default: goto yy1484; + case 0xBF: goto yy1518; + default: goto yy1490; } -yy1514: +yy1520: ++c; yych = *c; switch (yych) { @@ -74709,10 +74741,10 @@ yy1514: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1512; - default: goto yy1484; + case 0xBF: goto yy1518; + default: goto yy1490; } -yy1515: +yy1521: ++c; yych = *c; switch (yych) { @@ -74731,8 +74763,8 @@ yy1515: case 0x8C: case 0x8D: case 0x8E: - case 0x8F: goto yy1512; - default: goto yy1484; + case 0x8F: goto yy1518; + default: goto yy1490; } } @@ -74870,11 +74902,11 @@ size_t scan_setext(const char * c) { case '|': case '}': case '~': - case 0x7F: goto yy1524; - case ' ': goto yy1519; - case '-': goto yy1523; - case '=': goto yy1522; - case 0xC2: goto yy1520; + case 0x7F: goto yy1530; + case ' ': goto yy1525; + case '-': goto yy1529; + case '=': goto yy1528; + case 0xC2: goto yy1526; case 0xC3: case 0xC4: case 0xC5: @@ -74903,8 +74935,8 @@ size_t scan_setext(const char * c) { case 0xDC: case 0xDD: case 0xDE: - case 0xDF: goto yy1525; - case 0xE0: goto yy1526; + case 0xDF: goto yy1531; + case 0xE0: goto yy1532; case 0xE1: case 0xE2: case 0xE3: @@ -74919,26 +74951,26 @@ size_t scan_setext(const char * c) { case 0xEC: case 0xED: case 0xEE: - case 0xEF: goto yy1527; - case 0xF0: goto yy1528; + case 0xEF: goto yy1533; + case 0xF0: goto yy1534; case 0xF1: case 0xF2: - case 0xF3: goto yy1529; - case 0xF4: goto yy1530; - default: goto yy1518; + case 0xF3: goto yy1535; + case 0xF4: goto yy1536; + default: goto yy1524; } -yy1518: +yy1524: { return 0; } -yy1519: +yy1525: yych = *(marker = ++c); switch (yych) { - case ' ': goto yy1541; - case '-': goto yy1543; - case '=': goto yy1544; - case 0xC2: goto yy1542; - default: goto yy1518; + case ' ': goto yy1547; + case '-': goto yy1549; + case '=': goto yy1550; + case 0xC2: goto yy1548; + default: goto yy1524; } -yy1520: +yy1526: yych = *++c; switch (yych) { case 0x80: @@ -75003,29 +75035,29 @@ yy1520: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1524; - case 0xA0: goto yy1519; - default: goto yy1521; + case 0xBF: goto yy1530; + case 0xA0: goto yy1525; + default: goto yy1527; } -yy1521: +yy1527: c = marker; - goto yy1518; -yy1522: + goto yy1524; +yy1528: yych = *(marker = ++c); switch (yych) { - case '=': goto yy1536; - default: goto yy1518; + case '=': goto yy1542; + default: goto yy1524; } -yy1523: +yy1529: yych = *(marker = ++c); switch (yych) { - case '-': goto yy1531; - default: goto yy1518; + case '-': goto yy1537; + default: goto yy1524; } -yy1524: +yy1530: yych = *++c; - goto yy1518; -yy1525: + goto yy1524; +yy1531: yych = *++c; switch (yych) { case 0x80: @@ -75091,10 +75123,10 @@ yy1525: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1524; - default: goto yy1521; + case 0xBF: goto yy1530; + default: goto yy1527; } -yy1526: +yy1532: yych = *++c; switch (yych) { case 0xA0: @@ -75128,10 +75160,10 @@ yy1526: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1525; - default: goto yy1521; + case 0xBF: goto yy1531; + default: goto yy1527; } -yy1527: +yy1533: yych = *++c; switch (yych) { case 0x80: @@ -75197,10 +75229,10 @@ yy1527: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1525; - default: goto yy1521; + case 0xBF: goto yy1531; + default: goto yy1527; } -yy1528: +yy1534: yych = *++c; switch (yych) { case 0x90: @@ -75250,10 +75282,10 @@ yy1528: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1527; - default: goto yy1521; + case 0xBF: goto yy1533; + default: goto yy1527; } -yy1529: +yy1535: yych = *++c; switch (yych) { case 0x80: @@ -75319,10 +75351,10 @@ yy1529: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1527; - default: goto yy1521; + case 0xBF: goto yy1533; + default: goto yy1527; } -yy1530: +yy1536: yych = *++c; switch (yych) { case 0x80: @@ -75340,88 +75372,88 @@ yy1530: case 0x8C: case 0x8D: case 0x8E: - case 0x8F: goto yy1527; - default: goto yy1521; + case 0x8F: goto yy1533; + default: goto yy1527; } -yy1531: +yy1537: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy1533; - case '\r': goto yy1535; - case '-': goto yy1531; - default: goto yy1521; + case '\n': goto yy1539; + case '\r': goto yy1541; + case '-': goto yy1537; + default: goto yy1527; } -yy1533: +yy1539: ++c; -yy1534: +yy1540: { return (size_t)( c - start ); } -yy1535: +yy1541: yych = *++c; switch (yych) { - case '\n': goto yy1533; - default: goto yy1534; + case '\n': goto yy1539; + default: goto yy1540; } -yy1536: +yy1542: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy1538; - case '\r': goto yy1540; - case '=': goto yy1536; - default: goto yy1521; + case '\n': goto yy1544; + case '\r': goto yy1546; + case '=': goto yy1542; + default: goto yy1527; } -yy1538: +yy1544: ++c; -yy1539: +yy1545: { return (size_t)( c - start ); } -yy1540: +yy1546: yych = *++c; switch (yych) { - case '\n': goto yy1538; - default: goto yy1539; + case '\n': goto yy1544; + default: goto yy1545; } -yy1541: +yy1547: yych = *++c; switch (yych) { - case ' ': goto yy1545; - case '-': goto yy1543; - case '=': goto yy1544; - case 0xC2: goto yy1546; - default: goto yy1521; + case ' ': goto yy1551; + case '-': goto yy1549; + case '=': goto yy1550; + case 0xC2: goto yy1552; + default: goto yy1527; } -yy1542: +yy1548: yych = *++c; switch (yych) { - case 0xA0: goto yy1541; - default: goto yy1521; + case 0xA0: goto yy1547; + default: goto yy1527; } -yy1543: +yy1549: yych = *++c; switch (yych) { - case '-': goto yy1531; - default: goto yy1521; + case '-': goto yy1537; + default: goto yy1527; } -yy1544: +yy1550: yych = *++c; switch (yych) { - case '=': goto yy1536; - default: goto yy1521; + case '=': goto yy1542; + default: goto yy1527; } -yy1545: +yy1551: yych = *++c; switch (yych) { - case '-': goto yy1543; - case '=': goto yy1544; - default: goto yy1521; + case '-': goto yy1549; + case '=': goto yy1550; + default: goto yy1527; } -yy1546: +yy1552: ++c; switch ((yych = *c)) { - case 0xA0: goto yy1545; - default: goto yy1521; + case 0xA0: goto yy1551; + default: goto yy1527; } } @@ -75561,8 +75593,8 @@ size_t scan_atx(const char * c) { case '|': case '}': case '~': - case 0x7F: goto yy1551; - case '#': goto yy1550; + case 0x7F: goto yy1557; + case '#': goto yy1556; case 0xC2: case 0xC3: case 0xC4: @@ -75592,8 +75624,8 @@ size_t scan_atx(const char * c) { case 0xDC: case 0xDD: case 0xDE: - case 0xDF: goto yy1552; - case 0xE0: goto yy1554; + case 0xDF: goto yy1558; + case 0xE0: goto yy1560; case 0xE1: case 0xE2: case 0xE3: @@ -75608,29 +75640,29 @@ size_t scan_atx(const char * c) { case 0xEC: case 0xED: case 0xEE: - case 0xEF: goto yy1555; - case 0xF0: goto yy1556; + case 0xEF: goto yy1561; + case 0xF0: goto yy1562; case 0xF1: case 0xF2: - case 0xF3: goto yy1557; - case 0xF4: goto yy1558; - default: goto yy1549; + case 0xF3: goto yy1563; + case 0xF4: goto yy1564; + default: goto yy1555; } -yy1549: +yy1555: { return 0; } -yy1550: +yy1556: yych = *(marker = ++c); switch (yych) { case '\t': - case ' ': goto yy1559; - case '#': goto yy1562; - case 0xC2: goto yy1561; - default: goto yy1549; + case ' ': goto yy1565; + case '#': goto yy1568; + case 0xC2: goto yy1567; + default: goto yy1555; } -yy1551: +yy1557: yych = *++c; - goto yy1549; -yy1552: + goto yy1555; +yy1558: yych = *++c; switch (yych) { case 0x80: @@ -75696,13 +75728,13 @@ yy1552: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1551; - default: goto yy1553; + case 0xBF: goto yy1557; + default: goto yy1559; } -yy1553: +yy1559: c = marker; - goto yy1549; -yy1554: + goto yy1555; +yy1560: yych = *++c; switch (yych) { case 0xA0: @@ -75736,10 +75768,10 @@ yy1554: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1552; - default: goto yy1553; + case 0xBF: goto yy1558; + default: goto yy1559; } -yy1555: +yy1561: yych = *++c; switch (yych) { case 0x80: @@ -75805,10 +75837,10 @@ yy1555: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1552; - default: goto yy1553; + case 0xBF: goto yy1558; + default: goto yy1559; } -yy1556: +yy1562: yych = *++c; switch (yych) { case 0x90: @@ -75858,10 +75890,10 @@ yy1556: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1555; - default: goto yy1553; + case 0xBF: goto yy1561; + default: goto yy1559; } -yy1557: +yy1563: yych = *++c; switch (yych) { case 0x80: @@ -75927,10 +75959,10 @@ yy1557: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1555; - default: goto yy1553; + case 0xBF: goto yy1561; + default: goto yy1559; } -yy1558: +yy1564: yych = *++c; switch (yych) { case 0x80: @@ -75948,10 +75980,10 @@ yy1558: case 0x8C: case 0x8D: case 0x8E: - case 0x8F: goto yy1555; - default: goto yy1553; + case 0x8F: goto yy1561; + default: goto yy1559; } -yy1559: +yy1565: ++c; yych = *c; switch (yych) { @@ -76077,10 +76109,10 @@ yy1559: case '|': case '}': case '~': - case 0x7F: goto yy1564; + case 0x7F: goto yy1570; case '\t': - case ' ': goto yy1559; - case 0xC2: goto yy1566; + case ' ': goto yy1565; + case 0xC2: goto yy1572; case 0xC3: case 0xC4: case 0xC5: @@ -76109,8 +76141,8 @@ yy1559: case 0xDC: case 0xDD: case 0xDE: - case 0xDF: goto yy1567; - case 0xE0: goto yy1568; + case 0xDF: goto yy1573; + case 0xE0: goto yy1574; case 0xE1: case 0xE2: case 0xE3: @@ -76125,34 +76157,34 @@ yy1559: case 0xEC: case 0xED: case 0xEE: - case 0xEF: goto yy1569; - case 0xF0: goto yy1570; + case 0xEF: goto yy1575; + case 0xF0: goto yy1576; case 0xF1: case 0xF2: - case 0xF3: goto yy1571; - case 0xF4: goto yy1572; - default: goto yy1553; + case 0xF3: goto yy1577; + case 0xF4: goto yy1578; + default: goto yy1559; } -yy1561: +yy1567: yych = *++c; switch (yych) { - case 0xA0: goto yy1559; - default: goto yy1553; + case 0xA0: goto yy1565; + default: goto yy1559; } -yy1562: +yy1568: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy1559; - case '#': goto yy1562; - case 0xC2: goto yy1561; - default: goto yy1553; + case ' ': goto yy1565; + case '#': goto yy1568; + case 0xC2: goto yy1567; + default: goto yy1559; } -yy1564: +yy1570: ++c; { return (size_t)( c - start ); } -yy1566: +yy1572: ++c; yych = *c; switch (yych) { @@ -76218,11 +76250,11 @@ yy1566: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1564; - case 0xA0: goto yy1559; - default: goto yy1553; + case 0xBF: goto yy1570; + case 0xA0: goto yy1565; + default: goto yy1559; } -yy1567: +yy1573: yych = *++c; switch (yych) { case 0x80: @@ -76288,10 +76320,10 @@ yy1567: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1564; - default: goto yy1553; + case 0xBF: goto yy1570; + default: goto yy1559; } -yy1568: +yy1574: yych = *++c; switch (yych) { case 0xA0: @@ -76325,10 +76357,10 @@ yy1568: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1567; - default: goto yy1553; + case 0xBF: goto yy1573; + default: goto yy1559; } -yy1569: +yy1575: yych = *++c; switch (yych) { case 0x80: @@ -76394,10 +76426,10 @@ yy1569: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1567; - default: goto yy1553; + case 0xBF: goto yy1573; + default: goto yy1559; } -yy1570: +yy1576: yych = *++c; switch (yych) { case 0x90: @@ -76447,10 +76479,10 @@ yy1570: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1569; - default: goto yy1553; + case 0xBF: goto yy1575; + default: goto yy1559; } -yy1571: +yy1577: yych = *++c; switch (yych) { case 0x80: @@ -76516,10 +76548,10 @@ yy1571: case 0xBC: case 0xBD: case 0xBE: - case 0xBF: goto yy1569; - default: goto yy1553; + case 0xBF: goto yy1575; + default: goto yy1559; } -yy1572: +yy1578: ++c; switch ((yych = *c)) { case 0x80: @@ -76537,8 +76569,8 @@ yy1572: case 0x8C: case 0x8D: case 0x8E: - case 0x8F: goto yy1569; - default: goto yy1553; + case 0x8F: goto yy1575; + default: goto yy1559; } } diff --git a/Sources/libMultiMarkdown/scanners.re b/Sources/libMultiMarkdown/scanners.re index 8dd3d61..38990f5 100644 --- a/Sources/libMultiMarkdown/scanners.re +++ b/Sources/libMultiMarkdown/scanners.re @@ -152,6 +152,7 @@ align_left = sp ':' align sp ('|' | nl_eof); align_right = sp align ':' sp ('|' | nl_eof); align_center = sp ':' align ':' sp ('|' | nl_eof); + align_wrap = sp align '+' sp ('|' | nl_eof); align_wrap_left = sp ':' align '+' sp ('|' | nl_eof); align_wrap_right = sp align ':' '+' sp ('|' | nl_eof); align_wrap_center = sp ':' align ':' '+' sp ('|' | nl_eof); @@ -422,6 +423,7 @@ size_t scan_alignment_string(const char * c) { const char * marker = NULL; /*!re2c + align_wrap { return ALIGN_WRAP; } align_left { return ALIGN_LEFT; } align_right { return ALIGN_RIGHT; } align_center { return ALIGN_CENTER; } diff --git a/Sources/libMultiMarkdown/writer.c b/Sources/libMultiMarkdown/writer.c index 914bbe0..87ce197 100644 --- a/Sources/libMultiMarkdown/writer.c +++ b/Sources/libMultiMarkdown/writer.c @@ -2294,7 +2294,7 @@ void read_table_column_alignments(const char * source, token * table, scratch_pa scratch->table_alignment[counter] = 'C'; break; case ALIGN_WRAP: - scratch->table_alignment[counter] = 'C'; + scratch->table_alignment[counter] = 'N'; break; default: scratch->table_alignment[counter] = 'n'; diff --git a/tests/MMD6Tests/Tables.html b/tests/MMD6Tests/Tables.html index a9cc489..0606dd7 100644 --- a/tests/MMD6Tests/Tables.html +++ b/tests/MMD6Tests/Tables.html @@ -8,8 +8,8 @@ --++ @@ -33,7 +33,7 @@
-+ diff --git a/tests/MMD6Tests/Tables.htmlc b/tests/MMD6Tests/Tables.htmlc index 1b1bdfe..7e55634 100644 --- a/tests/MMD6Tests/Tables.htmlc +++ b/tests/MMD6Tests/Tables.htmlc @@ -2,12 +2,12 @@ latex config: article

| foo | bar |
-| ------ | :------: |
+| ------+ | :------:+ |
| foo | bar |
| foo bar ||

| foo1 | bar1 | -| :---+ | ----: | +| :---+ | ----:+ | foo | bar | | foo bar ||

diff --git a/tests/MMD6Tests/Tables.tex b/tests/MMD6Tests/Tables.tex index 4af980e..d039c35 100644 --- a/tests/MMD6Tests/Tables.tex +++ b/tests/MMD6Tests/Tables.tex @@ -7,7 +7,7 @@ \setlength{\tymax}{0.5\linewidth} \centering \small -\begin{tabulary}{\textwidth}{@{}lc@{}} \toprule +\begin{tabulary}{\textwidth}{@{}LC@{}} \toprule foo & bar \\ \midrule @@ -24,7 +24,7 @@ \setlength{\tymax}{0.5\linewidth} \centering \small -\begin{tabulary}{\textwidth}{@{}Lr@{}} \toprule +\begin{tabulary}{\textwidth}{@{}LR@{}} \toprule foo1 & bar1 \\ \midrule diff --git a/tests/MMD6Tests/Tables.text b/tests/MMD6Tests/Tables.text index 5141c2d..096fea8 100644 --- a/tests/MMD6Tests/Tables.text +++ b/tests/MMD6Tests/Tables.text @@ -2,13 +2,13 @@ Title: Tables latex config: article | foo | bar | -| ------ | :------: | +| ------+ | :------:+ | | *foo* | *bar* | | **foo bar** || | foo1 | bar1 | -| :---+ | ----: | +| :---+ | ----:+ | *foo* | *bar* | | **foo bar** ||