sheng 0.3.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (106) hide show
  1. checksums.yaml +7 -0
  2. data/.gitattributes +1 -0
  3. data/.gitignore +18 -0
  4. data/.rspec +3 -0
  5. data/.ruby-version +1 -0
  6. data/.watchr +99 -0
  7. data/Gemfile +4 -0
  8. data/LICENSE.txt +22 -0
  9. data/README.md +62 -0
  10. data/Rakefile +10 -0
  11. data/docs/creating_templates.docx +0 -0
  12. data/docs/creating_templates.md +392 -0
  13. data/lib/sheng/block.rb +59 -0
  14. data/lib/sheng/check_box.rb +43 -0
  15. data/lib/sheng/conditional_block.rb +30 -0
  16. data/lib/sheng/data_set.rb +45 -0
  17. data/lib/sheng/docx.rb +75 -0
  18. data/lib/sheng/merge_field.rb +208 -0
  19. data/lib/sheng/merge_field_set.rb +90 -0
  20. data/lib/sheng/path_helpers.rb +15 -0
  21. data/lib/sheng/sequence.rb +66 -0
  22. data/lib/sheng/support.rb +57 -0
  23. data/lib/sheng/version.rb +3 -0
  24. data/lib/sheng/wml_file.rb +47 -0
  25. data/lib/sheng.rb +21 -0
  26. data/sheng.gemspec +31 -0
  27. data/spec/fixtures/bad_docx_files/with_field_not_in_dataset.docx +0 -0
  28. data/spec/fixtures/bad_docx_files/with_missing_sequence_start.docx +0 -0
  29. data/spec/fixtures/bad_docx_files/with_old_mergefields.docx +0 -0
  30. data/spec/fixtures/bad_docx_files/with_poorly_nested_sequences.docx +0 -0
  31. data/spec/fixtures/bad_docx_files/with_unended_sequence.docx +0 -0
  32. data/spec/fixtures/docx_files/input_document.docx +0 -0
  33. data/spec/fixtures/docx_files/old_style/input_document.docx +0 -0
  34. data/spec/fixtures/docx_files/old_style/output_document.docx +0 -0
  35. data/spec/fixtures/docx_files/output_document.docx +0 -0
  36. data/spec/fixtures/inputs/complete.json +61 -0
  37. data/spec/fixtures/inputs/incomplete.json +52 -0
  38. data/spec/fixtures/trees/embedded_sequence.yml +13 -0
  39. data/spec/fixtures/trees/merge_field_set.yml +16 -0
  40. data/spec/fixtures/xml_fragments/input/check_box/check_box.xml +11 -0
  41. data/spec/fixtures/xml_fragments/input/conditional_block/bad/badly_nested_conditional.xml +105 -0
  42. data/spec/fixtures/xml_fragments/input/conditional_block/bad/unclosed_conditional.xml +35 -0
  43. data/spec/fixtures/xml_fragments/input/conditional_block/conditional_block_if.xml +84 -0
  44. data/spec/fixtures/xml_fragments/input/conditional_block/conditional_block_inline.xml +59 -0
  45. data/spec/fixtures/xml_fragments/input/conditional_block/conditional_block_unless.xml +51 -0
  46. data/spec/fixtures/xml_fragments/input/conditional_block/conditional_in_table.xml +176 -0
  47. data/spec/fixtures/xml_fragments/input/conditional_block/embedded_conditional.xml +79 -0
  48. data/spec/fixtures/xml_fragments/input/merge_field/bad/not_a_real_mergefield_new.xml +19 -0
  49. data/spec/fixtures/xml_fragments/input/merge_field/bad/not_a_real_mergefield_old.xml +9 -0
  50. data/spec/fixtures/xml_fragments/input/merge_field/bad/unclosed_merge_field.xml +25 -0
  51. data/spec/fixtures/xml_fragments/input/merge_field/inline_merge_field.xml +26 -0
  52. data/spec/fixtures/xml_fragments/input/merge_field/merge_field.xml +14 -0
  53. data/spec/fixtures/xml_fragments/input/merge_field/new_merge_field.xml +28 -0
  54. data/spec/fixtures/xml_fragments/input/merge_field/split_merge_field.xml +33 -0
  55. data/spec/fixtures/xml_fragments/input/merge_field_set/complex_nesting_and_reuse.xml +231 -0
  56. data/spec/fixtures/xml_fragments/input/merge_field_set/merge_field_set.xml +89 -0
  57. data/spec/fixtures/xml_fragments/input/merge_field_set/with_non_mergefield_fields.xml +43 -0
  58. data/spec/fixtures/xml_fragments/input/sequence/array_sequence.xml +23 -0
  59. data/spec/fixtures/xml_fragments/input/sequence/bad/badly_nested_sequence.xml +62 -0
  60. data/spec/fixtures/xml_fragments/input/sequence/bad/unclosed_sequence.xml +32 -0
  61. data/spec/fixtures/xml_fragments/input/sequence/embedded_sequence.xml +68 -0
  62. data/spec/fixtures/xml_fragments/input/sequence/inline_sequence.xml +24 -0
  63. data/spec/fixtures/xml_fragments/input/sequence/overridden_iterator_array_sequence.xml +23 -0
  64. data/spec/fixtures/xml_fragments/input/sequence/sequence.xml +39 -0
  65. data/spec/fixtures/xml_fragments/input/sequence/sequence_in_table.xml +125 -0
  66. data/spec/fixtures/xml_fragments/input/sequence/sequence_with_section_formatting.xml +41 -0
  67. data/spec/fixtures/xml_fragments/input/sequence/series_with_commas.xml +73 -0
  68. data/spec/fixtures/xml_fragments/output/check_box/check_box.xml +11 -0
  69. data/spec/fixtures/xml_fragments/output/conditional_block/conditional_in_table_does_not_exist.xml +52 -0
  70. data/spec/fixtures/xml_fragments/output/conditional_block/conditional_in_table_exists.xml +84 -0
  71. data/spec/fixtures/xml_fragments/output/conditional_block/embedded_conditional_both.xml +11 -0
  72. data/spec/fixtures/xml_fragments/output/conditional_block/embedded_conditional_inside.xml +5 -0
  73. data/spec/fixtures/xml_fragments/output/conditional_block/embedded_conditional_outside.xml +8 -0
  74. data/spec/fixtures/xml_fragments/output/conditional_block/if_does_not_exist.xml +5 -0
  75. data/spec/fixtures/xml_fragments/output/conditional_block/if_exists.xml +19 -0
  76. data/spec/fixtures/xml_fragments/output/conditional_block/inline_does_not_exist.xml +10 -0
  77. data/spec/fixtures/xml_fragments/output/conditional_block/inline_exists.xml +13 -0
  78. data/spec/fixtures/xml_fragments/output/conditional_block/unless_does_not_exist.xml +11 -0
  79. data/spec/fixtures/xml_fragments/output/conditional_block/unless_exists.xml +5 -0
  80. data/spec/fixtures/xml_fragments/output/merge_field/inline_merge_field.xml +11 -0
  81. data/spec/fixtures/xml_fragments/output/merge_field/merge_field.xml +12 -0
  82. data/spec/fixtures/xml_fragments/output/merge_field/split_merge_field.xml +10 -0
  83. data/spec/fixtures/xml_fragments/output/merge_field_set/complex_nesting_and_reuse.xml +190 -0
  84. data/spec/fixtures/xml_fragments/output/merge_field_set/merge_field_set.xml +75 -0
  85. data/spec/fixtures/xml_fragments/output/merge_field_set/with_non_mergefield_fields.xml +31 -0
  86. data/spec/fixtures/xml_fragments/output/sequence/array_sequence.xml +17 -0
  87. data/spec/fixtures/xml_fragments/output/sequence/embedded_sequence.xml +56 -0
  88. data/spec/fixtures/xml_fragments/output/sequence/inline_sequence.xml +16 -0
  89. data/spec/fixtures/xml_fragments/output/sequence/overridden_iterator_array_sequence.xml +12 -0
  90. data/spec/fixtures/xml_fragments/output/sequence/sequence.xml +28 -0
  91. data/spec/fixtures/xml_fragments/output/sequence/sequence_in_table.xml +120 -0
  92. data/spec/fixtures/xml_fragments/output/sequence/sequence_with_section_formatting.xml +46 -0
  93. data/spec/fixtures/xml_fragments/output/sequence/series_with_commas.xml +43 -0
  94. data/spec/fixtures/xml_fragments/output/sequence/series_with_commas_two_items.xml +31 -0
  95. data/spec/lib/sheng/check_box_spec.rb +87 -0
  96. data/spec/lib/sheng/conditional_block_spec.rb +151 -0
  97. data/spec/lib/sheng/data_set_spec.rb +65 -0
  98. data/spec/lib/sheng/docx_spec.rb +146 -0
  99. data/spec/lib/sheng/merge_field_set_spec.rb +165 -0
  100. data/spec/lib/sheng/merge_field_spec.rb +276 -0
  101. data/spec/lib/sheng/sequence_spec.rb +201 -0
  102. data/spec/lib/sheng/wml_file_spec.rb +38 -0
  103. data/spec/spec_helper.rb +16 -0
  104. data/spec/support/path_helper.rb +15 -0
  105. data/spec/support/xml_helper.rb +28 -0
  106. metadata +355 -0
