Module io.sf.carte.css4j
Package io.sf.carte.doc.style.css.om
Class RGBColorDeclarationFormattingContext
java.lang.Object
io.sf.carte.doc.style.css.om.DefaultDeclarationFormattingContext
io.sf.carte.doc.style.css.om.ColorDeclarationFormattingContext
io.sf.carte.doc.style.css.om.RGBColorDeclarationFormattingContext
- All Implemented Interfaces:
DeclarationFormattingContext
,Serializable
DeclarationFormattingContext that serializes colors as RGB (sRGB).
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected void
writeColor
(SimpleWriter wri, String propertyName, CSSColorValue value) Write a cssCOLOR
to the given writer.protected void
writeColorMix
(SimpleWriter wri, String propertyName, CSSColorMixFunction value) Write a cssCOLOR_MIX
to the given writer.protected void
writeMinifiedColor
(SimpleWriter wri, String propertyName, CSSColorValue value) Write a minified cssCOLOR
value to the given writer.protected void
writeMinifiedColorMix
(SimpleWriter wri, String propertyName, CSSColorMixFunction value) Write a minified cssCOLOR_MIX
value to the given writer.Methods inherited from class io.sf.carte.doc.style.css.om.ColorDeclarationFormattingContext
writeMinifiedValue, writeValue
Methods inherited from class io.sf.carte.doc.style.css.om.DefaultDeclarationFormattingContext
endPropertyDeclaration, startPropertyDeclaration, writeColon, writeComma, writeFullIndent, writeSemiColon, writeURL
-
Constructor Details
-
RGBColorDeclarationFormattingContext
public RGBColorDeclarationFormattingContext()
-
-
Method Details
-
writeColor
protected void writeColor(SimpleWriter wri, String propertyName, CSSColorValue value) throws IOException Write a cssCOLOR
to the given writer.- Overrides:
writeColor
in classColorDeclarationFormattingContext
- Parameters:
wri
- the writer.propertyName
- the name of the property whose value is being printed.value
- the value to write.- Throws:
IOException
- if an error happened while writing.
-
writeColorMix
protected void writeColorMix(SimpleWriter wri, String propertyName, CSSColorMixFunction value) throws IOException Write a cssCOLOR_MIX
to the given writer.- Overrides:
writeColorMix
in classColorDeclarationFormattingContext
- Parameters:
wri
- the writer.propertyName
- the name of the property whose value is being printed.value
- the value to write.- Throws:
IOException
- if an error happened while writing.
-
writeMinifiedColor
protected void writeMinifiedColor(SimpleWriter wri, String propertyName, CSSColorValue value) throws IOException Write a minified cssCOLOR
value to the given writer.- Overrides:
writeMinifiedColor
in classColorDeclarationFormattingContext
- Parameters:
wri
- the writer.propertyName
- the name of the property whose value is being printed.value
- the value to write.- Throws:
IOException
- if an error happened while writing.
-
writeMinifiedColorMix
protected void writeMinifiedColorMix(SimpleWriter wri, String propertyName, CSSColorMixFunction value) throws IOException Write a minified cssCOLOR_MIX
value to the given writer.- Overrides:
writeMinifiedColorMix
in classColorDeclarationFormattingContext
- Parameters:
wri
- the writer.propertyName
- the name of the property whose value is being printed.value
- the value to write.- Throws:
IOException
- if an error happened while writing.
-