summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Atkins <atkinssj@serenityos.org>2022-05-05 17:48:24 +0100
committerAndreas Kling <kling@serenityos.org>2022-05-21 22:25:33 +0200
commit0ef3c15822aaf0e8319100860ad5ea4b52ae0122 (patch)
tree56cb67aaf8da12a7721eed22ff93037f52f381d7
parent8915b3227c370997e1fb8a27b14e777eff1cedc4 (diff)
downloadserenity-0ef3c15822aaf0e8319100860ad5ea4b52ae0122.zip
ThemeEditor: Actually save alignment roles
-rw-r--r--Userland/Applications/ThemeEditor/MainWidget.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/Userland/Applications/ThemeEditor/MainWidget.cpp b/Userland/Applications/ThemeEditor/MainWidget.cpp
index 4e613e13f2..f4966662cc 100644
--- a/Userland/Applications/ThemeEditor/MainWidget.cpp
+++ b/Userland/Applications/ThemeEditor/MainWidget.cpp
@@ -392,6 +392,11 @@ void MainWidget::set_path(String path)
void MainWidget::save_to_file(Core::File& file)
{
auto theme = Core::ConfigFile::open(file.filename(), file.leak_fd()).release_value_but_fixme_should_propagate_errors();
+
+ for (auto role : m_alignment_roles) {
+ theme->write_entry("Alignments", to_string(role), to_string(m_preview_widget->preview_palette().alignment(role)));
+ }
+
for (auto role : m_color_roles) {
theme->write_entry("Colors", to_string(role), m_preview_widget->preview_palette().color(role).to_string());
}