A DESCRIPTION OF THE PROBLEM :
Blend modes "add", "red", "green" and "blue" cannot be set via CSS (-fx-blend-mode: red) I assume because they get parsed as colors and not blend mode enum values. (add becomes 0xaadddd most likely?)
Warning that gets logged:
```
Sep 29, 2021 10:13:55 AM javafx.scene.CssStyleHelper calculateValue
WARNING: Caught 'java.lang.ClassCastException: class javafx.scene.paint.Color cannot be cast to class java.lang.String (javafx.scene.paint.Color is in module javafx.graphics@11.0.12 of loader 'platform'; java.lang.String is in module java.base of loader 'bootstrap')' while converting value for '-fx-blend-mode' from inline style on Label@1b4e2356[styleClass=label rainbow blend-test]'add'
```
Additionally, `src-atop` and all the other `src-*` blend modes referenced in the documentation here seemingly cannot be set at all: https://openjfx.io/javadoc/11/javafx.graphics/javafx/scene/doc-files/cssref.html
In the source code the blend modes `src-*` are only referenced in the documentation based on this search: https://github.com/openjdk/jfx/search?q=src-atop (Maybe it should just be removed?)
Blend modes "add", "red", "green" and "blue" cannot be set via CSS (-fx-blend-mode: red) I assume because they get parsed as colors and not blend mode enum values. (add becomes 0xaadddd most likely?)
Warning that gets logged:
```
Sep 29, 2021 10:13:55 AM javafx.scene.CssStyleHelper calculateValue
WARNING: Caught 'java.lang.ClassCastException: class javafx.scene.paint.Color cannot be cast to class java.lang.String (javafx.scene.paint.Color is in module javafx.graphics@11.0.12 of loader 'platform'; java.lang.String is in module java.base of loader 'bootstrap')' while converting value for '-fx-blend-mode' from inline style on Label@1b4e2356[styleClass=label rainbow blend-test]'add'
```
Additionally, `src-atop` and all the other `src-*` blend modes referenced in the documentation here seemingly cannot be set at all: https://openjfx.io/javadoc/11/javafx.graphics/javafx/scene/doc-files/cssref.html
In the source code the blend modes `src-*` are only referenced in the documentation based on this search: https://github.com/openjdk/jfx/search?q=src-atop (Maybe it should just be removed?)
- duplicates
-
JDK-8088385 On using add,green,blue,red values for blend mode through css, getting invalid class cast exception
- Closed
- relates to
-
JDK-8268657 Looked-up color fails for -fx-background-color in JavaFX CSS file
- Open
-
JDK-8276180 Eliminate special case code for certain CSS attributes
- Open