mirror of
https://github.com/RGBCube/serenity
synced 2025-06-01 03:08:13 +00:00
LibGUI: Move Icon and FontDatabase into the GUI namespace
We also clean up some old references to the old G prefixed GUI classes This also fixes a potential bug with using: C_OBJECT_ABSTRACT(GAbstractButton) instead of C_OBJECT_ABSTRACT(AbstractButton)
This commit is contained in:
parent
57f1c919df
commit
6a3b12664a
24 changed files with 120 additions and 104 deletions
|
@ -281,11 +281,11 @@ int main(int argc, char** argv)
|
|||
GUI::ActionGroup font_action_group;
|
||||
font_action_group.set_exclusive(true);
|
||||
auto font_menu = GUI::Menu::construct("Font");
|
||||
GFontDatabase::the().for_each_fixed_width_font([&](const StringView& font_name) {
|
||||
GUI::FontDatabase::the().for_each_fixed_width_font([&](const StringView& font_name) {
|
||||
auto action = GUI::Action::create(font_name, [&](GUI::Action& action) {
|
||||
action.set_checked(true);
|
||||
terminal.set_font(GFontDatabase::the().get_by_name(action.text()));
|
||||
auto metadata = GFontDatabase::the().get_metadata_by_name(action.text());
|
||||
terminal.set_font(GUI::FontDatabase::the().get_by_name(action.text()));
|
||||
auto metadata = GUI::FontDatabase::the().get_metadata_by_name(action.text());
|
||||
ASSERT(metadata.has_value());
|
||||
config->write_entry("Text", "Font", metadata.value().path);
|
||||
config->sync();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue