Skip to content

Commit b189d9d

Browse files
committed
add formatter append transferred references
1 parent e2e983a commit b189d9d

112 files changed

Lines changed: 5418 additions & 413 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.idea/compiler.xml

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/encodings.xml

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/runConfigurations/ComboParserTest.xml

Lines changed: 18 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/runConfigurations/ComboParserTest_testHtmlRendering.xml

Lines changed: 22 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/runConfigurations/ComboParserTest_testHtmlRendering_alloceach_1_monitors_.xml

Lines changed: 22 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

VERSION.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ flexmark-java
77

88
- [To Do](#to-do)
99
- [Docx Converter](#docx-converter)
10+
- [0.34.60](#03460)
1011
- [0.34.58](#03458)
1112
- [0.34.56](#03456)
1213
- [0.34.53](#03453)
@@ -260,6 +261,22 @@ flexmark-java
260261

261262
&nbsp;</details>
262263

264+
0.34.60
265+
-------
266+
267+
* Change: some breaking changes to FormattingAppendableImpl derived constructors. Now all
268+
arguments must be passed, no defaults. It was getting too messy to trace which constructors
269+
were used and what were the resulting options for the appendable.
270+
* Fix: optimized HTML rendering with `HtmlRenderer.FORMAT_FLAGS` set to
271+
`HtmlRenderer.PASS_THROUGH`, no fancy output formatting other than line breaks but 7x faster
272+
than using standard fancy formatting output.
273+
* Fix: Emoji shortcut did not render emoji with UNICODE_ONLY image type option
274+
* Add: `Formatter.KEEP_HARD_LINE_BREAKS`, default true and `Formatter.KEEP_SOFT_LINE_BREAKS`
275+
default true. Setting to `false` will not output corresponding line break.
276+
* Add: `Formatter.APPEND_TRANSFERRED_REFERENCES`, default false. Setting to `true` will append
277+
all transferred references to the bottom of the formatted document.
278+
* Add: `NodeRepository` API to return referenced references from a given node.
279+
263280
0.34.58
264281
-------
265282

flexmark-all/pom.xml

Lines changed: 39 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<parent>
88
<groupId>com.vladsch.flexmark</groupId>
99
<artifactId>flexmark-java</artifactId>
10-
<version>0.34.58</version>
10+
<version>0.34.60</version>
1111
</parent>
1212

1313
<artifactId>flexmark-all</artifactId>
@@ -21,192 +21,192 @@
2121
<dependency>
2222
<groupId>com.vladsch.flexmark</groupId>
2323
<artifactId>flexmark</artifactId>
24-
<version>0.34.58</version>
24+
<version>0.34.60</version>
2525
</dependency>
2626
<dependency>
2727
<groupId>com.vladsch.flexmark</groupId>
2828
<artifactId>flexmark-ext-abbreviation</artifactId>
29-
<version>0.34.58</version>
29+
<version>0.34.60</version>
3030
</dependency>
3131
<dependency>
3232
<groupId>com.vladsch.flexmark</groupId>
3333
<artifactId>flexmark-ext-admonition</artifactId>
34-
<version>0.34.58</version>
34+
<version>0.34.60</version>
3535
</dependency>
3636
<dependency>
3737
<groupId>com.vladsch.flexmark</groupId>
3838
<artifactId>flexmark-ext-anchorlink</artifactId>
39-
<version>0.34.58</version>
39+
<version>0.34.60</version>
4040
</dependency>
4141
<dependency>
4242
<groupId>com.vladsch.flexmark</groupId>
4343
<artifactId>flexmark-ext-aside</artifactId>
44-
<version>0.34.58</version>
44+
<version>0.34.60</version>
4545
</dependency>
4646
<dependency>
4747
<groupId>com.vladsch.flexmark</groupId>
4848
<artifactId>flexmark-ext-attributes</artifactId>
49-
<version>0.34.58</version>
49+
<version>0.34.60</version>
5050
</dependency>
5151
<dependency>
5252
<groupId>com.vladsch.flexmark</groupId>
5353
<artifactId>flexmark-ext-autolink</artifactId>
54-
<version>0.34.58</version>
54+
<version>0.34.60</version>
5555
</dependency>
5656
<dependency>
5757
<groupId>com.vladsch.flexmark</groupId>
5858
<artifactId>flexmark-ext-definition</artifactId>
59-
<version>0.34.58</version>
59+
<version>0.34.60</version>
6060
</dependency>
6161
<dependency>
6262
<groupId>com.vladsch.flexmark</groupId>
6363
<artifactId>flexmark-ext-emoji</artifactId>
64-
<version>0.34.58</version>
64+
<version>0.34.60</version>
6565
</dependency>
6666
<dependency>
6767
<groupId>com.vladsch.flexmark</groupId>
6868
<artifactId>flexmark-ext-enumerated-reference</artifactId>
69-
<version>0.34.58</version>
69+
<version>0.34.60</version>
7070
</dependency>
7171
<dependency>
7272
<groupId>com.vladsch.flexmark</groupId>
7373
<artifactId>flexmark-ext-escaped-character</artifactId>
74-
<version>0.34.58</version>
74+
<version>0.34.60</version>
7575
</dependency>
7676
<dependency>
7777
<groupId>com.vladsch.flexmark</groupId>
7878
<artifactId>flexmark-ext-footnotes</artifactId>
79-
<version>0.34.58</version>
79+
<version>0.34.60</version>
8080
</dependency>
8181
<dependency>
8282
<groupId>com.vladsch.flexmark</groupId>
8383
<artifactId>flexmark-ext-gfm-issues</artifactId>
84-
<version>0.34.58</version>
84+
<version>0.34.60</version>
8585
</dependency>
8686
<dependency>
8787
<groupId>com.vladsch.flexmark</groupId>
8888
<artifactId>flexmark-ext-gfm-strikethrough</artifactId>
89-
<version>0.34.58</version>
89+
<version>0.34.60</version>
9090
</dependency>
9191
<dependency>
9292
<groupId>com.vladsch.flexmark</groupId>
9393
<artifactId>flexmark-ext-gfm-tables</artifactId>
94-
<version>0.34.58</version>
94+
<version>0.34.60</version>
9595
</dependency>
9696
<dependency>
9797
<groupId>com.vladsch.flexmark</groupId>
9898
<artifactId>flexmark-ext-gfm-tasklist</artifactId>
99-
<version>0.34.58</version>
99+
<version>0.34.60</version>
100100
</dependency>
101101
<dependency>
102102
<groupId>com.vladsch.flexmark</groupId>
103103
<artifactId>flexmark-ext-gfm-users</artifactId>
104-
<version>0.34.58</version>
104+
<version>0.34.60</version>
105105
</dependency>
106106
<dependency>
107107
<groupId>com.vladsch.flexmark</groupId>
108108
<artifactId>flexmark-ext-gitlab</artifactId>
109-
<version>0.34.58</version>
109+
<version>0.34.60</version>
110110
</dependency>
111111
<dependency>
112112
<groupId>com.vladsch.flexmark</groupId>
113113
<artifactId>flexmark-ext-jekyll-front-matter</artifactId>
114-
<version>0.34.58</version>
114+
<version>0.34.60</version>
115115
</dependency>
116116
<dependency>
117117
<groupId>com.vladsch.flexmark</groupId>
118118
<artifactId>flexmark-ext-jekyll-tag</artifactId>
119-
<version>0.34.58</version>
119+
<version>0.34.60</version>
120120
</dependency>
121121
<dependency>
122122
<groupId>com.vladsch.flexmark</groupId>
123123
<artifactId>flexmark-ext-media-tags</artifactId>
124-
<version>0.34.58</version>
124+
<version>0.34.60</version>
125125
</dependency>
126126
<dependency>
127127
<groupId>com.vladsch.flexmark</groupId>
128128
<artifactId>flexmark-ext-macros</artifactId>
129-
<version>0.34.58</version>
129+
<version>0.34.60</version>
130130
</dependency>
131131
<dependency>
132132
<groupId>com.vladsch.flexmark</groupId>
133133
<artifactId>flexmark-ext-ins</artifactId>
134-
<version>0.34.58</version>
134+
<version>0.34.60</version>
135135
</dependency>
136136
<dependency>
137137
<groupId>com.vladsch.flexmark</groupId>
138138
<artifactId>flexmark-ext-xwiki-macros</artifactId>
139-
<version>0.34.58</version>
139+
<version>0.34.60</version>
140140
</dependency>
141141
<dependency>
142142
<groupId>com.vladsch.flexmark</groupId>
143143
<artifactId>flexmark-ext-superscript</artifactId>
144-
<version>0.34.58</version>
144+
<version>0.34.60</version>
145145
</dependency>
146146
<dependency>
147147
<groupId>com.vladsch.flexmark</groupId>
148148
<artifactId>flexmark-ext-tables</artifactId>
149-
<version>0.34.58</version>
149+
<version>0.34.60</version>
150150
</dependency>
151151
<dependency>
152152
<groupId>com.vladsch.flexmark</groupId>
153153
<artifactId>flexmark-ext-toc</artifactId>
154-
<version>0.34.58</version>
154+
<version>0.34.60</version>
155155
</dependency>
156156
<dependency>
157157
<groupId>com.vladsch.flexmark</groupId>
158158
<artifactId>flexmark-ext-typographic</artifactId>
159-
<version>0.34.58</version>
159+
<version>0.34.60</version>
160160
</dependency>
161161
<dependency>
162162
<groupId>com.vladsch.flexmark</groupId>
163163
<artifactId>flexmark-ext-wikilink</artifactId>
164-
<version>0.34.58</version>
164+
<version>0.34.60</version>
165165
</dependency>
166166
<dependency>
167167
<groupId>com.vladsch.flexmark</groupId>
168168
<artifactId>flexmark-ext-yaml-front-matter</artifactId>
169-
<version>0.34.58</version>
169+
<version>0.34.60</version>
170170
</dependency>
171171
<dependency>
172172
<groupId>com.vladsch.flexmark</groupId>
173173
<artifactId>flexmark-ext-youtube-embedded</artifactId>
174-
<version>0.34.58</version>
174+
<version>0.34.60</version>
175175
</dependency>
176176
<dependency>
177177
<groupId>com.vladsch.flexmark</groupId>
178178
<artifactId>flexmark-formatter</artifactId>
179-
<version>0.34.58</version>
179+
<version>0.34.60</version>
180180
</dependency>
181181
<dependency>
182182
<groupId>com.vladsch.flexmark</groupId>
183183
<artifactId>flexmark-html-parser</artifactId>
184-
<version>0.34.58</version>
184+
<version>0.34.60</version>
185185
</dependency>
186186
<dependency>
187187
<groupId>com.vladsch.flexmark</groupId>
188188
<artifactId>flexmark-jira-converter</artifactId>
189-
<version>0.34.58</version>
189+
<version>0.34.60</version>
190190
</dependency>
191191
<dependency>
192192
<groupId>com.vladsch.flexmark</groupId>
193193
<artifactId>flexmark-pdf-converter</artifactId>
194-
<version>0.34.58</version>
194+
<version>0.34.60</version>
195195
</dependency>
196196
<dependency>
197197
<groupId>com.vladsch.flexmark</groupId>
198198
<artifactId>flexmark-profile-pegdown</artifactId>
199-
<version>0.34.58</version>
199+
<version>0.34.60</version>
200200
</dependency>
201201
<dependency>
202202
<groupId>com.vladsch.flexmark</groupId>
203203
<artifactId>flexmark-util</artifactId>
204-
<version>0.34.58</version>
204+
<version>0.34.60</version>
205205
</dependency>
206206
<dependency>
207207
<groupId>com.vladsch.flexmark</groupId>
208208
<artifactId>flexmark-youtrack-converter</artifactId>
209-
<version>0.34.58</version>
209+
<version>0.34.60</version>
210210
</dependency>
211211
</dependencies>
212212

flexmark-docx-converter/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<groupId>com.vladsch.flexmark</groupId>
77
<artifactId>flexmark-java</artifactId>
8-
<version>0.34.58</version>
8+
<version>0.34.60</version>
99
</parent>
1010

1111
<artifactId>flexmark-docx-converter</artifactId>

flexmark-docx-converter/src/main/java/com/vladsch/flexmark/docx/converter/internal/CoreNodeDocxRenderer.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
import com.vladsch.flexmark.ext.enumerated.reference.EnumeratedReferenceLink;
2121
import com.vladsch.flexmark.ext.enumerated.reference.EnumeratedReferenceText;
2222
import com.vladsch.flexmark.ext.enumerated.reference.internal.EnumRefTextCollectingVisitor;
23+
import com.vladsch.flexmark.ext.enumerated.reference.internal.EnumeratedReferenceRepository;
2324
import com.vladsch.flexmark.ext.enumerated.reference.internal.EnumeratedReferences;
2425
import com.vladsch.flexmark.ext.footnotes.Footnote;
2526
import com.vladsch.flexmark.ext.footnotes.FootnoteBlock;
@@ -1729,7 +1730,7 @@ private void render(EnumeratedReferenceLink node, final DocxRendererContext docx
17291730
int wasOrdinal = ordinal;
17301731
ordinal = enumeratedOrdinals.getOrdinal(text);
17311732

1732-
final String defaultText = String.format("%s %d", EnumeratedReferences.getType(text), ordinal);
1733+
final String defaultText = String.format("%s %d", EnumeratedReferenceRepository.getType(text), ordinal);
17331734
String title = referenceFormat != null ? new EnumRefTextCollectingVisitor(ordinal).collectAndGetText(referenceFormat) : defaultText;
17341735
Attributes attributes = new Attributes();
17351736

flexmark-docx-converter/src/main/java/com/vladsch/flexmark/docx/converter/internal/DocxRenderer.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,11 @@ public NodeDocxRenderer create(DataHolder options) {
176176
this.linkResolverFactories = FlatDependencyHandler.computeDependencies(builder.linkResolverFactories);
177177
}
178178

179+
@Override
180+
public DataHolder getOptions() {
181+
return new DataSet(builder);
182+
}
183+
179184
/**
180185
* Create a new builder for configuring the DocxRenderer.
181186
*

0 commit comments

Comments
 (0)