font-variant: small-caps (renderers emulate via scaled capitals)
font-family: monospace
null to use the renderer default
#ff0000, orange), or null for the default
<mark>), or null for none
null means this run is a hyperlink
Parsers resolve inheritance and resets while walking the DOM (e.g. <span style="font-style: normal">
inside <i> yields italic = false), so instances always carry final values and renderers
never need to consult ancestors.
| Modifier and Type | Class and Description |
|---|---|
| public static enum | InlineStyle.
Vertical placement of a run relative to the baseline. |
| Modifier and Type | Field and Description |
|---|---|
| private final @Nullable String | background
Record Component accessed by background(). CSS background color string (e.g. from<mark>), or null for none
|
| private final @Nullable String | |
| public static final InlineStyle | DEFAULT
The style of unmarked body text: weight 400, base size, no decorations, default fonts and colors. |
| private final @Nullable String | fontFamily
Record Component accessed by fontFamily(). explicit font family, ornull to use the renderer default
|
| private final double | fontScale
Record Component accessed by fontScale(). font size relative to the renderer's base size; 1.0 = base |
| private final int | fontWeight
Record Component accessed by fontWeight(). CSS font weight, 100–900; 400 is normal, 700 is bold |
| private final @Nullable String | |
| private final boolean | |
| private final boolean | |
| private final boolean | smallCaps
Record Component accessed by smallCaps(). font-variant: small-caps (renderers emulate via scaled capitals)
|
| private final boolean | strikethrough
Record Component accessed by strikethrough(). struck-through text |
| private final boolean | underline
Record Component accessed by underline(). underlined text |
| private final InlineStyle. | verticalPosition
Record Component accessed by verticalPosition(). subscript/superscript placement |
| Access | Constructor and Description |
|---|---|
| public | InlineStyle(int fontWeight, boolean italic, boolean underline, boolean strikethrough, boolean smallCaps, boolean monospace, InlineStyle.
|
| Modifier and Type | Method and Description |
|---|---|
| public @Nullable String | background()
Record Component getter of background.
Record Component
CSS background color string (e.g. from |
| public boolean | |
| public @Nullable String | |
| public final boolean | equals(Object o)
Implements abstract java. Indicates whether some other object is "equal to" this one. |
| public @Nullable String | fontFamily()
Record Component getter of fontFamily.
Record Component
explicit font family, or |
| public double | |
| public int | fontWeight()
Record Component getter of fontWeight.
Record Component CSS font weight, 100–900; 400 is normal, 700 is bold |
| public final int | |
| public @Nullable String | |
| public boolean | |
| public boolean | |
| public boolean | |
| public boolean | |
| public boolean | |
| public final String | toString()
Implements abstract java. Returns a string representation of the record. |
| public boolean | |
| public InlineStyle. | verticalPosition()
Record Component getter of verticalPosition.
Record Component subscript/superscript placement |
| public InlineStyle | |
| public InlineStyle | |
| public InlineStyle | |
| public InlineStyle | |
| public InlineStyle | |
| public InlineStyle | |
| public InlineStyle | |
| public InlineStyle | |
| public InlineStyle | |
| public InlineStyle | |
| public InlineStyle | |
| public InlineStyle |
| background | back to summary |
|---|---|
| private final @Nullable String background Record Component accessed by background(). CSS background color string (e.g. from | |
| color | back to summary |
|---|---|
| private final @Nullable String color Record Component accessed by color(). CSS color string (e.g. | |
| DEFAULT | back to summary |
|---|---|
| public static final InlineStyle DEFAULT The style of unmarked body text: weight 400, base size, no decorations, default fonts and colors. | |
| fontFamily | back to summary |
|---|---|
| private final @Nullable String fontFamily Record Component accessed by fontFamily(). explicit font family, or | |
| fontScale | back to summary |
|---|---|
| private final double fontScale Record Component accessed by fontScale(). font size relative to the renderer's base size; 1.0 = base | |
| fontWeight | back to summary |
|---|---|
| private final int fontWeight Record Component accessed by fontWeight(). CSS font weight, 100–900; 400 is normal, 700 is bold | |
| href | back to summary |
|---|---|
| private final @Nullable String href Record Component accessed by href(). link target; non- | |
| italic | back to summary |
|---|---|
| private final boolean italic Record Component accessed by italic(). italic or oblique | |
| monospace | back to summary |
|---|---|
| private final boolean monospace Record Component accessed by monospace(). code/tt/kbd/samp or | |
| smallCaps | back to summary |
|---|---|
| private final boolean smallCaps Record Component accessed by smallCaps().
| |
| strikethrough | back to summary |
|---|---|
| private final boolean strikethrough Record Component accessed by strikethrough(). struck-through text | |
| underline | back to summary |
|---|---|
| private final boolean underline Record Component accessed by underline(). underlined text | |
| verticalPosition | back to summary |
|---|---|
| private final InlineStyle. Record Component accessed by verticalPosition(). subscript/superscript placement | |
| InlineStyle | back to summary |
|---|---|
| public InlineStyle(int fontWeight, boolean italic, boolean underline, boolean strikethrough, boolean smallCaps, boolean monospace, InlineStyle. | |
| background | back to summary |
|---|---|
| public @Nullable String background() Record Component getter of background.
| |
| bold | back to summary |
|---|---|
public boolean bold()
| |
| color | back to summary |
|---|---|
| public @Nullable String color() Record Component getter of color.
| |
| equals | back to summary |
|---|---|
| public final boolean equals(Object o) Implements abstract java. Doc from java. Indicates whether some other object is "equal to" this one. In addition
to the general contract of
R copy = new R(r.c1(), r.c2(), ..., r.cn());
then it must be the case that r.equals(copy).
| |
| fontFamily | back to summary |
|---|---|
| public @Nullable String fontFamily() Record Component getter of fontFamily.
| |
| fontScale | back to summary |
|---|---|
| public double fontScale() Record Component getter of fontScale.
| |
| fontWeight | back to summary |
|---|---|
| public int fontWeight() Record Component getter of fontWeight.
| |
| hashCode | back to summary |
|---|---|
| public final int hashCode() Implements abstract java. Doc from java. Returns a hash code value for the record.
Obeys the general contract of | |
| href | back to summary |
|---|---|
| public @Nullable String href() Record Component getter of href.
| |
| italic | back to summary |
|---|---|
| public boolean italic() Record Component getter of italic.
| |
| link | back to summary |
|---|---|
public boolean link()
| |
| monospace | back to summary |
|---|---|
| public boolean monospace() Record Component getter of monospace.
| |
| smallCaps | back to summary |
|---|---|
| public boolean smallCaps() Record Component getter of smallCaps.
| |
| strikethrough | back to summary |
|---|---|
| public boolean strikethrough() Record Component getter of strikethrough.
| |
| toString | back to summary |
|---|---|
| public final String toString() Implements abstract java. Doc from java. Returns a string representation of the record.
In accordance with the general contract of In addition to this general contract, record classes must further participate in the invariant that any two records which are equal must produce equal strings. This invariant is necessarily relaxed in the rare case where corresponding equal component values might fail to produce equal strings for themselves. | |
| underline | back to summary |
|---|---|
| public boolean underline() Record Component getter of underline.
| |
| verticalPosition | back to summary |
|---|---|
| public InlineStyle. Record Component getter of verticalPosition.
| |
| withBackground | back to summary |
|---|---|
| public InlineStyle withBackground(@Nullable String newBackground) | |
| withColor | back to summary |
|---|---|
| public InlineStyle withColor(@Nullable String newColor) | |
| withFontFamily | back to summary |
|---|---|
| public InlineStyle withFontFamily(@Nullable String newFontFamily) | |
| withFontScale | back to summary |
|---|---|
| public InlineStyle withFontScale(double newFontScale) | |
| withFontWeight | back to summary |
|---|---|
| public InlineStyle withFontWeight(int newFontWeight) | |
| withHref | back to summary |
|---|---|
| public InlineStyle withHref(@Nullable String newHref) | |
| withItalic | back to summary |
|---|---|
| public InlineStyle withItalic(boolean newItalic) | |
| withMonospace | back to summary |
|---|---|
| public InlineStyle withMonospace(boolean newMonospace) | |
| withSmallCaps | back to summary |
|---|---|
| public InlineStyle withSmallCaps(boolean newSmallCaps) | |
| withStrikethrough | back to summary |
|---|---|
| public InlineStyle withStrikethrough(boolean newStrikethrough) | |
| withUnderline | back to summary |
|---|---|
| public InlineStyle withUnderline(boolean newUnderline) | |
| withVerticalPosition | back to summary |
|---|---|
| public InlineStyle withVerticalPosition(InlineStyle. | |
| Modifier and Type | Field and Description |
|---|---|
| public static final InlineStyle. | NORMAL
On the baseline. |
| public static final InlineStyle. | SUB
Subscript ( |
| public static final InlineStyle. | SUPER
Superscript ( |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static InlineStyle. | |
| public static InlineStyle. |
| NORMAL | back to summary |
|---|---|
| public static final InlineStyle. On the baseline. | |
| SUB | back to summary |
|---|---|
| public static final InlineStyle. Subscript ( | |
| SUPER | back to summary |
|---|---|
| public static final InlineStyle. Superscript ( | |
| VerticalPosition | back to summary |
|---|---|
| private VerticalPosition() | |
| valueOf | back to summary |
|---|---|
| public static InlineStyle. | |
| values | back to summary |
|---|---|
| public static InlineStyle. | |