Commit graph

4 commits

Author SHA1 Message Date
MacDue
21c647dd75 LibGUI: Add center_window_group_within() to AbstractThemePreview
This method will center a group of window rects, within some
bounds, accounting for the properties of the currently selected theme
(i.e. border width, title height, etc).
2022-05-07 22:58:55 +02:00
Sam Atkins
6c572006a3 LibGUI+ThemeEditor: Split preview-widget palette-change callback
There are two different things in ThemeEditor that want to know when a
palette changes:
1. The PreviewWidget subclass, so it can update its preview.
2. The ThemeEditor itself, so we know that the palette is modified.

Using a protected virtual function for 1 means that we can do 2 without
them fighting over the same on_palette_change callback.
2022-04-29 20:06:39 +02:00
MacDue
d0aef66bcc LibGUI: Respect TitleButtonsIconOnly in AbstractThemePreview 2022-04-25 23:45:24 +02:00
Ben Maxwell
3fbefb82ac LibGUI+Applications: Move abstract ThemeEditor preview to LibGUI
This allows most of the theme preview code to be reused by similar
theme preview widgets.
2022-04-02 21:50:41 +02:00