rmultimarkdown 6.2.2.1 → 6.4.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/ext/Makefile +2 -2
- data/ext/mmd/aho-corasick.c +12 -8
- data/ext/mmd/beamer.c +29 -0
- data/ext/mmd/critic_markup.c +100 -4
- data/ext/mmd/critic_markup.h +7 -0
- data/ext/mmd/d_string.c +502 -119
- data/ext/mmd/epub.c +2 -4
- data/ext/mmd/file.c +436 -0
- data/ext/mmd/file.h +153 -0
- data/ext/mmd/html.c +130 -37
- data/ext/mmd/include/d_string.h +20 -19
- data/ext/mmd/include/libMultiMarkdown.h +42 -27
- data/ext/mmd/include/token.h +15 -15
- data/ext/mmd/latex.c +107 -30
- data/ext/mmd/lexer.c +19 -7
- data/ext/mmd/lexer.h +2 -2
- data/ext/mmd/memoir.c +29 -0
- data/ext/mmd/mmd.c +65 -39
- data/ext/mmd/object_pool.h +4 -4
- data/ext/mmd/opendocument-content.c +95 -13
- data/ext/mmd/opendocument.c +315 -313
- data/ext/mmd/opml-lexer.c +2183 -0
- data/ext/mmd/opml-lexer.h +157 -0
- data/ext/mmd/opml-parser.c +1193 -0
- data/ext/mmd/opml-parser.h +15 -0
- data/ext/mmd/opml-reader.c +435 -0
- data/ext/mmd/opml-reader.h +111 -0
- data/ext/mmd/opml.c +511 -0
- data/ext/mmd/opml.h +115 -0
- data/ext/mmd/parser.c +2 -0
- data/ext/mmd/rng.c +1 -1
- data/ext/mmd/scanners.c +51663 -24824
- data/ext/mmd/stack.c +4 -2
- data/ext/mmd/stack.h +8 -8
- data/ext/mmd/textbundle.c +2 -4
- data/ext/mmd/token.c +24 -12
- data/ext/mmd/token_pairs.c +2 -2
- data/ext/mmd/token_pairs.h +10 -10
- data/ext/mmd/transclude.c +1 -226
- data/ext/mmd/transclude.h +0 -8
- data/ext/mmd/uuid.c +3 -3
- data/ext/mmd/version.h +3 -3
- data/ext/mmd/writer.c +99 -30
- data/ext/mmd/writer.h +11 -0
- data/lib/multi_markdown.bundle +0 -0
- data/lib/multi_markdown/version.rb +1 -1
- metadata +13 -5
- data/ext/mmd/fodt.c +0 -2288
- data/ext/mmd/fodt.h +0 -81
data/ext/mmd/object_pool.h
CHANGED
@@ -76,25 +76,25 @@ typedef struct pool pool;
|
|
76
76
|
|
77
77
|
/// Allocate a new object pool
|
78
78
|
pool * pool_new(
|
79
|
-
|
79
|
+
short size //!< How big are the objects to be allocated
|
80
80
|
);
|
81
81
|
|
82
82
|
|
83
83
|
/// Free object pool
|
84
84
|
void pool_free(
|
85
|
-
|
85
|
+
pool * p //!< Pool to be freed
|
86
86
|
);
|
87
87
|
|
88
88
|
|
89
89
|
/// Drain pool -- free slabs previously allocated
|
90
90
|
void pool_drain(
|
91
|
-
|
91
|
+
pool * p //!< Pool to be drained
|
92
92
|
);
|
93
93
|
|
94
94
|
|
95
95
|
/// Request memory for a new object from the pool
|
96
96
|
void * pool_allocate_object(
|
97
|
-
|
97
|
+
pool * p //!< Pool to be used for allocation
|
98
98
|
);
|
99
99
|
|
100
100
|
|
@@ -154,6 +154,11 @@ void mmd_print_char_opendocument(DString * out, char c) {
|
|
154
154
|
print_const(">");
|
155
155
|
break;
|
156
156
|
|
157
|
+
case '\n':
|
158
|
+
case '\r':
|
159
|
+
print_const("<text:line-break/>\n");
|
160
|
+
break;
|
161
|
+
|
157
162
|
case '\t':
|
158
163
|
print_const("<text:tab/>");
|
159
164
|
|
@@ -246,6 +251,7 @@ void mmd_print_localized_char_opendocument(DString * out, unsigned short type, s
|
|
246
251
|
break;
|
247
252
|
|
248
253
|
case FRENCH:
|
254
|
+
case SPANISH:
|
249
255
|
print_const("«");
|
250
256
|
break;
|
251
257
|
|
@@ -270,6 +276,7 @@ void mmd_print_localized_char_opendocument(DString * out, unsigned short type, s
|
|
270
276
|
break;
|
271
277
|
|
272
278
|
case FRENCH:
|
279
|
+
case SPANISH:
|
273
280
|
print_const("»");
|
274
281
|
break;
|
275
282
|
|
@@ -289,6 +296,8 @@ void mmd_export_token_opendocument_raw(DString * out, const char * source, token
|
|
289
296
|
return;
|
290
297
|
}
|
291
298
|
|
299
|
+
char * temp;
|
300
|
+
|
292
301
|
switch (t->type) {
|
293
302
|
case AMPERSAND:
|
294
303
|
print_const("&");
|
@@ -308,7 +317,20 @@ void mmd_export_token_opendocument_raw(DString * out, const char * source, token
|
|
308
317
|
|
309
318
|
case ESCAPED_CHARACTER:
|
310
319
|
print_const("\\");
|
311
|
-
|
320
|
+
|
321
|
+
if (t->next && t->next->type == TEXT_EMPTY && source[t->start + 1] == ' ') {
|
322
|
+
} else {
|
323
|
+
mmd_print_char_opendocument(out, source[t->start + 1]);
|
324
|
+
}
|
325
|
+
|
326
|
+
break;
|
327
|
+
|
328
|
+
case HTML_COMMENT_START:
|
329
|
+
print_const("<!--");
|
330
|
+
break;
|
331
|
+
|
332
|
+
case HTML_COMMENT_STOP:
|
333
|
+
print_const("-->");
|
312
334
|
break;
|
313
335
|
|
314
336
|
case HTML_ENTITY:
|
@@ -324,6 +346,60 @@ void mmd_export_token_opendocument_raw(DString * out, const char * source, token
|
|
324
346
|
print_const(""");
|
325
347
|
break;
|
326
348
|
|
349
|
+
case MARKER_H1:
|
350
|
+
case MARKER_H2:
|
351
|
+
case MARKER_H3:
|
352
|
+
case MARKER_H4:
|
353
|
+
case MARKER_H5:
|
354
|
+
case MARKER_H6:
|
355
|
+
temp = (char *) &source[t->start];
|
356
|
+
|
357
|
+
while (temp) {
|
358
|
+
switch (*temp) {
|
359
|
+
case '#':
|
360
|
+
print_const("#");
|
361
|
+
temp++;
|
362
|
+
break;
|
363
|
+
|
364
|
+
case ' ':
|
365
|
+
print_const(" ");
|
366
|
+
temp++;
|
367
|
+
break;
|
368
|
+
|
369
|
+
case '\t':
|
370
|
+
print_const("<text:tab/>");
|
371
|
+
temp++;
|
372
|
+
break;
|
373
|
+
|
374
|
+
default:
|
375
|
+
temp = NULL;
|
376
|
+
break;
|
377
|
+
}
|
378
|
+
}
|
379
|
+
|
380
|
+
break;
|
381
|
+
|
382
|
+
case MARKER_LIST_BULLET:
|
383
|
+
case MARKER_LIST_ENUMERATOR:
|
384
|
+
print_token(t);
|
385
|
+
|
386
|
+
temp = NULL;
|
387
|
+
|
388
|
+
if (t->next) {
|
389
|
+
temp = (char *) &source[t->next->start];
|
390
|
+
}
|
391
|
+
|
392
|
+
source = (char *) &source[t->start + t->len];
|
393
|
+
|
394
|
+
while (char_is_whitespace(*source) &&
|
395
|
+
((temp == NULL) ||
|
396
|
+
(source < temp))) {
|
397
|
+
print_char(*source);
|
398
|
+
source++;
|
399
|
+
}
|
400
|
+
|
401
|
+
break;
|
402
|
+
|
327
403
|
case MATH_BRACKET_OPEN:
|
328
404
|
case MATH_BRACKET_CLOSE:
|
329
405
|
case MATH_PAREN_OPEN:
|
@@ -359,6 +435,9 @@ void mmd_export_token_opendocument_raw(DString * out, const char * source, token
|
|
359
435
|
case TEXT_EMPTY:
|
360
436
|
break;
|
361
437
|
|
438
|
+
case TEXT_LINEBREAK:
|
439
|
+
print_const(" ");
|
440
|
+
|
362
441
|
case TEXT_NL:
|
363
442
|
print_const("<text:line-break/>");
|
364
443
|
break;
|
@@ -452,7 +531,7 @@ void mmd_export_link_opendocument(DString * out, const char * source, token * te
|
|
452
531
|
text->child->next->len++;
|
453
532
|
}
|
454
533
|
|
455
|
-
if (text) {
|
534
|
+
if (text && text->child) {
|
456
535
|
mmd_export_token_tree_opendocument(out, source, text->child, scratch);
|
457
536
|
}
|
458
537
|
|
@@ -810,6 +889,8 @@ void mmd_export_token_opendocument(DString * out, const char * source, token * t
|
|
810
889
|
free(temp_char);
|
811
890
|
}
|
812
891
|
|
892
|
+
trim_trailing_whitespace_d_string(out);
|
893
|
+
|
813
894
|
print_const("</text:h>");
|
814
895
|
scratch->padded = 0;
|
815
896
|
break;
|
@@ -976,7 +1057,7 @@ void mmd_export_token_opendocument(DString * out, const char * source, token * t
|
|
976
1057
|
temp_token = t->next->child;
|
977
1058
|
|
978
1059
|
if (temp_token->next &&
|
979
|
-
|
1060
|
+
temp_token->next->type == PAIR_BRACKET) {
|
980
1061
|
temp_token = temp_token->next;
|
981
1062
|
}
|
982
1063
|
|
@@ -1148,7 +1229,7 @@ void mmd_export_token_opendocument(DString * out, const char * source, token * t
|
|
1148
1229
|
|
1149
1230
|
case ESCAPED_CHARACTER:
|
1150
1231
|
if (!(scratch->extensions & EXT_COMPATIBILITY) &&
|
1151
|
-
|
1232
|
+
(source[t->start + 1] == ' ')) {
|
1152
1233
|
print_const(" "); // This is a non-breaking space character
|
1153
1234
|
} else {
|
1154
1235
|
mmd_print_char_opendocument(out, source[t->start + 1]);
|
@@ -1370,7 +1451,7 @@ void mmd_export_token_opendocument(DString * out, const char * source, token * t
|
|
1370
1451
|
|
1371
1452
|
case PAIR_BRACKET:
|
1372
1453
|
if ((scratch->extensions & EXT_NOTES) &&
|
1373
|
-
|
1454
|
+
(t->next && t->next->type == PAIR_BRACKET_CITATION)) {
|
1374
1455
|
goto parse_citation;
|
1375
1456
|
}
|
1376
1457
|
|
@@ -1386,8 +1467,8 @@ void mmd_export_token_opendocument(DString * out, const char * source, token * t
|
|
1386
1467
|
temp_token = t->next;
|
1387
1468
|
|
1388
1469
|
if (temp_token &&
|
1389
|
-
|
1390
|
-
|
1470
|
+
((temp_token->type == PAIR_BRACKET) ||
|
1471
|
+
(temp_token->type == PAIR_PAREN))) {
|
1391
1472
|
temp_token = temp_token->next;
|
1392
1473
|
}
|
1393
1474
|
|
@@ -1754,7 +1835,7 @@ parse_citation:
|
|
1754
1835
|
|
1755
1836
|
// Ignore if we're rejecting or accepting
|
1756
1837
|
if ((scratch->extensions & EXT_CRITIC_REJECT) ||
|
1757
|
-
|
1838
|
+
(scratch->extensions & EXT_CRITIC_ACCEPT)) {
|
1758
1839
|
break;
|
1759
1840
|
}
|
1760
1841
|
|
@@ -1774,7 +1855,7 @@ parse_citation:
|
|
1774
1855
|
|
1775
1856
|
// Ignore if we're rejecting or accepting
|
1776
1857
|
if ((scratch->extensions & EXT_CRITIC_REJECT) ||
|
1777
|
-
|
1858
|
+
(scratch->extensions & EXT_CRITIC_ACCEPT)) {
|
1778
1859
|
t->child->type = TEXT_EMPTY;
|
1779
1860
|
t->child->mate->type = TEXT_EMPTY;
|
1780
1861
|
mmd_export_token_tree_opendocument(out, source, t->child, scratch);
|
@@ -1803,8 +1884,8 @@ parse_citation:
|
|
1803
1884
|
|
1804
1885
|
case PAIR_CRITIC_SUB_DEL:
|
1805
1886
|
if ((scratch->extensions & EXT_CRITIC) &&
|
1806
|
-
|
1807
|
-
|
1887
|
+
(t->next) &&
|
1888
|
+
(t->next->type == PAIR_CRITIC_SUB_ADD)) {
|
1808
1889
|
t->child->type = TEXT_EMPTY;
|
1809
1890
|
t->child->mate->type = TEXT_EMPTY;
|
1810
1891
|
|
@@ -1825,8 +1906,8 @@ parse_citation:
|
|
1825
1906
|
|
1826
1907
|
case PAIR_CRITIC_SUB_ADD:
|
1827
1908
|
if ((scratch->extensions & EXT_CRITIC) &&
|
1828
|
-
|
1829
|
-
|
1909
|
+
(t->prev) &&
|
1910
|
+
(t->prev->type == PAIR_CRITIC_SUB_DEL)) {
|
1830
1911
|
t->child->type = TEXT_EMPTY;
|
1831
1912
|
t->child->mate->type = TEXT_EMPTY;
|
1832
1913
|
|
@@ -2025,6 +2106,7 @@ parse_citation:
|
|
2025
2106
|
|
2026
2107
|
break;
|
2027
2108
|
|
2109
|
+
case PAIR_RAW_FILTER:
|
2028
2110
|
case RAW_FILTER_LEFT:
|
2029
2111
|
case TEXT_BACKSLASH:
|
2030
2112
|
case TEXT_BRACE_LEFT:
|
data/ext/mmd/opendocument.c
CHANGED
@@ -105,6 +105,7 @@
|
|
105
105
|
#include <curl/curl.h>
|
106
106
|
#endif
|
107
107
|
|
108
|
+
#include "file.h"
|
108
109
|
#include "miniz.h"
|
109
110
|
#include "opendocument.h"
|
110
111
|
#include "opendocument-content.h"
|
@@ -188,12 +189,15 @@ char * opendocument_metadata(mmd_engine * e, scratch_pad * scratch) {
|
|
188
189
|
} else if (strcmp(m->key, "latexbegin") == 0) {
|
189
190
|
} else if (strcmp(m->key, "latexconfig") == 0) {
|
190
191
|
} else if (strcmp(m->key, "latexfooter") == 0) {
|
192
|
+
} else if (strcmp(m->key, "latexheader") == 0) {
|
191
193
|
} else if (strcmp(m->key, "latexheaderlevel") == 0) {
|
192
194
|
} else if (strcmp(m->key, "latexinput") == 0) {
|
193
195
|
} else if (strcmp(m->key, "latexleader") == 0) {
|
194
196
|
} else if (strcmp(m->key, "latexmode") == 0) {
|
195
197
|
} else if (strcmp(m->key, "mmdfooter") == 0) {
|
196
198
|
} else if (strcmp(m->key, "mmdheader") == 0) {
|
199
|
+
} else if (strcmp(m->key, "odfheader") == 0) {
|
200
|
+
mmd_print_string_opendocument(out, m->value);
|
197
201
|
} else if (strcmp(m->key, "quoteslanguage") == 0) {
|
198
202
|
} else if (strcmp(m->key, "title") == 0) {
|
199
203
|
print_const("\t<dc:title>");
|
@@ -249,253 +253,253 @@ char * opendocument_style(int format) {
|
|
249
253
|
|
250
254
|
/* Font Declarations */
|
251
255
|
print_const("<office:font-face-decls>\n" \
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
|
256
|
-
|
256
|
+
" <style:font-face style:name=\"Courier New\" svg:font-family=\"'Courier New'\"\n" \
|
257
|
+
" style:font-adornments=\"Regular\"\n" \
|
258
|
+
" style:font-family-generic=\"modern\"\n" \
|
259
|
+
" style:font-pitch=\"fixed\"/>\n" \
|
260
|
+
"</office:font-face-decls>\n");
|
257
261
|
|
258
262
|
/* Append basic style information */
|
259
263
|
print_const("<office:styles>\n" \
|
260
|
-
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
|
270
|
-
|
271
|
-
|
272
|
-
|
273
|
-
|
274
|
-
|
275
|
-
|
276
|
-
|
277
|
-
|
278
|
-
|
279
|
-
|
280
|
-
|
281
|
-
|
282
|
-
|
283
|
-
|
284
|
-
|
285
|
-
|
286
|
-
|
287
|
-
|
288
|
-
|
289
|
-
|
290
|
-
|
291
|
-
|
292
|
-
|
293
|
-
|
294
|
-
|
295
|
-
|
296
|
-
|
297
|
-
|
298
|
-
|
299
|
-
|
300
|
-
|
301
|
-
|
302
|
-
|
303
|
-
|
304
|
-
|
305
|
-
|
306
|
-
|
307
|
-
|
308
|
-
|
309
|
-
|
310
|
-
|
311
|
-
|
312
|
-
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
|
317
|
-
|
318
|
-
|
319
|
-
|
320
|
-
|
321
|
-
|
322
|
-
|
323
|
-
|
324
|
-
|
325
|
-
|
326
|
-
|
327
|
-
|
328
|
-
|
329
|
-
|
330
|
-
|
331
|
-
|
332
|
-
|
333
|
-
|
334
|
-
|
335
|
-
|
336
|
-
|
337
|
-
|
264
|
+
"<style:style style:name=\"Standard\" style:family=\"paragraph\" style:class=\"text\">\n" \
|
265
|
+
" <style:paragraph-properties fo:margin-top=\"0in\" fo:margin-bottom=\"0.15in\"" \
|
266
|
+
" fo:text-align=\"justify\" style:justify-single-word=\"false\"/>\n" \
|
267
|
+
" </style:style>\n" \
|
268
|
+
"<style:style style:name=\"Preformatted_20_Text\" style:display-name=\"Preformatted Text\"\n" \
|
269
|
+
" style:family=\"paragraph\"\n" \
|
270
|
+
" style:parent-style-name=\"Standard\"\n" \
|
271
|
+
" style:class=\"html\">\n" \
|
272
|
+
" <style:paragraph-properties fo:margin-top=\"0in\" fo:margin-bottom=\"0in\" fo:text-align=\"start\"\n" \
|
273
|
+
" style:justify-single-word=\"false\"/>\n" \
|
274
|
+
" <style:text-properties style:font-name=\"Courier New\" fo:font-size=\"11pt\"\n" \
|
275
|
+
" style:font-name-asian=\"Courier New\"\n" \
|
276
|
+
" style:font-size-asian=\"11pt\"\n" \
|
277
|
+
" style:font-name-complex=\"Courier New\"\n" \
|
278
|
+
" style:font-size-complex=\"11pt\"/>\n" \
|
279
|
+
"</style:style>\n" \
|
280
|
+
"<style:style style:name=\"Source_20_Text\" style:display-name=\"Source Text\"\n" \
|
281
|
+
" style:family=\"text\">\n" \
|
282
|
+
" <style:text-properties style:font-name=\"Courier New\" style:font-name-asian=\"Courier New\"\n" \
|
283
|
+
" style:font-name-complex=\"Courier New\"\n" \
|
284
|
+
" fo:font-size=\"11pt\"/>\n" \
|
285
|
+
"</style:style>\n" \
|
286
|
+
"<style:style style:name=\"List\" style:family=\"paragraph\"\n" \
|
287
|
+
" style:parent-style-name=\"Standard\"\n" \
|
288
|
+
" style:class=\"list\">\n" \
|
289
|
+
" <style:paragraph-properties fo:text-align=\"start\" style:justify-single-word=\"false\"/>\n" \
|
290
|
+
" <style:text-properties style:font-size-asian=\"12pt\"/>\n" \
|
291
|
+
"</style:style>\n" \
|
292
|
+
"<style:style style:name=\"Quotations\" style:family=\"paragraph\"\n" \
|
293
|
+
" style:parent-style-name=\"Standard\"\n" \
|
294
|
+
" style:class=\"html\">\n" \
|
295
|
+
" <style:paragraph-properties fo:margin-left=\"0.3937in\" fo:margin-right=\"0.3937in\" fo:margin-top=\"0in\"\n" \
|
296
|
+
" fo:margin-bottom=\"0.1965in\"\n" \
|
297
|
+
" fo:text-align=\"justify\"" \
|
298
|
+
" style:justify-single-word=\"false\"" \
|
299
|
+
" fo:text-indent=\"0in\"\n" \
|
300
|
+
" style:auto-text-indent=\"false\"/>\n" \
|
301
|
+
"</style:style>\n" \
|
302
|
+
"<style:style style:name=\"Table_20_Heading\" style:display-name=\"Table Heading\"\n" \
|
303
|
+
" style:family=\"paragraph\"\n" \
|
304
|
+
" style:parent-style-name=\"Table_20_Contents\"\n" \
|
305
|
+
" style:class=\"extra\">\n" \
|
306
|
+
" <style:paragraph-properties fo:text-align=\"center\" style:justify-single-word=\"false\"\n" \
|
307
|
+
" text:number-lines=\"false\"\n" \
|
308
|
+
" text:line-number=\"0\"/>\n" \
|
309
|
+
" <style:text-properties fo:font-weight=\"bold\" style:font-weight-asian=\"bold\"\n" \
|
310
|
+
" style:font-weight-complex=\"bold\"/>\n" \
|
311
|
+
"</style:style>\n" \
|
312
|
+
"<style:style style:name=\"Horizontal_20_Line\" style:display-name=\"Horizontal Line\"\n" \
|
313
|
+
" style:family=\"paragraph\"\n" \
|
314
|
+
" style:parent-style-name=\"Standard\"\n" \
|
315
|
+
" style:class=\"html\">\n" \
|
316
|
+
" <style:paragraph-properties fo:margin-top=\"0in\" fo:margin-bottom=\"0.1965in\"\n" \
|
317
|
+
" style:border-line-width-bottom=\"0.0008in 0.0138in 0.0008in\"\n" \
|
318
|
+
" fo:padding=\"0in\"\n" \
|
319
|
+
" fo:border-left=\"none\"\n" \
|
320
|
+
" fo:border-right=\"none\"\n" \
|
321
|
+
" fo:border-top=\"none\"\n" \
|
322
|
+
" fo:border-bottom=\"0.0154in double #808080\"\n" \
|
323
|
+
" text:number-lines=\"false\"\n" \
|
324
|
+
" text:line-number=\"0\"\n" \
|
325
|
+
" style:join-border=\"false\"/>\n" \
|
326
|
+
" <style:text-properties fo:font-size=\"6pt\" style:font-size-asian=\"6pt\" style:font-size-complex=\"6pt\"/>\n" \
|
327
|
+
"</style:style>\n" \
|
328
|
+
"<style:style style:name=\"Footnote_20_anchor\" style:display-name=\"Footnote anchor\"" \
|
329
|
+
" style:family=\"text\">" \
|
330
|
+
" <style:text-properties style:text-position=\"super 58%\"/>" \
|
331
|
+
" </style:style>\n" \
|
332
|
+
"<style:style style:name=\"TOC_Item\" style:family=\"paragraph\" style:parent-style-name=\"Standard\">\n" \
|
333
|
+
" <style:paragraph-properties>\n" \
|
334
|
+
" <style:tab-stops>\n" \
|
335
|
+
" <style:tab-stop style:position=\"6.7283in\" style:type=\"right\" style:leader-style=\"dotted\" style:leader-text=\".\"/>\n" \
|
336
|
+
" </style:tab-stops>\n" \
|
337
|
+
" </style:paragraph-properties>\n" \
|
338
|
+
"</style:style>\n" \
|
339
|
+
" <text:notes-configuration text:note-class=\"footnote\" text:default-style-name=\"Footnote\" text:citation-style-name=\"Footnote_20_Symbol\" text:citation-body-style-name=\"Footnote_20_anchor\" text:master-page-name=\"Footnote\" style:num-format=\"a\" text:start-value=\"0\" text:footnotes-position=\"page\" text:start-numbering-at=\"page\"/>\n" \
|
340
|
+
" <text:notes-configuration text:note-class=\"endnote\" text:default-style-name=\"Endnote\" text:citation-style-name=\"Endnote_20_Symbol\" text:citation-body-style-name=\"Endnote_20_anchor\" text:master-page-name=\"Endnote\" style:num-format=\"1\" text:start-value=\"0\"/>\n" \
|
341
|
+
"</office:styles>\n");
|
338
342
|
|
339
343
|
/* Automatic style information */
|
340
344
|
print_const("<office:automatic-styles>" \
|
341
|
-
|
342
|
-
|
343
|
-
|
344
|
-
|
345
|
-
|
346
|
-
|
347
|
-
|
348
|
-
|
349
|
-
|
350
|
-
|
351
|
-
|
352
|
-
|
353
|
-
|
354
|
-
|
355
|
-
|
356
|
-
|
357
|
-
|
358
|
-
|
359
|
-
|
360
|
-
|
361
|
-
|
362
|
-
|
363
|
-
|
364
|
-
|
365
|
-
|
366
|
-
|
367
|
-
|
368
|
-
|
369
|
-
|
370
|
-
|
371
|
-
|
372
|
-
|
373
|
-
|
374
|
-
|
375
|
-
|
376
|
-
|
377
|
-
|
378
|
-
|
379
|
-
|
380
|
-
|
381
|
-
|
382
|
-
|
383
|
-
|
384
|
-
|
385
|
-
|
386
|
-
|
387
|
-
|
388
|
-
|
389
|
-
|
390
|
-
|
391
|
-
|
392
|
-
|
393
|
-
|
394
|
-
|
395
|
-
|
396
|
-
|
397
|
-
|
398
|
-
|
399
|
-
|
400
|
-
|
401
|
-
|
402
|
-
|
403
|
-
|
404
|
-
|
405
|
-
|
406
|
-
|
407
|
-
|
408
|
-
|
409
|
-
|
410
|
-
|
411
|
-
|
412
|
-
|
413
|
-
|
414
|
-
|
415
|
-
|
416
|
-
|
417
|
-
|
418
|
-
|
419
|
-
|
420
|
-
|
421
|
-
|
422
|
-
|
423
|
-
|
424
|
-
|
425
|
-
|
426
|
-
|
427
|
-
|
428
|
-
|
429
|
-
|
430
|
-
|
431
|
-
|
432
|
-
|
433
|
-
|
434
|
-
|
435
|
-
|
436
|
-
|
437
|
-
|
438
|
-
|
439
|
-
|
440
|
-
|
441
|
-
|
442
|
-
|
443
|
-
|
444
|
-
|
445
|
-
|
446
|
-
|
447
|
-
|
448
|
-
|
449
|
-
|
450
|
-
|
451
|
-
|
452
|
-
|
453
|
-
|
454
|
-
|
455
|
-
|
456
|
-
|
457
|
-
|
458
|
-
|
459
|
-
|
460
|
-
|
461
|
-
|
462
|
-
|
463
|
-
|
464
|
-
|
465
|
-
|
466
|
-
|
467
|
-
|
468
|
-
|
469
|
-
|
470
|
-
|
471
|
-
|
472
|
-
|
473
|
-
|
474
|
-
|
475
|
-
|
476
|
-
|
477
|
-
|
478
|
-
|
479
|
-
|
480
|
-
|
481
|
-
|
482
|
-
|
483
|
-
|
484
|
-
|
485
|
-
|
486
|
-
|
487
|
-
|
488
|
-
|
489
|
-
|
490
|
-
|
491
|
-
|
492
|
-
|
493
|
-
|
494
|
-
|
495
|
-
|
496
|
-
|
497
|
-
|
498
|
-
|
345
|
+
" <style:style style:name=\"MMD-Italic\" style:family=\"text\">\n" \
|
346
|
+
" <style:text-properties fo:font-style=\"italic\" style:font-style-asian=\"italic\"\n" \
|
347
|
+
" style:font-style-complex=\"italic\"/>\n" \
|
348
|
+
" </style:style>\n" \
|
349
|
+
" <style:style style:name=\"MMD-Bold\" style:family=\"text\">\n" \
|
350
|
+
" <style:text-properties fo:font-weight=\"bold\" style:font-weight-asian=\"bold\"\n" \
|
351
|
+
" style:font-weight-complex=\"bold\"/>\n" \
|
352
|
+
" </style:style>\n" \
|
353
|
+
" <style:style style:name=\"MMD-Superscript\" style:family=\"text\">\n" \
|
354
|
+
" <style:text-properties style:text-position=\"super 58%\"/>\n" \
|
355
|
+
" </style:style>\n" \
|
356
|
+
" <style:style style:name=\"MMD-Subscript\" style:family=\"text\">\n" \
|
357
|
+
" <style:text-properties style:text-position=\"sub 58%\"/>\n" \
|
358
|
+
" </style:style>\n" \
|
359
|
+
" <style:style style:name=\"Strike\" style:family=\"text\">\n" \
|
360
|
+
" <style:text-properties style:text-line-through-style=\"solid\" />\n" \
|
361
|
+
" </style:style>\n" \
|
362
|
+
" <style:style style:name=\"Underline\" style:family=\"text\">\n" \
|
363
|
+
" <style:text-properties style:text-underline-style=\"solid\" style:text-underline-color=\"font-color\"/>\n" \
|
364
|
+
" </style:style>\n" \
|
365
|
+
" <style:style style:name=\"Highlight\" style:family=\"text\">\n" \
|
366
|
+
" <style:text-properties fo:background-color=\"#FFFF00\" />\n" \
|
367
|
+
" </style:style>\n" \
|
368
|
+
" <style:style style:name=\"Comment\" style:family=\"text\">\n" \
|
369
|
+
" <style:text-properties fo:color=\"#0000BB\" />\n" \
|
370
|
+
" </style:style>\n" \
|
371
|
+
"<style:style style:name=\"MMD-Table\" style:family=\"paragraph\" style:parent-style-name=\"Standard\">\n" \
|
372
|
+
" <style:paragraph-properties fo:margin-top=\"0in\" fo:margin-bottom=\"0.05in\"/>\n" \
|
373
|
+
"</style:style>\n" \
|
374
|
+
"<style:style style:name=\"MMD-Table-Center\" style:family=\"paragraph\" style:parent-style-name=\"MMD-Table\">\n" \
|
375
|
+
" <style:paragraph-properties fo:text-align=\"center\" style:justify-single-word=\"false\"/>\n" \
|
376
|
+
"</style:style>\n" \
|
377
|
+
"<style:style style:name=\"MMD-Table-Right\" style:family=\"paragraph\" style:parent-style-name=\"MMD-Table\">\n" \
|
378
|
+
" <style:paragraph-properties fo:text-align=\"right\" style:justify-single-word=\"false\"/>\n" \
|
379
|
+
"</style:style>\n" \
|
380
|
+
"<style:style style:name=\"P2\" style:family=\"paragraph\" style:parent-style-name=\"Standard\"\n" \
|
381
|
+
" style:list-style-name=\"L2\">\n" \
|
382
|
+
"<style:paragraph-properties fo:text-align=\"start\" style:justify-single-word=\"false\"/>\n" \
|
383
|
+
"</style:style>\n" \
|
384
|
+
"<style:style style:name=\"fr1\" style:family=\"graphic\" style:parent-style-name=\"Frame\">\n" \
|
385
|
+
" <style:graphic-properties style:print-content=\"true\" style:vertical-pos=\"top\"\n" \
|
386
|
+
" style:vertical-rel=\"baseline\"\n" \
|
387
|
+
" fo:padding=\"0in\"\n" \
|
388
|
+
" fo:border=\"none\"\n" \
|
389
|
+
" style:shadow=\"none\"/>\n" \
|
390
|
+
"</style:style>\n" \
|
391
|
+
"<style:style style:name=\"P1\" style:family=\"paragraph\" style:parent-style-name=\"Standard\"\n" \
|
392
|
+
" style:list-style-name=\"L1\"/>\n" \
|
393
|
+
"<text:list-style style:name=\"L1\">\n" \
|
394
|
+
" <text:list-level-style-bullet text:level=\"1\" text:style-name=\"Numbering_20_Symbols\" style:num-suffix=\".\" text:bullet-char=\"•\">\n" \
|
395
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
396
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"0.5in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"0.5in\"/>\n" \
|
397
|
+
" </style:list-level-properties>\n" \
|
398
|
+
" </text:list-level-style-bullet>\n" \
|
399
|
+
" <text:list-level-style-bullet text:level=\"2\" text:style-name=\"Numbering_20_Symbols\" style:num-suffix=\".\" text:bullet-char=\"◦\">\n" \
|
400
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
401
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"0.75in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"0.75in\"/>\n" \
|
402
|
+
" </style:list-level-properties>\n" \
|
403
|
+
" </text:list-level-style-bullet>\n" \
|
404
|
+
" <text:list-level-style-bullet text:level=\"3\" text:style-name=\"Numbering_20_Symbols\" style:num-suffix=\".\" text:bullet-char=\"▪\">\n" \
|
405
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
406
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"1in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"1in\"/>\n" \
|
407
|
+
" </style:list-level-properties>\n" \
|
408
|
+
" </text:list-level-style-bullet>\n" \
|
409
|
+
" <text:list-level-style-number text:level=\"4\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
410
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
411
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"1.25in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"1.25in\"/>\n" \
|
412
|
+
" </style:list-level-properties>\n" \
|
413
|
+
" </text:list-level-style-number>\n" \
|
414
|
+
" <text:list-level-style-number text:level=\"5\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
415
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
416
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"1.5in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"1.5in\"/>\n" \
|
417
|
+
" </style:list-level-properties>\n" \
|
418
|
+
" </text:list-level-style-number>\n" \
|
419
|
+
" <text:list-level-style-number text:level=\"6\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
420
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
421
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"1.75in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"1.75in\"/>\n" \
|
422
|
+
" </style:list-level-properties>\n" \
|
423
|
+
" </text:list-level-style-number>\n" \
|
424
|
+
" <text:list-level-style-number text:level=\"7\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
425
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
426
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"2in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"2in\"/>\n" \
|
427
|
+
" </style:list-level-properties>\n" \
|
428
|
+
" </text:list-level-style-number>\n" \
|
429
|
+
" <text:list-level-style-number text:level=\"8\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
430
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
431
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"2.25in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"2.25in\"/>\n" \
|
432
|
+
" </style:list-level-properties>\n" \
|
433
|
+
" </text:list-level-style-number>\n" \
|
434
|
+
" <text:list-level-style-number text:level=\"9\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
435
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
436
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"2.5in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"2.5in\"/>\n" \
|
437
|
+
" </style:list-level-properties>\n" \
|
438
|
+
" </text:list-level-style-number>\n" \
|
439
|
+
" <text:list-level-style-number text:level=\"10\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
440
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
441
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"2.75in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"2.75in\"/>\n" \
|
442
|
+
" </style:list-level-properties>\n" \
|
443
|
+
" </text:list-level-style-number>\n" \
|
444
|
+
"</text:list-style>\n" \
|
445
|
+
"<text:list-style style:name=\"L2\">\n" \
|
446
|
+
" <text:list-level-style-number text:level=\"1\" text:style-name=\"Standard\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
447
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
448
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"0.5in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"0.5in\"/>\n" \
|
449
|
+
" </style:list-level-properties>\n" \
|
450
|
+
" </text:list-level-style-number>\n" \
|
451
|
+
" <text:list-level-style-number text:level=\"2\" text:style-name=\"Standard\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
452
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
453
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"0.75in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"0.75in\"/>\n" \
|
454
|
+
" </style:list-level-properties>\n" \
|
455
|
+
" </text:list-level-style-number>\n" \
|
456
|
+
" <text:list-level-style-number text:level=\"3\" text:style-name=\"Standard\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
457
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
458
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"1in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"1in\"/>\n" \
|
459
|
+
" </style:list-level-properties>\n" \
|
460
|
+
" </text:list-level-style-number>\n" \
|
461
|
+
" <text:list-level-style-number text:level=\"4\" text:style-name=\"Standard\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
462
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
463
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"1.25in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"1.25in\"/>\n" \
|
464
|
+
" </style:list-level-properties>\n" \
|
465
|
+
" </text:list-level-style-number>\n" \
|
466
|
+
" <text:list-level-style-number text:level=\"5\" text:style-name=\"Standard\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
467
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
468
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"1.5in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"1.5in\"/>\n" \
|
469
|
+
" </style:list-level-properties>\n" \
|
470
|
+
" </text:list-level-style-number>\n" \
|
471
|
+
" <text:list-level-style-number text:level=\"6\" text:style-name=\"Standard\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
472
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
473
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"1.75in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"1.75in\"/>\n" \
|
474
|
+
" </style:list-level-properties>\n" \
|
475
|
+
" </text:list-level-style-number>\n" \
|
476
|
+
" <text:list-level-style-number text:level=\"7\" text:style-name=\"Standard\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
477
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
478
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"2in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"2in\"/>\n" \
|
479
|
+
" </style:list-level-properties>\n" \
|
480
|
+
" </text:list-level-style-number>\n" \
|
481
|
+
" <text:list-level-style-number text:level=\"8\" text:style-name=\"Standard\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
482
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
483
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"2.25in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"2.25in\"/>\n" \
|
484
|
+
" </style:list-level-properties>\n" \
|
485
|
+
" </text:list-level-style-number>\n" \
|
486
|
+
" <text:list-level-style-number text:level=\"9\" text:style-name=\"Standard\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
487
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
488
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"2.5in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"2.5in\"/>\n" \
|
489
|
+
" </style:list-level-properties>\n" \
|
490
|
+
" </text:list-level-style-number>\n" \
|
491
|
+
" <text:list-level-style-number text:level=\"10\" text:style-name=\"Standard\" style:num-suffix=\".\" style:num-format=\"1\">\n" \
|
492
|
+
" <style:list-level-properties text:list-level-position-and-space-mode=\"label-alignment\">\n" \
|
493
|
+
" <style:list-level-label-alignment text:label-followed-by=\"listtab\" text:list-tab-stop-position=\"2.75in\" fo:text-indent=\"-0.25in\" fo:margin-left=\"2.75in\"/>\n" \
|
494
|
+
" </style:list-level-properties>\n" \
|
495
|
+
" </text:list-level-style-number>\n" \
|
496
|
+
"</text:list-style>\n" \
|
497
|
+
"</office:automatic-styles>\n" \
|
498
|
+
" <office:master-styles>\n" \
|
499
|
+
" <style:master-page style:name=\"Endnote\" >\n" \
|
500
|
+
" <style:header><text:h text:outline-level=\"2\">Bibliography</text:h></style:header></style:master-page>\n" \
|
501
|
+
" <style:master-page style:name=\"Footnote\" style:page-layout-name=\"pm2\"/>\n" \
|
502
|
+
" </office:master-styles>\n");
|
499
503
|
|
500
504
|
char * result = out->str;
|
501
505
|
d_string_free(out, false);
|
@@ -513,41 +517,41 @@ char * opendocument_style_file(int format) {
|
|
513
517
|
d_string_append(out, "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n");
|
514
518
|
|
515
519
|
print_const("<office:document-styles xmlns:office=\"urn:oasis:names:tc:opendocument:xmlns:office:1.0\"\n" \
|
516
|
-
|
517
|
-
|
518
|
-
|
519
|
-
|
520
|
-
|
521
|
-
|
522
|
-
|
523
|
-
|
524
|
-
|
525
|
-
|
526
|
-
|
527
|
-
|
528
|
-
|
529
|
-
|
530
|
-
|
531
|
-
|
532
|
-
|
533
|
-
|
534
|
-
|
535
|
-
|
536
|
-
|
537
|
-
|
538
|
-
|
539
|
-
|
540
|
-
|
541
|
-
|
542
|
-
|
543
|
-
|
544
|
-
|
545
|
-
|
546
|
-
|
547
|
-
|
548
|
-
|
549
|
-
|
550
|
-
|
520
|
+
"xmlns:style=\"urn:oasis:names:tc:opendocument:xmlns:style:1.0\"\n" \
|
521
|
+
"xmlns:text=\"urn:oasis:names:tc:opendocument:xmlns:text:1.0\"\n" \
|
522
|
+
"xmlns:table=\"urn:oasis:names:tc:opendocument:xmlns:table:1.0\"\n" \
|
523
|
+
"xmlns:draw=\"urn:oasis:names:tc:opendocument:xmlns:drawing:1.0\"\n" \
|
524
|
+
"xmlns:fo=\"urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0\"\n" \
|
525
|
+
"xmlns:xlink=\"http://www.w3.org/1999/xlink\"\n" \
|
526
|
+
"xmlns:dc=\"http://purl.org/dc/elements/1.1/\"\n" \
|
527
|
+
"xmlns:meta=\"urn:oasis:names:tc:opendocument:xmlns:meta:1.0\"\n" \
|
528
|
+
"xmlns:number=\"urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0\"\n" \
|
529
|
+
"xmlns:svg=\"urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0\"\n" \
|
530
|
+
"xmlns:chart=\"urn:oasis:names:tc:opendocument:xmlns:chart:1.0\"\n" \
|
531
|
+
"xmlns:dr3d=\"urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0\"\n" \
|
532
|
+
"xmlns:math=\"http://www.w3.org/1998/Math/MathML\"\n" \
|
533
|
+
"xmlns:form=\"urn:oasis:names:tc:opendocument:xmlns:form:1.0\"\n" \
|
534
|
+
"xmlns:script=\"urn:oasis:names:tc:opendocument:xmlns:script:1.0\"\n" \
|
535
|
+
"xmlns:ooo=\"http://openoffice.org/2004/office\"\n" \
|
536
|
+
"xmlns:ooow=\"http://openoffice.org/2004/writer\"\n" \
|
537
|
+
"xmlns:oooc=\"http://openoffice.org/2004/calc\"\n" \
|
538
|
+
"xmlns:dom=\"http://www.w3.org/2001/xml-events\"\n" \
|
539
|
+
"xmlns:xforms=\"http://www.w3.org/2002/xforms\"\n" \
|
540
|
+
"xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\"\n" \
|
541
|
+
"xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"\n" \
|
542
|
+
"xmlns:rpt=\"http://openoffice.org/2005/report\"\n" \
|
543
|
+
"xmlns:of=\"urn:oasis:names:tc:opendocument:xmlns:of:1.2\"\n" \
|
544
|
+
"xmlns:xhtml=\"http://www.w3.org/1999/xhtml\"\n" \
|
545
|
+
"xmlns:grddl=\"http://www.w3.org/2003/g/data-view#\"\n" \
|
546
|
+
"xmlns:officeooo=\"http://openoffice.org/2009/office\"\n" \
|
547
|
+
"xmlns:tableooo=\"http://openoffice.org/2009/table\"\n" \
|
548
|
+
"xmlns:drawooo=\"http://openoffice.org/2010/draw\"\n" \
|
549
|
+
"xmlns:calcext=\"urn:org:documentfoundation:names:experimental:calc:xmlns:calcext:1.0\"\n" \
|
550
|
+
"xmlns:loext=\"urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.0\"\n" \
|
551
|
+
"xmlns:field=\"urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0\"\n" \
|
552
|
+
"xmlns:formx=\"urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0\"\n" \
|
553
|
+
"xmlns:css3t=\"http://www.w3.org/TR/css3-text/\"\n" \
|
554
|
+
"office:version=\"1.2\">\n");
|
551
555
|
|
552
556
|
// Styles
|
553
557
|
d_string_append(out, style);
|
@@ -655,8 +659,6 @@ static void add_assets(mz_zip_archive * pZip, mmd_engine * e, const char * direc
|
|
655
659
|
char destination[100] = "Pictures/";
|
656
660
|
destination[45] = '\0';
|
657
661
|
|
658
|
-
mz_bool status;
|
659
|
-
|
660
662
|
HASH_ITER(hh, e->asset_hash, a, a_tmp) {
|
661
663
|
|
662
664
|
memcpy(&destination[9], a->asset_path, 36);
|
@@ -813,41 +815,41 @@ mz_zip_archive * opendocument_core_zip(mmd_engine * e, int format) {
|
|
813
815
|
/// Add shared office:document config
|
814
816
|
void opendocument_document_attr(DString * out) {
|
815
817
|
print_const("xmlns:office=\"urn:oasis:names:tc:opendocument:xmlns:office:1.0\"\n" \
|
816
|
-
|
817
|
-
|
818
|
-
|
819
|
-
|
820
|
-
|
821
|
-
|
822
|
-
|
823
|
-
|
824
|
-
|
825
|
-
|
826
|
-
|
827
|
-
|
828
|
-
|
829
|
-
|
830
|
-
|
831
|
-
|
832
|
-
|
833
|
-
|
834
|
-
|
835
|
-
|
836
|
-
|
837
|
-
|
838
|
-
|
839
|
-
|
840
|
-
|
841
|
-
|
842
|
-
|
843
|
-
|
844
|
-
|
845
|
-
|
846
|
-
|
847
|
-
|
848
|
-
|
849
|
-
|
850
|
-
|
818
|
+
"xmlns:style=\"urn:oasis:names:tc:opendocument:xmlns:style:1.0\"\n" \
|
819
|
+
"xmlns:text=\"urn:oasis:names:tc:opendocument:xmlns:text:1.0\"\n" \
|
820
|
+
"xmlns:table=\"urn:oasis:names:tc:opendocument:xmlns:table:1.0\"\n" \
|
821
|
+
"xmlns:draw=\"urn:oasis:names:tc:opendocument:xmlns:drawing:1.0\"\n" \
|
822
|
+
"xmlns:fo=\"urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0\"\n" \
|
823
|
+
"xmlns:xlink=\"http://www.w3.org/1999/xlink\"\n" \
|
824
|
+
"xmlns:dc=\"http://purl.org/dc/elements/1.1/\"\n" \
|
825
|
+
"xmlns:meta=\"urn:oasis:names:tc:opendocument:xmlns:meta:1.0\"\n" \
|
826
|
+
"xmlns:number=\"urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0\"\n" \
|
827
|
+
"xmlns:svg=\"urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0\"\n" \
|
828
|
+
"xmlns:chart=\"urn:oasis:names:tc:opendocument:xmlns:chart:1.0\"\n" \
|
829
|
+
"xmlns:dr3d=\"urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0\"\n" \
|
830
|
+
"xmlns:math=\"http://www.w3.org/1998/Math/MathML\"\n" \
|
831
|
+
"xmlns:form=\"urn:oasis:names:tc:opendocument:xmlns:form:1.0\"\n" \
|
832
|
+
"xmlns:script=\"urn:oasis:names:tc:opendocument:xmlns:script:1.0\"\n" \
|
833
|
+
"xmlns:ooo=\"http://openoffice.org/2004/office\"\n" \
|
834
|
+
"xmlns:ooow=\"http://openoffice.org/2004/writer\"\n" \
|
835
|
+
"xmlns:oooc=\"http://openoffice.org/2004/calc\"\n" \
|
836
|
+
"xmlns:dom=\"http://www.w3.org/2001/xml-events\"\n" \
|
837
|
+
"xmlns:xforms=\"http://www.w3.org/2002/xforms\"\n" \
|
838
|
+
"xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\"\n" \
|
839
|
+
"xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"\n" \
|
840
|
+
"xmlns:rpt=\"http://openoffice.org/2005/report\"\n" \
|
841
|
+
"xmlns:of=\"urn:oasis:names:tc:opendocument:xmlns:of:1.2\"\n" \
|
842
|
+
"xmlns:xhtml=\"http://www.w3.org/1999/xhtml\"\n" \
|
843
|
+
"xmlns:grddl=\"http://www.w3.org/2003/g/data-view#\"\n" \
|
844
|
+
"xmlns:officeooo=\"http://openoffice.org/2009/office\"\n" \
|
845
|
+
"xmlns:tableooo=\"http://openoffice.org/2009/table\"\n" \
|
846
|
+
"xmlns:drawooo=\"http://openoffice.org/2010/draw\"\n" \
|
847
|
+
"xmlns:calcext=\"urn:org:documentfoundation:names:experimental:calc:xmlns:calcext:1.0\"\n" \
|
848
|
+
"xmlns:loext=\"urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.0\"\n" \
|
849
|
+
"xmlns:field=\"urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0\"\n" \
|
850
|
+
"xmlns:formx=\"urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0\"\n" \
|
851
|
+
"xmlns:css3t=\"http://www.w3.org/TR/css3-text/\"\n" \
|
852
|
+
"office:version=\"1.2\"");
|
851
853
|
}
|
852
854
|
|
853
855
|
|