| 1 | // Aseprite |
| 2 | // Copyright (C) 2018-2021 Igara Studio S.A. |
| 3 | // Copyright (C) 2001-2017 David Capello |
| 4 | // |
| 5 | // This program is distributed under the terms of |
| 6 | // the End-User License Agreement for Aseprite. |
| 7 | |
| 8 | #ifndef APP_MODULES_GUI_H_INCLUDED |
| 9 | #define APP_MODULES_GUI_H_INCLUDED |
| 10 | #pragma once |
| 11 | |
| 12 | #include "app/ui/skin/skin_property.h" |
| 13 | #include "base/exception.h" |
| 14 | #include "gfx/rect.h" |
| 15 | #include "ui/base.h" |
| 16 | |
| 17 | namespace ui { |
| 18 | class ButtonBase; |
| 19 | class CheckBox; |
| 20 | class Message; |
| 21 | class RadioButton; |
| 22 | class Widget; |
| 23 | class Window; |
| 24 | } |
| 25 | |
| 26 | namespace app { |
| 27 | class Command; |
| 28 | class Doc; |
| 29 | class Params; |
| 30 | |
| 31 | namespace tools { |
| 32 | class Tool; |
| 33 | } |
| 34 | |
| 35 | int init_module_gui(); |
| 36 | void exit_module_gui(); |
| 37 | |
| 38 | void update_windows_color_profile_from_preferences(); |
| 39 | void update_screen_for_document(const Doc* document); |
| 40 | |
| 41 | void load_window_pos(ui::Window* window, const char* section, |
| 42 | const bool limitMinSize = true); |
| 43 | void save_window_pos(ui::Window* window, const char* section); |
| 44 | |
| 45 | ui::Widget* setup_mini_font(ui::Widget* widget); |
| 46 | ui::Widget* setup_mini_look(ui::Widget* widget); |
| 47 | |
| 48 | // This function can be used to reinvalidate a specific rectangle if |
| 49 | // we weren't able to validate it on a onPaint() event. E.g. Because |
| 50 | // the current document was locked. |
| 51 | void defer_invalid_rect(const gfx::Rect& rc); |
| 52 | |
| 53 | } // namespace app |
| 54 | |
| 55 | #endif |
| 56 | |