Commit Graph

399 Commits

Author SHA1 Message Date
Rubidium 9ba2e386ac Codechange: use GrfID over uint32_t for NewGRF IDs 2026-07-06 16:41:08 +02:00
Peter Nelson 3666eb23a1 Fix #15784: Do close and reopen road build toolbar when switching road tram types (#15789) 2026-06-28 07:08:13 +00:00
mmtunligit 98dfc7376c Codechange: Split long single line loop to match #15589 2026-06-26 18:26:01 +02:00
mmtunligit 1a00026929 Change: selecting Rail/Roadtype updates build toolbar instead of closing and reopening (#15589) 2026-06-23 22:31:54 +00:00
Peter Nelson a55bd4e041 Codechange: make TransportType a scoped enum 2026-06-22 11:59:24 +02:00
Rubidium 5a6469ad6f Codechange: make EventState a scoped enum 2026-06-15 11:20:52 +02:00
Matt C 6bc486a578 Feature: Add default road and tram selection (#15585)
- Merged with the existing default rail type selection
2026-06-06 09:23:08 -04:00
Cyprian Klimaszewski 4175aee782 Fix #14975: Show correct tile for tunnel error message (#15660) 2026-06-03 18:47:55 -04:00
Rubidium 55be58a31d Codefix: do not update just closed construction toolbar when changing company 2026-06-03 07:20:55 +02:00
Peter Nelson f010c21f1a Codechange: make DiagDirection a scoped enum 2026-05-31 13:11:53 +01:00
Peter Nelson 0e0e8056a7 Codechange: use static_cast/to_underlying when converting DiagDirection 2026-05-31 13:11:53 +01:00
Rubidium 2ff631caa2 Codechange: make GameMode a scoped enum 2026-05-30 23:20:20 +02:00
Peter Nelson c74431e734 Codechange: make Axis a scoped enum 2026-05-27 07:49:39 +01:00
Peter Nelson c4b642668d Codechange: use EnumIndexArray for RoadStopType-indexed arrays 2026-05-26 17:12:50 +01:00
Rubidium bcda4a72ee Codechange: make WindowClass a scoped enum 2026-05-20 21:39:04 +02:00
Rubidium c59d64c132 Codechange: separate TextColour enumeration and flags 2026-05-18 08:37:42 +02:00
Peter Nelson 77403627a8 Codechange: make VehicleType a scoped enum 2026-04-26 07:00:13 +01:00
Rubidium 99c8a637b4 Codechange: make WindowPosition a scoped enum 2026-04-25 17:15:18 +02:00
Rubidium 3b5d46e0bb Codechange: make Colours a scoped enum 2026-04-19 20:53:52 +02:00
Peter Nelson 2bf84ea78c Codechange: make GrfSpecFeature a scoped enum (#15487) 2026-04-19 19:04:27 +01:00
Peter Nelson 73dafe5021 Codechange: use EnumBitSet for DisallowedRoadDirections (#15479) 2026-04-13 22:48:44 +01:00
Peter Nelson b33b0d92a0 Codechange: make RoadBits an EnumBitSet (#15476) 2026-04-13 21:23:17 +01:00
Peter Nelson a5a60c8615 Codechange: make RoadTramType a scoped enum, and use EnumBitSet (#15477) 2026-04-13 18:15:41 +01:00
Rubidium 7434052eb6 Codechange: make FontSize a scoped enum 2026-04-12 18:10:34 +02:00
Peter Nelson a9d7397a77 Codechange: Pass rail and roadtypes separately for tunnel and bridge commands. (#15438)
Avoids passing and casting each via an unrelated type, at the expense of an extra command parameter.
2026-04-06 14:45:22 +01:00
Rubidium 549d555be7 Codechange: document a number of parameters and return types 2026-02-18 22:57:05 +01:00
Peter Nelson 50110602aa Change: Display rail and road type speed limit text in yellow. (#15076)
This was a "convention" used by NewGRFs which exploited string colour bleeding.
2026-02-18 09:11:46 +00:00
Peter Nelson 0e25f9245c Codechange: use PoolID for newgrf class ids (#15228) 2026-02-18 09:11:04 +00:00
Rubidium c6c06e13eb Codefix: wrong parameter names and partially missing parameters 2026-02-02 16:31:46 +01:00
Rito12 664b507fe2 Change: Add support for next/previous/first/last road/tram type hotkeys. 2026-01-30 00:00:53 +01:00
Rito12 2de2c5d31d Cleanup: Expose last built types in the toolbar gui header. 2026-01-30 00:00:53 +01:00
Rubidium 4adf494ebc Codechange: enum-class-ify Commands 2026-01-28 23:32:51 +01:00
mmtunligit 2bcbea2694 Feature: User-defined collections of saved items in the picker window (#14813) 2026-01-25 12:38:01 -05:00
Cyprian Klimaszewski 99f04f27de Doc: Update information for receiving a copy of GPL. (#14869) 2025-12-07 11:25:08 +00:00
mmtunligit 7662105081 Change: Clamp terraform toolbar to main toolbar (#14725) 2025-11-13 18:25:21 -05:00
Peter Nelson 66b6d71e32 Codechange: Use std::initializer_list for NWidgetPart data. (#14749)
Avoids using C/C++ arrays.
2025-11-01 22:33:00 +00:00
Rito12 8ea347a811 Remove: Rail type cost from replace vehicle window. (#14748) 2025-10-31 10:26:47 -04:00
Peter Nelson f8aa2e64e4 Add: Include build cost in rail/road dropdowns. (#14599) 2025-09-29 19:23:02 +01:00
Peter Nelson 1229a498b7 Codechange: Add constant for INVALID_WIDGET. (#14649)
Replaces direct use of -1, making it easier to find.
2025-09-21 21:47:04 +00:00
Peter Nelson 614a01907a Codechange: Make functions for click and confirm beeps. (#14484)
Avoids repetition.
2025-07-27 21:54:32 +01:00
Peter Nelson de660cba02 Change: Consistent toolbar sizes with dedicated NWidgetParts. (#14344)
Add SetToolbarSpacerMinimalSize() and SetToolbarMinimalSize() NWidgetParts and use to make toolbar button sizes consistent.
2025-06-08 18:13:47 +00:00
Rubidium 7805c1c189 Codechange: use std::string_view for ini_key 2025-05-01 23:24:43 +02:00
Peter Nelson 394adb654e Codechange: Move GUI parts of badges to a separate file. (#14023) 2025-04-18 17:20:31 +01:00
Richard Wheeler a93087ec5c Fix #13980: Allow diagonal selection for road convert (#13983)
Fixes #13980
2025-04-12 18:50:11 +01:00
Peter Nelson 732109e444 Codechange: Use EnumBitSet for RoadTypes. 2025-03-25 20:15:48 +00:00
Peter Nelson 819e097d6e Codechange: Use separate RoadTypes mask to list road or tram roadtypes.
This simplifies logic reduces ambiguity.
2025-03-25 20:15:48 +00:00
Peter Nelson adb20f99ea Fix: Autoreplace rail/road list only listed buildable types. (#13887)
Instead list all possible types which includes hidden types compatible with buildable types.
2025-03-25 08:22:30 +00:00
Peter Nelson a1bcfb836a Codechange: Remove leftover SetStringTips. 2025-03-04 08:23:28 +00:00
Peter Nelson c7846f4629 Codechange: Move to GetWidgetString for road windows. 2025-03-03 21:20:14 +00:00
Peter Nelson e2c1b9f03e Codechange: Use only raw strings in drop down lists. (#13667)
Strings with parameters are now pre-formatted, avoiding global parameters.

Helper functions still allow StringID.
2025-02-27 21:11:16 +00:00