Changeset View
Changeset View
Standalone View
Standalone View
libs/image/kis_properties_configuration.cc
Show First 20 Lines • Show All 249 Lines • ▼ Show 20 Line(s) | 249 | { | |||
---|---|---|---|---|---|
250 | QVariant v = getProperty(name); | 250 | QVariant v = getProperty(name); | ||
251 | if (v.isValid()) { | 251 | if (v.isValid()) { | ||
252 | if (v.type() == QVariant::UserType && v.userType() == qMetaTypeId<KoColor>()) { | 252 | if (v.type() == QVariant::UserType && v.userType() == qMetaTypeId<KoColor>()) { | ||
253 | return v.value<KoColor>(); | 253 | return v.value<KoColor>(); | ||
254 | } else { | 254 | } else { | ||
255 | QDomDocument doc; | 255 | QDomDocument doc; | ||
256 | doc.setContent(v.toString()); | 256 | doc.setContent(v.toString()); | ||
257 | QDomElement e = doc.documentElement().firstChild().toElement(); | 257 | QDomElement e = doc.documentElement().firstChild().toElement(); | ||
258 | return KoColor::fromXML(e, Integer16BitsColorDepthID.id(), QHash<QString, QString>()); | 258 | return KoColor::fromXML(e, Integer16BitsColorDepthID.id()); | ||
259 | } | 259 | } | ||
260 | } else { | 260 | } else { | ||
261 | return color; | 261 | return color; | ||
262 | } | 262 | } | ||
263 | } | 263 | } | ||
264 | 264 | | |||
265 | void KisPropertiesConfiguration::dump() const | 265 | void KisPropertiesConfiguration::dump() const | ||
266 | { | 266 | { | ||
▲ Show 20 Lines • Show All 53 Lines • Show Last 20 Lines |