12#include <kconfiggroup.h>
13#include <ksharedconfig.h>
81 qFatal(
"Unsupported mode");
84 return QString(
"LiquifyTool/%1").arg(result);
92 cfg.writeEntry(
"size",
m_size);
99 cfg.writeEntry(
"flow",
m_flow);
101 KConfigGroup globalCfg = KSharedConfig::openConfig()->group(
"LiquifyTool");
102 globalCfg.writeEntry(
"mode", (
int)
m_mode);
122 KConfigGroup globalCfg = KSharedConfig::openConfig()->group(
"LiquifyTool");
130 QDomDocument doc = e->ownerDocument();
131 QDomElement liqEl = doc.createElement(
"liquify_properties");
132 e->appendChild(liqEl);
166 if (result && newMode >= 0 && newMode <
N_MODES) {
178 dbg.nospace() <<
"\nKisLiquifyProperties(";
179 dbg.space() <<
"\n " <<
ppVar(props.
mode());
180 dbg.space() <<
"\n " <<
ppVar(props.
size());
187 dbg.space() <<
"\n " <<
ppVar(props.
flow());
188 dbg.space() <<
"\n );\n";
189 return dbg.nospace();
bool operator==(const KisLiquifyProperties &other) const
bool reverseDirection() const
bool sizeHasPressure() const
static KisLiquifyProperties fromXML(const QDomElement &e)
KisLiquifyProperties & operator=(const KisLiquifyProperties &rhs)
bool amountHasPressure() const
void toXML(QDomElement *e) const
QDebug operator<<(QDebug dbg, const KisLiquifyProperties &props)
QString liquifyModeString(KisLiquifyProperties::LiquifyMode mode)
void saveValue(QDomElement *parent, const QString &tag, const QSize &size)
bool findOnlyElement(const QDomElement &parent, const QString &tag, QDomElement *el, QStringList *errorMessages)
bool loadValue(const QDomElement &e, float *v)