Commit Graph
226 Commits
Author SHA1 Message Date
Gymnasiast 2398d91fb2 Rename DrawTextBasic() to DrawText() 2026-03-25 23:15:49 +01:00
Michael Steenbeek decc6631d5 Remove Formatter::Common() (#26197) 2026-03-16 13:01:38 +00:00
Aaron van Geffen 0ef38bc902 Fix mapgen window size in enlarged UI mode (#26159)
The mapgen window was not getting the right window size in enlarged UI mode.
2026-03-09 11:07:39 +01:00
Aaron van Geffen 3014621495 Resize dropdowns in mapgen window (#26148) 2026-03-06 21:56:58 +01:00
Michael Steenbeek 343c7a70d7 Change colour to a strong enum (#25873) 2026-01-28 10:06:45 +01:00
Gymnasiast e46d2eba9e Move colour map to its own file 2026-01-17 18:46:54 +01:00
Gymnasiast 04a3d02023 Rename members of ColourShadeMap 2026-01-16 19:25:58 +01:00
Gymnasiast a13b1c4e11 Make PaletteIndex into a strong enum and move into namespace 2026-01-07 23:55:30 +01:00
Aaron van Geffen 40aaf97c07 Update copyright years to 2026 (#25741) 2026-01-05 13:42:59 +00:00
Aaron van Geffen 8a0a655025 Unwrangle Drawing.h and Paint.h (#25706)
* Drop Drawing.h include from Paint.h

* Split off RenderTarget to its own header/unit

* Move FilterPaletteID to its own header
2025-12-26 12:58:33 +01:00
Michael Steenbeek 5a547fc2bb Fix return value of Widget::height() 2025-12-12 18:26:05 +01:00
Michael Steenbeek 6f24577027 Fix return value of Widget::width() 2025-11-08 10:27:58 +01:00
Gymnasiast daa4fe8ac3 Rename field of all config categories 2025-10-07 20:21:32 +02:00
Michael Steenbeek eb38b7227f Change WindowFlag to strong enum 2025-09-20 21:46:42 +02:00
Gymnasiast a662c5ef8e Change WindowClass members to use lowerCamelCase 2025-09-17 23:18:52 +02:00
Gymnasiast 3a803e13e2 Change window functions to use lowerCamelCase 2025-09-17 20:10:12 +02:00
Gymnasiast d4a0bca091 Rename Window fields 2025-09-17 20:10:12 +02:00
Aaron van Geffen 5b8fedd5b2 Rework Map.h includes (remove transitive header includes) 2025-09-04 22:16:53 +02:00
Gymnasiast ff896787ac Replace dropdown disabled/checked functions 2025-08-24 11:30:58 +02:00
Michael Steenbeek 577c3336c6 Create struct for all dropdown-related globals (#25023) 2025-08-23 13:56:13 +02:00
Michael Steenbeek 7b322d825a Refactor constants in window .cpp files 2025-06-16 23:10:47 +02:00
Gymnasiast 81e3181ebb Pass ScreenSize to makeWindowShim() 2025-06-10 23:21:15 +02:00
Gymnasiast bdba89f428 Pass ScreenSize to window creation functions 2025-06-10 23:20:28 +02:00
Gymnasiast bd6ae5848c Rename remaining methods in Widget.h to lowerCamelCase 2025-06-10 23:20:18 +02:00
Gymnasiast 650fa3ae2e Rename WindowWidgetType to WidgetType and change for new code style 2025-06-10 19:55:12 +02:00
Gymnasiast 149468406b Update WindowColour enum for new code style 2025-06-10 19:53:12 +02:00
Gymnasiast 86e265f093 Make widget creation functions lowerCamelCase 2025-06-10 19:51:21 +02:00
Aaron van Geffen 0779b9f0ab Replace window shim and widget macros with constexpr functions (#24566) 2025-06-07 23:02:14 +02:00
Matt 6335c31336 Rename DrawPixelInfo to RenderTarget (#24339)
* Begin backend separation, rename type DrawingPixelInfo to RenderTarget

* Rename dpi variables to rt
2025-05-04 22:06:46 +00:00
Aaron van Geffen 3f87e2b67a Centralise ResizeFrame in WindowBase and call when setting widgets or resizing 2025-04-11 20:37:54 +02:00
Aaron van Geffen 47795f398c Adjust more hardcoded top positions 2025-04-06 11:53:29 +02:00
Michael Steenbeek 70bdddcf36 Reduce object casting (#24072) 2025-03-25 08:51:44 +01:00
Aaron van Geffen 92212369d4 Skip setting page/widgets if we're already on the page (#23975) 2025-03-12 19:50:19 +01:00
Michael Steenbeek 8266447904 Split LOADSAVETYPE_* into LoadSaveAction and LoadSaveType 2025-03-06 21:06:39 +00:00
Gymnasiast 9cf02f3635 Refactor MODAL_RESULT_* to enum 2025-03-01 20:12:11 +01:00
Aaron van Geffen bb94ee8bc0 Rename ObjectType enum to follow recent code style (#23810) 2025-02-13 23:07:55 +01:00
73 b9b2c96c97 Rename sprites.h to SpriteIds.h (#23804) 2025-02-13 15:51:46 +00:00
Michael Steenbeek b0c99fcb6c Refactor more constants to kConstant notation 2025-01-22 16:16:55 +00:00
Aaron van Geffen 5fbe8d0ae1 Centralise external window signatures in Windows.h (#23653) 2025-01-19 15:50:54 +01:00
Aaron van Geffen bed4d5bdca Move WindowCreate and WindowFocusOrCreate into WindowManager (#23643)
* Move WindowBringToFront into WindowManager

* Move WindowCreate and WindowFocusOrCreate into WindowManager

* Cut back on Context/UiContext includes
2025-01-19 06:58:28 -03:00
MattandAaron van Geffen b9f6b6f754 Refactor widgets state (#23621)
* Refactor windows to not share widget state

* First half of refactoring all the windows

* Refactor the remaining windows, compiles but has issues

* Fix drawing only every second widget

* Remove the need of an terminating widget

* Address WidgetIndex signedness issues; use kWidgetIndexNull more

* Address constexpr issue with Widget content union

* Fix tabs in scenery window

* Fix tabs in object selection window

* Adjust custom widget index for CustomTool events

* Use STR_NONE for default tooltip initialisation

* Adjustment for mingw compiler

* Fix bottom toolbar using the widget declaration not instance

* Remove pointless code in Guest window, handled by SetPage

* Prevent out of bounds crash

* Move scroll widgets initialization to SetPage in Cheats window

* Remove special logic in Options window

* Remove special logic in Park window

* Remove special logic for Player window

* Remove special logic for Research window

* Remove special logic for Ride window

* Remove special logic for Staff window

* Remove special logic for Finances window

* Remove special logic for MapGen window

* Remove special logic for editor objective options window

* Remove special logic for editor scenario options window

* Fix widgets not being set since page is initialized to 0

* Remove more redundant code

* Fix remaining access to widget declarations

* Remove unused variable

* Fix editor object selection tabs on successive windows

---------

Co-authored-by: Aaron van Geffen <aaron@aaronweb.net>
2025-01-18 13:45:17 +01:00
Aaron van Geffen c0505bb164 Fix mapgen window reverting to flatland when selecting heightmap image 2025-01-02 12:30:51 +01:00
Aaron van Geffen 8cf9142b87 Encapsulate map generator in World::MapGenerator namespace 2024-12-30 16:21:22 +01:00
Aaron van Geffen c5508bcf1d Split off PngTerrainGenerator, SimplexNoise units 2024-12-30 15:11:40 +01:00
Aaron van Geffen 8562545138 Move MapGen and MapHelpers units into map_generator folder 2024-12-30 14:46:47 +01:00
Aaron van Geffen fa06a49302 Update copyright year to 2025 (#23514) 2024-12-31 20:30:04 +01:00
ζeh Matt 9dfd4f3b19 Rename the callback types 2024-12-04 20:43:55 +02:00
ζeh Matt e86618e835 Make sure the callback is not converted to void* 2024-12-04 16:46:35 +02:00
Aaron van Geffen ece199176e Move UnitConversion from Util into its own compilation unit 2024-10-29 11:27:00 +01:00
Aaron van Geffen 1c61c24ec2 Add clamp to map size text input (#23050) 2024-10-25 19:34:26 +02:00