diff --git a/Base/res/icons/16x16/bottom-layer.png b/Base/res/icons/16x16/bottom-layer.png index f8b540b48ef..bcd05b12283 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 a7556652f30..d2a8998ba3d 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 17e33bbf0c7..d49f071deb9 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 f96544ba745..9b3b758a1fa 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 50b7dfd9423..84b8fd318d5 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 41455ff5da2..d0b3ca85dcf 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 01d2de7b2ad..9d37c2621f0 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 8edb7689b53..5caf3bfeb87 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 00000000000..c120416c489 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 00000000000..e4ac353fb5b 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 00000000000..ab65d0f6e63 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 00000000000..9e62d16e902 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 2a7cb72e3eb..c421dfa3f2d 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 9e62d16e902..a0f817444e2 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 00000000000..8ab269ac7a4 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 00000000000..f1b51a965f4 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 00000000000..5072a44b3ad 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 00000000000..f108bcb1392 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 2f6dc0ed4ad..608b8c15dda 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 e57ab2fe9a8..050e88bde95 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 00000000000..ca658ad84f6 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 5f84a4fb71c..e264ac3f573 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 88017b99e04..bbd1a2ab60e 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 eab38790738..0eaf1244222 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 d1509c03260..e1c99f85ec3 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();