2013-03-15 13:11:33 +00:00
|
|
|
namespace phoenix {
|
|
|
|
|
2013-05-02 11:25:45 +00:00
|
|
|
static Settings* settings = nullptr;
|
2011-02-24 09:27:21 +00:00
|
|
|
|
|
|
|
void Settings::load() {
|
2013-05-02 11:25:45 +00:00
|
|
|
string path = {userpath(), ".config/phoenix/"};
|
|
|
|
Configuration::Document::load({path, "gtk.bml"});
|
2011-02-24 09:27:21 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void Settings::save() {
|
2013-04-14 08:52:47 +00:00
|
|
|
string path = {userpath(), ".config/phoenix/"};
|
|
|
|
directory::create(path, 0755);
|
2013-05-02 11:25:45 +00:00
|
|
|
Configuration::Document::save({path, "gtk.bml"});
|
2011-02-24 09:27:21 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
Settings::Settings() {
|
2013-04-14 08:52:47 +00:00
|
|
|
geometry.append(geometry.frameX = 4, "FrameX");
|
|
|
|
geometry.append(geometry.frameY = 24, "FrameY");
|
|
|
|
geometry.append(geometry.frameWidth = 8, "FrameWidth");
|
|
|
|
geometry.append(geometry.frameHeight = 28, "FrameHeight");
|
|
|
|
geometry.append(geometry.menuHeight = 20, "MenuHeight");
|
|
|
|
geometry.append(geometry.statusHeight = 20, "StatusHeight");
|
|
|
|
append(geometry, "Geometry");
|
|
|
|
window.append(window.backgroundColor = 0xedeceb, "BackgroundColor");
|
|
|
|
append(window, "Window");
|
2011-02-24 09:27:21 +00:00
|
|
|
}
|
2013-03-15 13:11:33 +00:00
|
|
|
|
|
|
|
}
|