diff --git a/Base/res/icons/16x16/bottom-layer.png b/Base/res/icons/16x16/bottom-layer.png index f8b540b48e..bcd05b1228 100644 Binary files a/Base/res/icons/16x16/bottom-layer.png and b/Base/res/icons/16x16/bottom-layer.png differ diff --git a/Base/res/icons/16x16/move-to-back.png b/Base/res/icons/16x16/move-to-back.png index a7556652f3..d2a8998ba3 100644 Binary files a/Base/res/icons/16x16/move-to-back.png and b/Base/res/icons/16x16/move-to-back.png differ diff --git a/Base/res/icons/16x16/move-to-front.png b/Base/res/icons/16x16/move-to-front.png index 17e33bbf0c..d49f071deb 100644 Binary files a/Base/res/icons/16x16/move-to-front.png and b/Base/res/icons/16x16/move-to-front.png differ diff --git a/Base/res/icons/16x16/new-layer.png b/Base/res/icons/16x16/new-layer.png index f96544ba74..9b3b758a1f 100644 Binary files a/Base/res/icons/16x16/new-layer.png and b/Base/res/icons/16x16/new-layer.png differ diff --git a/Base/res/icons/16x16/top-layer.png b/Base/res/icons/16x16/top-layer.png index 50b7dfd942..84b8fd318d 100644 Binary files a/Base/res/icons/16x16/top-layer.png and b/Base/res/icons/16x16/top-layer.png differ diff --git a/Base/res/icons/16x16/zoom-reset.png b/Base/res/icons/16x16/zoom-reset.png index 41455ff5da..d0b3ca85dc 100644 Binary files a/Base/res/icons/16x16/zoom-reset.png and b/Base/res/icons/16x16/zoom-reset.png differ diff --git a/Base/res/icons/pixelpaint/active-layer-down.png b/Base/res/icons/pixelpaint/active-layer-down.png index 01d2de7b2a..9d37c2621f 100644 Binary files a/Base/res/icons/pixelpaint/active-layer-down.png and b/Base/res/icons/pixelpaint/active-layer-down.png differ diff --git a/Base/res/icons/pixelpaint/active-layer-up.png b/Base/res/icons/pixelpaint/active-layer-up.png index 8edb7689b5..5caf3bfeb8 100644 Binary files a/Base/res/icons/pixelpaint/active-layer-up.png and b/Base/res/icons/pixelpaint/active-layer-up.png differ diff --git a/Base/res/icons/pixelpaint/add-guide.png b/Base/res/icons/pixelpaint/add-guide.png new file mode 100644 index 0000000000..c120416c48 Binary files /dev/null and b/Base/res/icons/pixelpaint/add-guide.png differ diff --git a/Base/res/icons/pixelpaint/clear-guides.png b/Base/res/icons/pixelpaint/clear-guides.png new file mode 100644 index 0000000000..e4ac353fb5 Binary files /dev/null and b/Base/res/icons/pixelpaint/clear-guides.png differ diff --git a/Base/res/icons/pixelpaint/close-image.png b/Base/res/icons/pixelpaint/close-image.png new file mode 100644 index 0000000000..ab65d0f6e6 Binary files /dev/null and b/Base/res/icons/pixelpaint/close-image.png differ diff --git a/Base/res/icons/pixelpaint/crop.png b/Base/res/icons/pixelpaint/crop.png new file mode 100644 index 0000000000..9e62d16e90 Binary files /dev/null and b/Base/res/icons/pixelpaint/crop.png differ diff --git a/Base/res/icons/pixelpaint/default-colors.png b/Base/res/icons/pixelpaint/default-colors.png index 2a7cb72e3e..c421dfa3f2 100644 Binary files a/Base/res/icons/pixelpaint/default-colors.png and b/Base/res/icons/pixelpaint/default-colors.png differ diff --git a/Base/res/icons/pixelpaint/guides.png b/Base/res/icons/pixelpaint/guides.png index 9e62d16e90..a0f817444e 100644 Binary files a/Base/res/icons/pixelpaint/guides.png and b/Base/res/icons/pixelpaint/guides.png differ diff --git a/Base/res/icons/pixelpaint/load-color-palette.png b/Base/res/icons/pixelpaint/load-color-palette.png new file mode 100644 index 0000000000..8ab269ac7a Binary files /dev/null and b/Base/res/icons/pixelpaint/load-color-palette.png differ diff --git a/Base/res/icons/pixelpaint/merge-active-layer-down.png b/Base/res/icons/pixelpaint/merge-active-layer-down.png new file mode 100644 index 0000000000..f1b51a965f Binary files /dev/null and b/Base/res/icons/pixelpaint/merge-active-layer-down.png differ diff --git a/Base/res/icons/pixelpaint/merge-active-layer-up.png b/Base/res/icons/pixelpaint/merge-active-layer-up.png new file mode 100644 index 0000000000..5072a44b3a Binary files /dev/null and b/Base/res/icons/pixelpaint/merge-active-layer-up.png differ diff --git a/Base/res/icons/pixelpaint/merge-visible.png b/Base/res/icons/pixelpaint/merge-visible.png new file mode 100644 index 0000000000..f108bcb139 Binary files /dev/null and b/Base/res/icons/pixelpaint/merge-visible.png differ diff --git a/Base/res/icons/pixelpaint/next-layer.png b/Base/res/icons/pixelpaint/next-layer.png index 2f6dc0ed4a..608b8c15dd 100644 Binary files a/Base/res/icons/pixelpaint/next-layer.png and b/Base/res/icons/pixelpaint/next-layer.png differ diff --git a/Base/res/icons/pixelpaint/previous-layer.png b/Base/res/icons/pixelpaint/previous-layer.png index e57ab2fe9a..050e88bde9 100644 Binary files a/Base/res/icons/pixelpaint/previous-layer.png and b/Base/res/icons/pixelpaint/previous-layer.png differ diff --git a/Base/res/icons/pixelpaint/save-color-palette.png b/Base/res/icons/pixelpaint/save-color-palette.png new file mode 100644 index 0000000000..ca658ad84f Binary files /dev/null and b/Base/res/icons/pixelpaint/save-color-palette.png differ diff --git a/Base/res/icons/pixelpaint/swap-colors.png b/Base/res/icons/pixelpaint/swap-colors.png index 5f84a4fb71..e264ac3f57 100644 Binary files a/Base/res/icons/pixelpaint/swap-colors.png and b/Base/res/icons/pixelpaint/swap-colors.png differ diff --git a/Userland/Applications/PixelPaint/IconBag.cpp b/Userland/Applications/PixelPaint/IconBag.cpp index 88017b99e0..bbd1a2ab60 100644 --- a/Userland/Applications/PixelPaint/IconBag.cpp +++ b/Userland/Applications/PixelPaint/IconBag.cpp @@ -15,12 +15,18 @@ ErrorOr IconBag::try_create() icon_bag.filetype_pixelpaint = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/16x16/filetype-pixelpaint.png")); icon_bag.new_clipboard = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/pixelpaint/new-clipboard.png")); icon_bag.file_export = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/16x16/file-export.png")); + icon_bag.close_image = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/16x16/close-tab.png")); icon_bag.edit_copy = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/16x16/edit-copy.png")); icon_bag.clear_selection = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/16x16/clear-selection.png")); icon_bag.swap_colors = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/pixelpaint/swap-colors.png")); icon_bag.default_colors = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/pixelpaint/default-colors.png")); + icon_bag.load_color_palette = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/pixelpaint/load-color-palette.png")); + icon_bag.save_color_palette = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/pixelpaint/save-color-palette.png")); + icon_bag.add_guide = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/pixelpaint/add-guide.png")); + icon_bag.clear_guides = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/pixelpaint/clear-guides.png")); icon_bag.edit_flip_vertical = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/16x16/edit-flip-vertical.png")); icon_bag.edit_flip_horizontal = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/16x16/edit-flip-horizontal.png")); + icon_bag.crop = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/pixelpaint/crop.png")); icon_bag.new_layer = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/16x16/new-layer.png")); icon_bag.previous_layer = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/pixelpaint/previous-layer.png")); icon_bag.next_layer = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/pixelpaint/next-layer.png")); @@ -29,6 +35,7 @@ ErrorOr IconBag::try_create() icon_bag.active_layer_up = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/pixelpaint/active-layer-up.png")); icon_bag.active_layer_down = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/pixelpaint/active-layer-down.png")); icon_bag.delete_layer = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/16x16/delete.png")); + icon_bag.merge_visible = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/pixelpaint/merge-visible.png")); icon_bag.filter = TRY(Gfx::Bitmap::try_load_from_file("/res/icons/pixelpaint/filter.png")); return icon_bag; diff --git a/Userland/Applications/PixelPaint/IconBag.h b/Userland/Applications/PixelPaint/IconBag.h index eab3879073..0eaf124422 100644 --- a/Userland/Applications/PixelPaint/IconBag.h +++ b/Userland/Applications/PixelPaint/IconBag.h @@ -16,12 +16,18 @@ struct IconBag final { RefPtr filetype_pixelpaint { nullptr }; RefPtr new_clipboard { nullptr }; RefPtr file_export { nullptr }; + RefPtr close_image { nullptr }; RefPtr edit_copy { nullptr }; RefPtr clear_selection { nullptr }; RefPtr swap_colors { nullptr }; RefPtr default_colors { nullptr }; + RefPtr load_color_palette { nullptr }; + RefPtr save_color_palette { nullptr }; + RefPtr add_guide { nullptr }; + RefPtr clear_guides { nullptr }; RefPtr edit_flip_vertical { nullptr }; RefPtr edit_flip_horizontal { nullptr }; + RefPtr crop { nullptr }; RefPtr new_layer { nullptr }; RefPtr previous_layer { nullptr }; RefPtr next_layer { nullptr }; @@ -30,6 +36,7 @@ struct IconBag final { RefPtr active_layer_up { nullptr }; RefPtr active_layer_down { nullptr }; RefPtr delete_layer { nullptr }; + RefPtr merge_visible { nullptr }; RefPtr filter { nullptr }; }; } diff --git a/Userland/Applications/PixelPaint/MainWidget.cpp b/Userland/Applications/PixelPaint/MainWidget.cpp index d1509c0326..e1c99f85ec 100644 --- a/Userland/Applications/PixelPaint/MainWidget.cpp +++ b/Userland/Applications/PixelPaint/MainWidget.cpp @@ -191,7 +191,7 @@ void MainWidget::initialize_menubar(GUI::Window& window) file_menu.add_separator(); - m_close_image_action = GUI::Action::create("&Close Image", { Mod_Ctrl, Key_W }, [&](auto&) { + m_close_image_action = GUI::Action::create("&Close Image", { Mod_Ctrl, Key_W }, g_icon_bag.close_image, [&](auto&) { auto* active_widget = m_tab_widget->active_widget(); VERIFY(active_widget); m_tab_widget->on_tab_close_click(*active_widget); @@ -305,7 +305,7 @@ void MainWidget::initialize_menubar(GUI::Window& window) editor->set_secondary_color(Color::White); })); m_edit_menu->add_action(GUI::Action::create( - "&Load Color Palette", [&](auto&) { + "&Load Color Palette", g_icon_bag.load_color_palette, [&](auto&) { auto response = FileSystemAccessClient::Client::the().try_open_file(&window, "Load Color Palette"); if (response.is_error()) return; @@ -319,7 +319,7 @@ void MainWidget::initialize_menubar(GUI::Window& window) m_palette_widget->display_color_list(result.value()); })); m_edit_menu->add_action(GUI::Action::create( - "Sa&ve Color Palette", [&](auto&) { + "Sa&ve Color Palette", g_icon_bag.save_color_palette, [&](auto&) { auto response = FileSystemAccessClient::Client::the().try_save_file(&window, "untitled", "palette"); if (response.is_error()) return; @@ -352,7 +352,7 @@ void MainWidget::initialize_menubar(GUI::Window& window) }); m_add_guide_action = GUI::Action::create( - "&Add Guide", [&](auto&) { + "&Add Guide", g_icon_bag.add_guide, [&](auto&) { auto dialog = PixelPaint::EditGuideDialog::construct(&window); if (dialog->exec() != GUI::Dialog::ExecOK) return; @@ -388,7 +388,7 @@ void MainWidget::initialize_menubar(GUI::Window& window) m_view_menu->add_action(*m_show_guides_action); m_view_menu->add_action(GUI::Action::create( - "&Clear Guides", [&](auto&) { + "&Clear Guides", g_icon_bag.clear_guides, [&](auto&) { auto* editor = current_image_editor(); VERIFY(editor); editor->clear_guides(); @@ -462,7 +462,7 @@ void MainWidget::initialize_menubar(GUI::Window& window) })); m_image_menu->add_separator(); m_image_menu->add_action(GUI::Action::create( - "&Crop To Selection", [&](auto&) { + "&Crop To Selection", g_icon_bag.crop, [&](auto&) { auto* editor = current_image_editor(); VERIFY(editor); // FIXME: disable this action if there is no selection @@ -584,7 +584,7 @@ void MainWidget::initialize_menubar(GUI::Window& window) })); m_layer_menu->add_action(GUI::Action::create( - "&Merge Visible", { Mod_Ctrl, Key_M }, [&](auto&) { + "&Merge Visible", { Mod_Ctrl, Key_M }, g_icon_bag.merge_visible, [&](auto&) { auto* editor = current_image_editor(); VERIFY(editor); editor->image().merge_visible_layers();