added preference for effect textbox size

This commit is contained in:
itsmattkc
2019-01-17 23:38:42 +11:00
parent 96043aa8c5
commit 9143561bb4
5 changed files with 39 additions and 14 deletions
+12 -7
View File
@@ -46,7 +46,8 @@ Config::Config()
upcoming_queue_type(FRAME_QUEUE_TYPE_SECONDS),
loop(true),
pause_at_out_point(true),
seek_also_selects(false)
seek_also_selects(false),
effect_textbox_lines(3)
{}
void Config::load(QString path) {
@@ -162,10 +163,13 @@ void Config::load(QString path) {
} else if (stream.name() == "SeekAlsoSelects") {
stream.readNext();
seek_also_selects = (stream.text() == "1");
} else if (stream.name() == "CSSPath") {
stream.readNext();
css_path = stream.text().toString();
}
} else if (stream.name() == "CSSPath") {
stream.readNext();
css_path = stream.text().toString();
} else if (stream.name() == "EffectTextboxLines") {
stream.readNext();
effect_textbox_lines = stream.text().toInt();
}
}
}
if (stream.hasError()) {
@@ -223,8 +227,9 @@ void Config::save(QString path) {
stream.writeTextElement("UpcomingFrameQueueType", QString::number(upcoming_queue_type));
stream.writeTextElement("Loop", QString::number(loop));
stream.writeTextElement("PauseAtOutPoint", QString::number(pause_at_out_point));
stream.writeTextElement("SeekAlsoSelects", QString::number(seek_also_selects));
stream.writeTextElement("CSSPath", css_path);
stream.writeTextElement("SeekAlsoSelects", QString::number(seek_also_selects));
stream.writeTextElement("CSSPath", css_path);
stream.writeTextElement("EffectTextboxLines", QString::number(effect_textbox_lines));
stream.writeEndElement(); // configuration
stream.writeEndDocument(); // doc