23 #include "customparamspanel.h" 24 #include "ui_customparamspanel.h" 28 #include "serverapi/gamecreateparams.h" 30 DClass<CustomParamsPanel> :
public Ui::CustomParamsPanel
42 CustomParamsPanel::~CustomParamsPanel()
48 QString customParams = d->paramsArea->toPlainText();
49 QByteArray utf8 = customParams.toUtf8();
50 Scanner sc(utf8.constData(), utf8.length());
51 while (sc.nextString())
53 params.customParameters() << sc->str();
57 void CustomParamsPanel::loadConfig(
Ini &config)
60 d->paramsArea->document()->setPlainText(misc[
"CustomParams"]);
63 void CustomParamsPanel::saveConfig(
Ini &config)
66 misc[
"CustomParams"] = d->paramsArea->toPlainText();
Game parametrization data used when creating new games.
INI section representation.
IniSection section(const QString &name)
Access configuration file section.
Scanner reads scripts by checking individual tokens.