@@ -0,0 +1,89 @@
1
+ <w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">
2
+ <w:p>
3
+ <w:r>
4
+ <w:t xml:space="preserve">First Name: </w:t>
5
+ </w:r>
6
+ <w:fldSimple w:instr=" MERGEFIELD person.first_name \* MERGEFORMAT ">
7
+ <w:r>
8
+ <w:rPr>
9
+ <w:noProof/>
10
+ </w:rPr>
11
+ <w:t>«person.first_name»</w:t>
12
+ </w:r>
13
+ </w:fldSimple>
14
+ <w:r>
15
+ <w:tab/>
16
+ <w:t xml:space="preserve">Last Name: </w:t>
17
+ </w:r>
18
+ <w:fldSimple w:instr=" MERGEFIELD person.last_name | upcase \* MERGEFORMAT ">
19
+ <w:r>
20
+ <w:rPr>
21
+ <w:noProof/>
22
+ </w:rPr>
23
+ <w:t>«person.last_name | upcase»</w:t>
24
+ </w:r>
25
+ </w:fldSimple>
26
+ </w:p>
27
+ <w:p>
28
+ <w:fldSimple w:instr=" MERGEFIELD start:person.socks \* MERGEFORMAT ">
29
+ <w:r w:rsidR="00455C8A">
30
+ <w:rPr>
31
+ <w:noProof/>
32
+ </w:rPr>
33
+ <w:t>«start:person.socks»</w:t>
34
+ </w:r>
35
+ </w:fldSimple>
36
+ </w:p>
37
+ <w:p>
38
+ <w:fldSimple w:instr=" MERGEFIELD color \* MERGEFORMAT ">
39
+ <w:r>
40
+ <w:rPr>
41
+ <w:noProof/>
42
+ </w:rPr>
43
+ <w:t>«color»</w:t>
44
+ </w:r>
45
+ </w:fldSimple>
46
+ </w:p>
47
+ <w:p>
48
+ <w:fldSimple w:instr=" MERGEFIELD size \* MERGEFORMAT ">
49
+ <w:r>
50
+ <w:rPr>
51
+ <w:noProof/>
52
+ </w:rPr>
53
+ <w:t>«size»</w:t>
54
+ </w:r>
55
+ </w:fldSimple>
56
+ </w:p>
57
+ <w:p>
58
+ <w:fldSimple w:instr=" MERGEFIELD end:person.socks \* MERGEFORMAT ">
59
+ <w:r w:rsidR="00455C8A">
60
+ <w:rPr>
61
+ <w:noProof/>
62
+ </w:rPr>
63
+ <w:t>«end:person.socks»</w:t>
64
+ </w:r>
65
+ </w:fldSimple>
66
+ </w:p>
67
+ <w:ffData>
68
+ <w:name w:val="veggies.green.spinach"/>
69
+ <w:enabled/>
70
+ <w:calcOnExit w:val="0"/>
71
+ <w:checkBox>
72
+ <w:sizeAuto/>
73
+ <w:default w:val="0"/>
74
+ </w:checkBox>
75
+ </w:ffData>
76
+ <w:p>
77
+ <w:r>
78
+ <w:t xml:space="preserve">First Name Again: </w:t>
79
+ </w:r>
80
+ <w:fldSimple w:instr=" MERGEFIELD person.first_name \* MERGEFORMAT ">
81
+ <w:r>
82
+ <w:rPr>
83
+ <w:noProof/>
84
+ </w:rPr>
85
+ <w:t>«person.first_name»</w:t>
86
+ </w:r>
87
+ </w:fldSimple>
88
+ </w:p>
89
+ </w:document>
@@ -0,0 +1,43 @@
1
+ <w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">
2
+ <w:p>
3
+ <w:r>
4
+ <w:fldChar w:fldCharType="begin"/>
5
+ </w:r>
6
+ <w:r>
7
+ <w:instrText xml:space="preserve">MERGEFIELD color \* MERGEFORMAT </w:instrText>
8
+ </w:r>
9
+ <w:r>
10
+ <w:fldChar w:fldCharType="separate"/>
11
+ </w:r>
12
+ <w:r>
13
+ <w:t>«color»</w:t>
14
+ </w:r>
15
+ <w:r>
16
+ <w:fldChar w:fldCharType="end"/>
17
+ </w:r>
18
+ </w:p>
19
+ <w:p>
20
+ <w:r>
21
+ <w:fldChar w:fldCharType="begin"/>
22
+ </w:r>
23
+ <w:r>
24
+ <w:instrText xml:space="preserve">PAGE \* MERGEFORMAT </w:instrText>
25
+ </w:r>
26
+ <w:r>
27
+ <w:fldChar w:fldCharType="separate"/>
28
+ </w:r>
29
+ <w:r>
30
+ <w:t>1</w:t>
31
+ </w:r>
32
+ <w:r>
33
+ <w:fldChar w:fldCharType="end"/>
34
+ </w:r>
35
+ </w:p>
36
+ <w:p>
37
+ <w:fldSimple w:instr=" PAGE \* MERGEFORMAT ">
38
+ <w:r>
39
+ <w:t>1</w:t>
40
+ </w:r>
41
+ </w:fldSimple>
42
+ </w:p>
43
+ </w:document>
@@ -0,0 +1,23 @@
1
+ <w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">
2
+ <w:p>
3
+ <w:fldSimple w:instr=" MERGEFIELD start:my_dog.favorite_toys \* MERGEFORMAT ">
4
+ <w:r>
5
+ <w:t>«start:my_dog.favorite_toys»</w:t>
6
+ </w:r>
7
+ </w:fldSimple>
8
+ </w:p>
9
+ <w:p>
10
+ <w:fldSimple w:instr=" MERGEFIELD item \* MERGEFORMAT ">
11
+ <w:r>
12
+ <w:t>«item»</w:t>
13
+ </w:r>
14
+ </w:fldSimple>
15
+ </w:p>
16
+ <w:p>
17
+ <w:fldSimple w:instr=" MERGEFIELD end:my_dog.favorite_toys \* MERGEFORMAT ">
18
+ <w:r>
19
+ <w:t>«end:my_dog.favorite_toys»</w:t>
20
+ </w:r>
21
+ </w:fldSimple>
22
+ </w:p>
23
+ </w:document>
@@ -0,0 +1,62 @@
1
+ <w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">
2
+ <w:p>
3
+ <w:fldSimple w:instr=" MERGEFIELD start:animals \* MERGEFORMAT ">
4
+ <w:r>
5
+ <w:rPr>
6
+ <w:noProof/>
7
+ </w:rPr>
8
+ <w:t>«start:animals»</w:t>
9
+ </w:r>
10
+ </w:fldSimple>
11
+ </w:p>
12
+ <w:p>
13
+ <w:fldSimple w:instr=" MERGEFIELD color \* MERGEFORMAT ">
14
+ <w:r>
15
+ <w:rPr>
16
+ <w:noProof/>
17
+ </w:rPr>
18
+ <w:t>«color»</w:t>
19
+ </w:r>
20
+ </w:fldSimple>
21
+ </w:p>
22
+ <w:p>
23
+ <w:fldSimple w:instr=" MERGEFIELD start:birds \* MERGEFORMAT ">
24
+ <w:r>
25
+ <w:rPr>
26
+ <w:noProof/>
27
+ </w:rPr>
28
+ <w:t>«start:birds»</w:t>
29
+ </w:r>
30
+ </w:fldSimple>
31
+ </w:p>
32
+ <w:p>
33
+ <w:fldSimple w:instr=" MERGEFIELD wingspan \* MERGEFORMAT ">
34
+ <w:r>
35
+ <w:rPr>
36
+ <w:noProof/>
37
+ </w:rPr>
38
+ <w:t>«wingspan»</w:t>
39
+ </w:r>
40
+ </w:fldSimple>
41
+ </w:p>
42
+ <w:p>
43
+ <w:fldSimple w:instr=" MERGEFIELD end:animals \* MERGEFORMAT ">
44
+ <w:r>
45
+ <w:rPr>
46
+ <w:noProof/>
47
+ </w:rPr>
48
+ <w:t>«end:animals»</w:t>
49
+ </w:r>
50
+ </w:fldSimple>
51
+ </w:p>
52
+ <w:p>
53
+ <w:fldSimple w:instr=" MERGEFIELD end:birds \* MERGEFORMAT ">
54
+ <w:r>
55
+ <w:rPr>
56
+ <w:noProof/>
57
+ </w:rPr>
58
+ <w:t>«end:birds»</w:t>
59
+ </w:r>
60
+ </w:fldSimple>
61
+ </w:p>
62
+ </w:document>
@@ -0,0 +1,32 @@
1
+ <w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">
2
+ <w:p>
3
+ <w:fldSimple w:instr=" MERGEFIELD start:library.books \* MERGEFORMAT ">
4
+ <w:r w:rsidR="00455C8A">
5
+ <w:rPr>
6
+ <w:noProof/>
7
+ </w:rPr>
8
+ <w:t>«start:library.books»</w:t>
9
+ </w:r>
10
+ </w:fldSimple>
11
+ </w:p>
12
+ <w:p>
13
+ <w:fldSimple w:instr=" MERGEFIELD title \* MERGEFORMAT ">
14
+ <w:r>
15
+ <w:rPr>
16
+ <w:noProof/>
17
+ </w:rPr>
18
+ <w:t>«title»</w:t>
19
+ </w:r>
20
+ </w:fldSimple>
21
+ </w:p>
22
+ <w:p>
23
+ <w:fldSimple w:instr=" MERGEFIELD scent \* MERGEFORMAT ">
24
+ <w:r>
25
+ <w:rPr>
26
+ <w:noProof/>
27
+ </w:rPr>
28
+ <w:t>«scent»</w:t>
29
+ </w:r>
30
+ </w:fldSimple>
31
+ </w:p>
32
+ </w:document>
@@ -0,0 +1,68 @@
1
+ <w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">
2
+ <w:p>
3
+ <w:fldSimple w:instr=" MERGEFIELD start:library.books \* MERGEFORMAT ">
4
+ <w:r w:rsidR="00455C8A">
5
+ <w:rPr>
6
+ <w:noProof/>
7
+ </w:rPr>
8
+ <w:t>«start:library.books»</w:t>
9
+ </w:r>
10
+ </w:fldSimple>
11
+ </w:p>
12
+ <w:p>
13
+ <w:fldSimple w:instr=" MERGEFIELD title \* MERGEFORMAT ">
14
+ <w:r>
15
+ <w:t>«title»</w:t>
16
+ </w:r>
17
+ </w:fldSimple>
18
+ </w:p>
19
+ <w:p>
20
+ <w:p>
21
+ <w:fldSimple w:instr=" MERGEFIELD start:pages \* MERGEFORMAT ">
22
+ <w:r w:rsidR="00455C8A">
23
+ <w:t>«start:pages»</w:t>
24
+ </w:r>
25
+ </w:fldSimple>
26
+ </w:p>
27
+ <w:p>
28
+ <w:fldSimple w:instr=" MERGEFIELD size \* MERGEFORMAT ">
29
+ <w:r>
30
+ <w:rPr>
31
+ <w:noProof/>
32
+ </w:rPr>
33
+ <w:t>«size»</w:t>
34
+ </w:r>
35
+ </w:fldSimple>
36
+ </w:p>
37
+ <w:p>
38
+ <w:fldSimple w:instr=" MERGEFIELD end:pages \* MERGEFORMAT ">
39
+ <w:r w:rsidR="00455C8A">
40
+ <w:rPr>
41
+ <w:noProof/>
42
+ </w:rPr>
43
+ <w:t>«end:pages»</w:t>
44
+ </w:r>
45
+ </w:fldSimple>
46
+ </w:p>
47
+ </w:p>
48
+ <w:p>
49
+ <w:fldSimple w:instr=" MERGEFIELD scent \* MERGEFORMAT ">
50
+ <w:r>
51
+ <w:rPr>
52
+ <w:noProof/>
53
+ </w:rPr>
54
+ <w:t>«scent»</w:t>
55
+ </w:r>
56
+ </w:fldSimple>
57
+ </w:p>
58
+ <w:p>
59
+ <w:fldSimple w:instr=" MERGEFIELD end:library.books \* MERGEFORMAT ">
60
+ <w:r w:rsidR="00455C8A">
61
+ <w:rPr>
62
+ <w:noProof/>
63
+ </w:rPr>
64
+ <w:t>«end:library.books»</w:t>
65
+ </w:r>
66
+ </w:fldSimple>
67
+ </w:p>
68
+ </w:document>
@@ -0,0 +1,24 @@
1
+ <w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">
2
+ <w:p>
3
+ <w:fldSimple w:instr=" MERGEFIELD start:library.books \* MERGEFORMAT ">
4
+ <w:r>
5
+ <w:t>«start:library.books»</w:t>
6
+ </w:r>
7
+ </w:fldSimple>
8
+ <w:fldSimple w:instr=" MERGEFIELD title \* MERGEFORMAT ">
9
+ <w:r>
10
+ <w:t>«title»</w:t>
11
+ </w:r>
12
+ </w:fldSimple>
13
+ <w:fldSimple w:instr=" MERGEFIELD scent \* MERGEFORMAT ">
14
+ <w:r>
15
+ <w:t>«scent»</w:t>
16
+ </w:r>
17
+ </w:fldSimple>
18
+ <w:fldSimple w:instr=" MERGEFIELD end:library.books \* MERGEFORMAT ">
19
+ <w:r>
20
+ <w:t>«end:library.books»</w:t>
21
+ </w:r>
22
+ </w:fldSimple>
23
+ </w:p>
24
+ </w:document>
@@ -0,0 +1,23 @@
1
+ <w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">
2
+ <w:p>
3
+ <w:fldSimple w:instr=" MERGEFIELD start:perps | as(bad_guy) \* MERGEFORMAT ">
4
+ <w:r>
5
+ <w:t>«start:perps | as(bad_guy)»</w:t>
6
+ </w:r>
7
+ </w:fldSimple>
8
+ </w:p>
9
+ <w:p>
10
+ <w:fldSimple w:instr=" MERGEFIELD bad_guy \* MERGEFORMAT ">
11
+ <w:r>
12
+ <w:t>«bad_guy»</w:t>
13
+ </w:r>
14
+ </w:fldSimple>
15
+ </w:p>
16
+ <w:p>
17
+ <w:fldSimple w:instr=" MERGEFIELD end:perps \* MERGEFORMAT ">
18
+ <w:r>
19
+ <w:t>«end:perps»</w:t>
20
+ </w:r>
21
+ </w:fldSimple>
22
+ </w:p>
23
+ </w:document>
@@ -0,0 +1,39 @@
1
+ <w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">
2
+ <w:p>
3
+ <w:fldSimple w:instr=" MERGEFIELD start:library.books \* MERGEFORMAT ">
4
+ <w:r w:rsidR="00455C8A">
5
+ <w:rPr>
6
+ <w:noProof/>
7
+ </w:rPr>
8
+ <w:t>«start:library.books»</w:t>
9
+ </w:r>
10
+ </w:fldSimple>
11
+ </w:p>
12
+ <w:p>
13
+ <w:fldSimple w:instr=" MERGEFIELD title \* MERGEFORMAT ">
14
+ <w:r>
15
+ <w:t>«title»</w:t>
16
+ </w:r>
17
+ </w:fldSimple>
18
+ </w:p>
19
+ <w:p>
20
+ <w:fldSimple w:instr=" MERGEFIELD scent \* MERGEFORMAT ">
21
+ <w:r>
22
+ <w:rPr>
23
+ <w:noProof/>
24
+ </w:rPr>
25
+ <w:t>«scent»</w:t>
26
+ </w:r>
27
+ </w:fldSimple>
28
+ </w:p>
29
+ <w:p>
30
+ <w:fldSimple w:instr=" MERGEFIELD end:library.books \* MERGEFORMAT ">
31
+ <w:r w:rsidR="00455C8A">
32
+ <w:rPr>
33
+ <w:noProof/>
34
+ </w:rPr>
35
+ <w:t>«end:library.books»</w:t>
36
+ </w:r>
37
+ </w:fldSimple>
38
+ </w:p>
39
+ </w:document>
@@ -0,0 +1,125 @@
1
+ <w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">
2
+ <w:tbl>
3
+ <w:tr>
4
+ <w:tc>
5
+ <w:p>
6
+ <w:r>
7
+ <w:t>Meal</w:t>
8
+ </w:r>
9
+ </w:p>
10
+ </w:tc>
11
+ <w:tc>
12
+ <w:p>
13
+ <w:r>
14
+ <w:t>Drink</w:t>
15
+ </w:r>
16
+ </w:p>
17
+ </w:tc>
18
+ <w:tc>
19
+ <w:p>
20
+ <w:r>
21
+ <w:t>Appetizer</w:t>
22
+ </w:r>
23
+ </w:p>
24
+ </w:tc>
25
+ <w:tc>
26
+ <w:p>
27
+ <w:r>
28
+ <w:t>Dessert</w:t>
29
+ </w:r>
30
+ </w:p>
31
+ </w:tc>
32
+ </w:tr>
33
+ <w:tr>
34
+ <w:tc>
35
+ <w:p>
36
+ <w:fldSimple w:instr=" MERGEFIELD start:meals \* MERGEFORMAT ">
37
+ <w:r w:rsidR="002E3E51">
38
+ <w:rPr>
39
+ <w:noProof/>
40
+ </w:rPr>
41
+ <w:t>«start:meals»</w:t>
42
+ </w:r>
43
+ </w:fldSimple>
44
+ </w:p>
45
+ </w:tc>
46
+ <w:tc>
47
+ </w:tc>
48
+ <w:tc>
49
+ </w:tc>
50
+ <w:tc>
51
+ </w:tc>
52
+ </w:tr>
53
+ <w:tr>
54
+ <w:tc>
55
+ <w:p>
56
+ <w:fldSimple w:instr=" MERGEFIELD meal \* MERGEFORMAT ">
57
+ <w:r w:rsidR="00623574">
58
+ <w:t>«meal»</w:t>
59
+ </w:r>
60
+ </w:fldSimple>
61
+ </w:p>
62
+ </w:tc>
63
+ <w:tc>
64
+ </w:tc>
65
+ <w:tc>
66
+ <w:p>
67
+ <w:fldSimple w:instr=" MERGEFIELD appetizer \* MERGEFORMAT ">
68
+ <w:r w:rsidR="00623574">
69
+ <w:t>«appetizer»</w:t>
70
+ </w:r>
71
+ </w:fldSimple>
72
+ </w:p>
73
+ </w:tc>
74
+ <w:tc>
75
+ <w:p>
76
+ <w:fldSimple w:instr=" MERGEFIELD dessert \* MERGEFORMAT ">
77
+ <w:r w:rsidR="00623574">
78
+ <w:t>«dessert»</w:t>
79
+ </w:r>
80
+ </w:fldSimple>
81
+ </w:p>
82
+ </w:tc>
83
+ </w:tr>
84
+ <w:tr>
85
+ <w:tc>
86
+ <w:p>
87
+ <w:fldSimple w:instr=" MERGEFIELD drink \* MERGEFORMAT ">
88
+ <w:r w:rsidR="00E069D4">
89
+ <w:rPr>
90
+ <w:noProof/>
91
+ </w:rPr>
92
+ <w:t>«drink»</w:t>
93
+ </w:r>
94
+ </w:fldSimple>
95
+ </w:p>
96
+ </w:tc>
97
+ <w:tc>
98
+ </w:tc>
99
+ <w:tc>
100
+ </w:tc>
101
+ <w:tc>
102
+ </w:tc>
103
+ </w:tr>
104
+ <w:tr>
105
+ <w:tc>
106
+ <w:p>
107
+ <w:fldSimple w:instr=" MERGEFIELD end:meals \* MERGEFORMAT ">
108
+ <w:r w:rsidR="002E3E51">
109
+ <w:rPr>
110
+ <w:noProof/>
111
+ </w:rPr>
112
+ <w:t>«end:meals»</w:t>
113
+ </w:r>
114
+ </w:fldSimple>
115
+ </w:p>
116
+ </w:tc>
117
+ <w:tc>
118
+ </w:tc>
119
+ <w:tc>
120
+ </w:tc>
121
+ <w:tc>
122
+ </w:tc>
123
+ </w:tr>
124
+ </w:tbl>
125
+ </w:document>
@@ -0,0 +1,41 @@
1
+ <w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">
2
+ <w:p>
3
+ <w:pPr>
4
+ <w:pStyle w:val="fancy"/>
5
+ <w:sectPr>
6
+ <w:cols w:num="1" w:space="10"/>
7
+ </w:sectPr>
8
+ </w:pPr>
9
+ <w:fldSimple w:instr=" MERGEFIELD start:countries \* MERGEFORMAT ">
10
+ <w:r>
11
+ <w:t>«start:countries»</w:t>
12
+ </w:r>
13
+ </w:fldSimple>
14
+ </w:p>
15
+ <w:p>
16
+ <w:pPr>
17
+ <w:pStyle w:val="fancy"/>
18
+ <w:sectPr>
19
+ <w:cols w:num="2" w:space="20"/>
20
+ </w:sectPr>
21
+ </w:pPr>
22
+ <w:fldSimple w:instr=" MERGEFIELD item \* MERGEFORMAT ">
23
+ <w:r>
24
+ <w:t>«item»</w:t>
25
+ </w:r>
26
+ </w:fldSimple>
27
+ </w:p>
28
+ <w:p>
29
+ <w:pPr>
30
+ <w:pStyle w:val="dumb"/>
31
+ <w:sectPr>
32
+ <w:cols w:num="3" w:space="30"/>
33
+ </w:sectPr>
34
+ </w:pPr>
35
+ <w:fldSimple w:instr=" MERGEFIELD end:countries \* MERGEFORMAT ">
36
+ <w:r>
37
+ <w:t>«end:countries»</w:t>
38
+ </w:r>
39
+ </w:fldSimple>
40
+ </w:p>
41
+ </w:document>
@@ -0,0 +1,73 @@
1
+ <w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">
2
+ <w:p>
3
+ <w:r>
4
+ <w:t xml:space="preserve">Here's a list of buffoons: </w:t>
5
+ </w:r>
6
+ <w:r>
7
+ <w:fldChar w:fldCharType="begin"/>
8
+ </w:r>
9
+ <w:r>
10
+ <w:instrText xml:space="preserve">MERGEFIELD start:buffoons | series_with_commas \* MERGEFORMAT </w:instrText>
11
+ </w:r>
12
+ <w:r>
13
+ <w:fldChar w:fldCharType="separate"/>
14
+ </w:r>
15
+ <w:r>
16
+ <w:t>«start:buffoons | series_with_commas»</w:t>
17
+ </w:r>
18
+ <w:r>
19
+ <w:fldChar w:fldCharType="end"/>
20
+ </w:r>
21
+ <w:r>
22
+ <w:fldChar w:fldCharType="begin"/>
23
+ </w:r>
24
+ <w:r>
25
+ <w:instrText xml:space="preserve">MERGEFIELD first_name \* MERGEFORMAT </w:instrText>
26
+ </w:r>
27
+ <w:r>
28
+ <w:fldChar w:fldCharType="separate"/>
29
+ </w:r>
30
+ <w:r>
31
+ <w:t>«first_name»</w:t>
32
+ </w:r>
33
+ <w:r>
34
+ <w:fldChar w:fldCharType="end"/>
35
+ </w:r>
36
+ <w:r>
37
+ <w:t xml:space="preserve"> </w:t>
38
+ </w:r>
39
+ <w:r>
40
+ <w:fldChar w:fldCharType="begin"/>
41
+ </w:r>
42
+ <w:r>
43
+ <w:instrText xml:space="preserve">MERGEFIELD last_name \* MERGEFORMAT </w:instrText>
44
+ </w:r>
45
+ <w:r>
46
+ <w:fldChar w:fldCharType="separate"/>
47
+ </w:r>
48
+ <w:r>
49
+ <w:t>«last_name»</w:t>
50
+ </w:r>
51
+ <w:r>
52
+ <w:fldChar w:fldCharType="end"/>
53
+ </w:r>
54
+ <w:r>
55
+ <w:fldChar w:fldCharType="begin"/>
56
+ </w:r>
57
+ <w:r>
58
+ <w:instrText xml:space="preserve">MERGEFIELD end:buffoons \* MERGEFORMAT </w:instrText>
59
+ </w:r>
60
+ <w:r>
61
+ <w:fldChar w:fldCharType="separate"/>
62
+ </w:r>
63
+ <w:r>
64
+ <w:t>«end:buffoons</w:t>
65
+ </w:r>
66
+ <w:r>
67
+ <w:fldChar w:fldCharType="end"/>
68
+ </w:r>
69
+ <w:r>
70
+ <w:t xml:space="preserve">. Phew. What a list.</w:t>
71
+ </w:r>
72
+ </w:p>
73
+ </w:document>
@@ -0,0 +1,11 @@
1
+ <w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">
2
+ <w:ffData>
3
+ <w:name w:val="goats"/>
4
+ <w:enabled/>
5
+ <w:calcOnExit w:val="0"/>
6
+ <w:checkBox>
7
+ <w:sizeAuto/>
8
+ <w:default w:val="1"/>
9
+ </w:checkBox>
10
+ </w:ffData>
11
+ </w:document>