Commit Graph
94 Commits
Author SHA1 Message Date
Duncan e09f27df3c Rename snake_case Class names (Remaining Bits) (#19237)
* Rename snake_case Class names

* Clang format

* Fix build issues
2023-01-21 19:57:17 +00:00
Duncan 859b071ddc Rename classes with snakes OpenRCT2/A*-F* (#19215)
* Rename classes with snakes OpenRCT2/A*-F*

* Clang format files
2023-01-19 08:16:44 +00:00
Hielke Morsink 0762fcb601 Rename snake_case functions in OpenRCT2/util folder 2023-01-18 22:44:13 +01:00
Michael Steenbeekandduncanspumpkin bf5f7e8e71 Rename format_string(2) and is_user_string_id() (#19178)
Co-authored-by: duncanspumpkin <duncans_pumpkin@hotmail.co.uk>
2023-01-17 08:59:07 +00:00
Michael Steenbeek b4480b344e Rename snake_case functions from localisation folder 2023-01-16 23:12:35 +00:00
Hielke Morsink 6dafbbfb65 Rename global window functions to TitleCase (#19167) 2023-01-16 20:13:42 +00:00
Duncan 7f5934cc95 Remove snake_case from second chunk of Drawing (#19166) 2023-01-16 18:52:17 +00:00
Duncan 8a8d3105f3 Remove snake_case from first chunk of Drawing (#19164)
* Remove snake_case from first chunk of Drawing

* Address formatting
2023-01-16 13:50:43 +00:00
Gymnasiast a516dc507e Replace str_is_null_or_empty() with String::IsNullOrEmpty() 2023-01-08 16:19:18 +01:00
James103 73738bbdc8 Replace 2022 with 2023 in copyright headers
Replace all instances of the year 2022 with 2023 in all copyright headers
2023-01-01 11:58:01 +01:00
Gymnasiast 162b01204d Rename rct_widget to Widget 2022-12-31 15:18:22 +01:00
Duncan 482971710d Apply code style to context functions 2022-11-06 21:49:07 +01:00
Gymnasiast 14f9a75e0a Refactor FontSpriteBase and font size into FontStyle 2022-10-19 11:59:26 +02:00
73 b9e677945d Replace 20XX with 2022 (#18158)
* Replace 2020 with 2022

Replace all 2020 headers with 2022

* replace other years with 2022

add missing years
2022-10-01 08:42:14 +01:00
Meehoi 61d74eaa4b Part of #15589: Make numpad enter able to confirm input 2022-09-25 18:33:02 +00:00
Gymnasiast a088537b65 Rename rct_widgetindex to WidgetIndex 2022-08-21 18:49:23 +02:00
Hielke Morsink 7f29e4e39c Make rct_windowclass strong type WindowClass
This already revealed some places where implicit conversions were done, including some where its use was nonsense (MouseInput.cpp).
The changes to the Intent class were necessary to keep things working, and this splits things up more neatly.
2022-08-21 18:38:25 +02:00
Gymnasiast d3fd31c611 Rename rct_string_id to StringId 2022-07-31 22:30:13 +02:00
Hielke Morsink a258008bef Refactor window functions to take references 4 2022-07-31 17:23:16 +02:00
Hielke Morsink 76c1bc8980 Refactor window functions to take references 1 2022-07-31 17:23:15 +02:00
Michael Steenbeekandguljam 3243183680 Fix #17187: Text input window does not resize correctly
window_set_resize() already invalidates, so no need to call it twice.

Co-authored-by: guljam <guljam@users.noreply.github.com>
2022-06-06 00:11:29 +02:00
Ted John da89a4e413 Remove rct_window::enabled_widgets (#16643)
`enabled_widgets` was used to enable input for widgets. However I do not recall anywhere this being used to specifically disable a widget which doesn't use the dedicated `disabled_widgets` flag. I don't think there is any purpose in keeping this, so I have removed all uses of it.
2022-02-13 23:06:19 +00:00
frutiemax adb692b74e Forward declare Formatter 2021-12-30 12:17:51 -05:00
Duncan 90d2be3ddd Clang tidy Part 3: Ui Project Enum Names (#15986)
* Enum constant case

* Apply enum names clang tidy

* Rename scoped enum missed by clang-tidy
2021-11-26 14:25:34 +00:00
Duncan bb2c7dbaca Clang tidy Part 1: Ui Project Function Names (#15956)
* Add NOLINT around STL using classes and vendor functions

* Apply clang-tidy to ui project function names

* Undo scripting clang-format

* Upper case OpenRCT2 and RCT2
2021-11-23 13:18:07 +00:00
Hielke Morsink 9dd9b27db4 Make WIDGETS_END constexpr 2021-09-26 11:11:42 +02:00
Duncan d2aca03ff6 Fix #15271. Use formatter to pass description args to text input (#15272)
* Fix #15271. Use formatter to pass description args to text input

Originally passed the variables via global vars which were not updated to 32bit during recent refactors. This removes the global and makes the interface cleaner and corrects the type

* Fix size of arguments
2021-08-24 19:12:05 +01:00
Michael Steenbeek f5935931e3 Port remaining DrawTextWrapped calls with void args to Formatter 2021-08-21 09:42:05 +02:00
ζeh Matt 8fc7e06116 Move gLastStringPos into rct_drawpixelinfo (#14811) 2021-06-03 22:10:09 -03:00
ζeh Matt ebcdfd06e9 Fix #14707: Crash when window is closed during text input 2021-05-24 00:11:04 +02:00
duncanspumpkin 820668d0aa Use unsafe strlen for platforms without strlen_s 2021-03-20 07:27:23 +00:00
duncanspumpkin ee575d5b8c Use std::vector to prevent violations of std string 2021-03-20 07:22:00 +00:00
duncanspumpkin 07b2945c5b Fix #14353. Provide a buffer for text input 2021-03-19 18:25:14 +00:00
Duncanspumpkin 0957542503 Implement C++ solution to truncate UTF8 strings 2021-03-18 22:14:12 +01:00
Gymnasiast 645685de18 Fix #14315: Crash when renaming APVC in Korean 2021-03-15 21:27:13 +01:00
Gymnasiast 7fd049c22e Remove last remnants of gCurrentFontSpriteBase 2021-02-28 00:26:53 +01:00
Gymnasiast c40701d997 Make gfx_draw_string() take a TextPaint argument 2021-02-28 00:26:20 +01:00
Gymnasiast 503273793a Remove gCurrentFontSpriteBase from some functions 2021-02-28 00:26:20 +01:00
Gymnasiast 826f6c7442 Reduce usage of gCurrentFontSpriteBase 2021-02-28 00:25:30 +01:00
Gymnasiast 3e536e2711 Change gfx_draw_string_*_wrapped() to DrawTextWrapped() 2021-02-28 00:23:01 +01:00
Gymnasiast 2477933c51 Turn font sprite base into a strong enum 2021-02-28 00:23:00 +01:00
Michał Janiszewski 9aef29361f Default-initialise more fields (#14130)
Doesn't really fix any particular issue, but adds more defaults to
fields in classes where other defaults are already present
2021-02-20 19:40:32 +01:00
Ted John e5b412fb5f Fix #14017: Text input window errors 2021-02-08 17:45:08 +00:00
Ted John 17f4f3aaf8 Refactor text input window to class 2021-02-07 22:36:31 +01:00
ζeh Matt 9ff2138f3f Remove unused variable gCurrentFontFlags 2021-01-30 16:46:22 +01:00
skdltmxn c093a50f3f Refactor to use string_view more properly 2021-01-07 01:52:10 +09:00
Ted John 503a383301 Do not format characters in text input 2020-11-27 18:54:57 +00:00
Ted John b6a688e540 Refactor format tokens 2020-11-27 18:54:57 +00:00
ffrogman 7ed1804e61 Fix #12410: Refactor WINDOW_WIDGET_TYPES to use strong enum (#13453)
* Fix #12410: Refactor WINDOW_WIDGET_TYPES to use strong enum
2020-11-27 00:14:20 -03:00
pizza2004 2015acd4c0 Refactor UI/Interface Window to Title Case (#13367) 2020-11-04 04:52:23 +00:00