java.lang.Object
org.jhotdraw8.css.converter.AbstractCssConverter<CssFont>
org.jhotdraw8.draw.css.converter.FontCssConverter
- All Implemented Interfaces:
org.jhotdraw8.base.converter.Converter<CssFont>,CssConverter<CssFont>
CssFontConverter.
Parses the following EBNF from the JavaFX CSS Reference Guide.
CssFont := [FontStyle] [FontWeight] FontSize FontFamily ; FontStyle := normal|italic|oblique; FontWeight := normal|bold|bolder|lighter|100|200|300|400|500|600|700|800|900; FontSize := Size; FontFamily := Word|Quoted;
- Author:
- Werner Randelshofer
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription@Nullable StringparseNonNull(CssTokenizer tt, @Nullable org.jhotdraw8.base.converter.IdResolver idResolver) <TT extends CssFont>
voidproduceTokensNonNull(TT font, @Nullable org.jhotdraw8.base.converter.IdSupplier idSupplier, Consumer<CssToken> out) Methods inherited from class org.jhotdraw8.css.converter.AbstractCssConverter
getDefaultValue, isNullable, parse, produceTokensMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.jhotdraw8.base.converter.Converter
fromString, fromString, fromStringNonNull, fromStringNonNull, fromStringNonNull, fromStringNonNull, needsIdResolver, toString, toStringMethods inherited from interface org.jhotdraw8.css.converter.CssConverter
fromString, fromString, getExamples, toString, toString, toString, toTokens
-
Field Details
-
ITALIC_STYLE
- See Also:
-
BOLD_WEIGHT
- See Also:
-
NORMAL_STYLE
- See Also:
-
NORMAL_WEIGHT
- See Also:
-
OBLIQUE_STYLE
- See Also:
-
BOLDER_WEIGHT
- See Also:
-
LIGHTER_WEIGHT
- See Also:
-
-
Constructor Details
-
FontCssConverter
public FontCssConverter(boolean nullable)
-
-
Method Details
-
produceTokensNonNull
public <TT extends CssFont> void produceTokensNonNull(TT font, @Nullable org.jhotdraw8.base.converter.IdSupplier idSupplier, Consumer<CssToken> out) - Specified by:
produceTokensNonNullin classAbstractCssConverter<CssFont>
-
parseNonNull
public CssFont parseNonNull(CssTokenizer tt, @Nullable org.jhotdraw8.base.converter.IdResolver idResolver) throws ParseException, IOException - Specified by:
parseNonNullin interfaceCssConverter<CssFont>- Specified by:
parseNonNullin classAbstractCssConverter<CssFont>- Throws:
ParseExceptionIOException
-
getHelpText
-