aboutsummaryrefslogtreecommitdiff
path: root/src/test/java/org/zwobble/mammoth/tests/documents/DocumentElementMakers.java
diff options
context:
space:
mode:
authorMichael Williamson <mike@zwobble.org>2016-02-14 11:19:05 +0000
committerMichael Williamson <mike@zwobble.org>2016-02-14 11:19:05 +0000
commitae5ded5955978970cbe992fd41628eb2cb3d4b23 (patch)
tree5e83172ef682613c5f3ba2f2b22f073aecec6bb6 /src/test/java/org/zwobble/mammoth/tests/documents/DocumentElementMakers.java
parent2ffae2608b8634c11a02924d3342d6e8cc6c02fe (diff)
Wrap bold runs in <strong>
Diffstat (limited to 'src/test/java/org/zwobble/mammoth/tests/documents/DocumentElementMakers.java')
-rw-r--r--src/test/java/org/zwobble/mammoth/tests/documents/DocumentElementMakers.java12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/test/java/org/zwobble/mammoth/tests/documents/DocumentElementMakers.java b/src/test/java/org/zwobble/mammoth/tests/documents/DocumentElementMakers.java
index 396a95a..6e9409f 100644
--- a/src/test/java/org/zwobble/mammoth/tests/documents/DocumentElementMakers.java
+++ b/src/test/java/org/zwobble/mammoth/tests/documents/DocumentElementMakers.java
@@ -14,6 +14,10 @@ import static com.natpryce.makeiteasy.Property.newProperty;
import static org.zwobble.mammoth.util.MammothLists.list;
public class DocumentElementMakers {
+ public static final Property<HasChildren, Boolean> BOLD = newProperty();
+ public static final Property<HasChildren, Boolean> ITALIC = newProperty();
+ public static final Property<HasChildren, Boolean> UNDERLINE = newProperty();
+ public static final Property<HasChildren, Boolean> STRIKETHROUGH = newProperty();
public static final Property<HasChildren, List<DocumentElement>> CHILDREN = newProperty();
public static final Instantiator<Paragraph> PARAGRAPH =
@@ -24,10 +28,10 @@ public class DocumentElementMakers {
public static final Instantiator<Run> RUN =
propertyLookup -> new Run(
- false,
- false,
- false,
- false,
+ propertyLookup.valueOf(BOLD, false),
+ propertyLookup.valueOf(ITALIC, false),
+ propertyLookup.valueOf(UNDERLINE, false),
+ propertyLookup.valueOf(STRIKETHROUGH, false),
VerticalAlignment.BASELINE,
Optional.empty(),
propertyLookup.valueOf(CHILDREN, list()));