public class Markup extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
CSS_KEY_COLOR
the CSS tag for text color
|
static String |
CSS_KEY_FONTFAMILY
the CSS tag for the font family
|
static String |
CSS_KEY_FONTSIZE
the CSS tag for the font size
|
static String |
CSS_KEY_FONTSTYLE
the CSS tag for the font style
|
static String |
CSS_KEY_FONTWEIGHT
the CSS tag for the font weight
|
static String |
CSS_KEY_LINEHEIGHT
the CSS tag for text decorations
|
static String |
CSS_KEY_VERTICALALIGN
the CSS tag for text decorations
|
static String |
CSS_VALUE_BOLD
a CSS value for text font weight
|
static String |
CSS_VALUE_ITALIC
a CSS value for text font style
|
static String |
CSS_VALUE_LINETHROUGH
a CSS value for text decoration
|
static String |
CSS_VALUE_NORMAL
a CSS value
|
static String |
CSS_VALUE_OBLIQUE
a CSS value for text font style
|
static String |
CSS_VALUE_UNDERLINE
a CSS value for text decoration
|
static float |
DEFAULT_FONT_SIZE
a default value for font-size
|
static String |
HTML_ATTR_STYLE
This is used for inline css style information
|
| Constructor and Description |
|---|
Markup() |
| Modifier and Type | Method and Description |
|---|---|
static Color |
decodeColor(String s)
Converts a
Color into a HTML representation of this
Color. |
static Properties |
parseAttributes(String string)
This method parses a String with attributes and returns a Properties
object.
|
static float |
parseLength(String string)
Parses a length.
|
static float |
parseLength(String string,
float actualFontSize)
New method contributed by: Lubos Strapko
|
public static final String HTML_ATTR_STYLE
public static final String CSS_KEY_COLOR
public static final String CSS_KEY_FONTFAMILY
public static final String CSS_KEY_FONTSIZE
public static final String CSS_KEY_FONTSTYLE
public static final String CSS_KEY_FONTWEIGHT
public static final String CSS_KEY_LINEHEIGHT
public static final String CSS_KEY_VERTICALALIGN
public static final String CSS_VALUE_BOLD
public static final String CSS_VALUE_ITALIC
public static final String CSS_VALUE_LINETHROUGH
public static final String CSS_VALUE_NORMAL
public static final String CSS_VALUE_OBLIQUE
public static final String CSS_VALUE_UNDERLINE
public static final float DEFAULT_FONT_SIZE
public static float parseLength(String string)
string - a length in the form of an optional + or -, followed by a
number and a unit.public static float parseLength(String string, float actualFontSize)
string - StringactualFontSize - Actual Font Sizepublic static Color decodeColor(String s)
Color into a HTML representation of this
Color.s - the Color that has to be converted.Colorpublic static Properties parseAttributes(String string)
string - a String of this form: 'key1="value1"; key2="value2";...
keyN="valueN" 'Copyright © 2021. All rights reserved.