https://www.w3.org/TR/SVG11/types.html#DataTypeColor
| 253 | |
| 254 | // https://www.w3.org/TR/SVG11/types.html#DataTypeColor |
| 255 | bool SVGAttributeParser::parseNamedColorToken(Color* c) { |
| 256 | RestoreCurPos restoreCurPos(this); |
| 257 | |
| 258 | std::string ident; |
| 259 | if (!this->parseIdentToken(&ident)) { |
| 260 | return false; |
| 261 | } |
| 262 | if (!SVGParse::FindNamedColor(ident.c_str(), c)) { |
| 263 | return false; |
| 264 | } |
| 265 | |
| 266 | restoreCurPos.clear(); |
| 267 | return true; |
| 268 | } |
| 269 | |
| 270 | bool SVGAttributeParser::parseHexColorToken(Color* c) { |
| 271 | RestoreCurPos restoreCurPos(this); |
no test coverage detected