From d31f83e0987fbf7fb358d0fef9357f4ad7ed35e6 Mon Sep 17 00:00:00 2001 From: David Capello Date: Fri, 8 May 2015 16:08:55 -0300 Subject: [PATCH] Add option to load/save default palette preset (fix #626) Now the default palette is saved in the user configuration directory, so we can set any palette as the default (it doesn't matter if it's related or not to a file, it will be copied into the user directory anyway). --- data/gui.xml | 11 +++++-- data/widgets/palette_popup.xml | 1 - src/app/app.cpp | 34 ++++++++++++-------- src/app/commands/cmd_load_palette.cpp | 24 +++++++++++--- src/app/commands/cmd_save_palette.cpp | 46 ++++++++++++++++++++------- src/app/commands/cmd_set_palette.cpp | 32 ++++--------------- src/app/commands/cmd_set_palette.h | 6 ++-- src/app/document_api.cpp | 2 +- src/app/document_api.h | 2 +- src/app/file/palette_file.cpp | 2 +- src/app/file/palette_file.h | 2 +- src/app/modules/palettes.cpp | 25 +++++++++++++-- src/app/modules/palettes.h | 7 +++- src/app/ui/palette_popup.cpp | 14 ++------ src/app/ui/palette_popup.h | 2 +- 15 files changed, 130 insertions(+), 80 deletions(-) diff --git a/data/gui.xml b/data/gui.xml index 8b2a3a22a..3c2c4a17f 100644 --- a/data/gui.xml +++ b/data/gui.xml @@ -736,8 +736,15 @@ - - + + + + + + + + + diff --git a/data/widgets/palette_popup.xml b/data/widgets/palette_popup.xml index e8e6a0653..2c2d2b5f9 100644 --- a/data/widgets/palette_popup.xml +++ b/data/widgets/palette_popup.xml @@ -7,7 +7,6 @@