17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-10-17 12:09:19 +02:00
Commit Graph

19 Commits

Author SHA1 Message Date
maj00r
f1a3bde00f refactor(editor): one declaration per statement (cpp:S1659) and no chained assignments (cpp:S1121) in the editor files of the branch; single statements under if/else/for that became two got braces 2026-10-11 22:28:35 +02:00
maj00r
b103a561e0 fix(editor): the drive of a switch follows the switch: moved, turned, its grade or cant changed with the gizmo or any other change of the switch, the include gets the new position, direction and rot.x/rot.z of the start of the switch, in the same undo step; self-test drives prints the parameters of the drive 2026-10-11 21:33:28 +02:00
7d331ee65a Editor: brace ImGui clipper loops, rename scenery wizard file name field 2026-10-10 19:55:50 +02:00
9935257783 Add nosonar tags 2026-10-09 18:40:31 +02:00
1c28809dd7 Sonar fixes 2026-10-09 14:42:55 +02:00
476f3bf1b7 feat(ui): panels can be docked together and dragged out of the simulator window into windows of their own (imgui multi-viewports, ui.viewports yes by default, off where the renderer or the platform can't do it, e.g. wayland); imgui coordinates kept relative to the main window by the glfw backend, so the overlays, picking and gizmo of the editor work unchanged; overlays of the 3d view drawn on the main viewport; keys pressed in the separate windows passed on to the simulator, so the shortcuts of the editor work there too 2026-10-08 21:04:58 +02:00
344034ec70 feat(ui): imgui 1.91.9b-docking in place of 1.73: local changes of the backends carried over (glad as the gl loader, srgb and gamma of the ui, gles glsl string), BufferingBar/Spinner kept, imgui_tables in cmake; cursor position, cursor enter and focus of the main window passed to the glfw backend, which works with events now; code adapted to the api: ImGuiListClipper::Begin, BeginListBox, ImTextureID as an integer, ImageButton with an id, ImGuiKey without GetKeyIndex, logarithmic sliders in place of the removed power argument; ImGuizmo with the math operators defined before imgui.h and SetNextFrameWantCaptureMouse 2026-10-08 20:38:13 +02:00
maj00r
d4271ea7c5 fix(editor): no variables named near or far, the Windows headers define them away 2026-10-06 22:37:00 +02:00
maj00r
24923dd472 feat(editor): track editor driven by what the cursor is over: the outline and a label show what a click or a drag does, snapping to free ends on the screen, handles and ends dragged directly, no rotation gizmo; laying from a free end the same in every mode, straight with Shift, the curve of a switch going on past its diverging end; height 0 where there's no terrain; placed switch leaves the switch mode, double slips listed apart, a drive of the switch placed with it by the //$e switch description of its template; compound curves of any number of radii; dragged end of a straight fits the curve beside it; name of a path, followed by the memory cells and the includes taking it; turntable placed from a template described as one, tracks led out of it and the tracks around fitted to it, its positions written to the include; infrastructure bound to the path whose events read its memory cell; terrain made where the route has none and shaped to the formation under the ballast; models along the track over the selected path and on along the joined ones while dragged, rarely used settings folded; vehicles and trainsets placed on any path, switches included, facing the way the arrow shows; joined paths spread into the selection; New scenery in the File menu starts the editor again with the wizard; ortho zoom towards the cursor; scripted self tests; Polish translation 2026-10-06 22:19:54 +02:00
maj00r
3731520e33 feat(tracks): track editor in one movable Tracks window with exclusive modes, a guide of what can be done in the current step and the rarely used fields folded; vertical profile window with the ground of the scenery triangles; plain pieces added at a free end, freehand only on request; curve mode edits the single curve clicked 2026-10-05 01:21:11 +02:00
maj00r
9bd8226c51 Fix the GCC 13 and MSVC builds: no brace-initialised reference from reference_wrapper, no near/far names 2026-10-04 02:49:05 +02:00
maj00r
7d87fef7a0 refactor(editor): anchor on the nearest place of a path 2026-10-04 00:51:05 +02:00
maj00r
07994a578c refactor(editor): stored bindings read apart from their registration, one way to open a profile route 2026-10-04 00:50:08 +02:00
maj00r
eb5b2e8919 refactor(editor): split the infrastructure window 2026-10-04 00:48:00 +02:00
maj00r
0879f1528e refactor(editor): named overlay colours 2026-10-04 00:43:41 +02:00
maj00r
c85a52d5b1 refactor(editor): track observer instead of the function hooks 2026-10-04 00:37:26 +02:00
maj00r
7b8d809078 refactor(editor): drop unused editor state and vertical leftovers of the route design 2026-10-04 00:35:40 +02:00
maj00r
e5c91d8a1a refactor(editor): shared plan geometry and formatting helpers 2026-10-04 00:33:44 +02:00
maj00r
8778353b22 feat(editor): infrastructure bound to the paths follows their changes 2026-10-04 00:14:03 +02:00