Commit Graph
39 Commits
Author SHA1 Message Date
Leonardo Zide c6dd2c45c1 Fix keyboard focus after dropping parts from floating docks
Dragging a part from a floating Parts window can leave that window active after the drop. Setting focus on the model view alone does not activate its window, so movement shortcuts remain in the Parts list until the model is clicked.

Activate the receiving window before focusing the view after accepted part or color drops so keyboard commands can reach the model immediately.

Fixes #1040.
2026-10-23 14:42:54 -07:00
Leonardo Zide 78fe37515c Add selection outlines with obscured geometry fill
Render selected pieces with an outline above scene geometry and a faint selection-colored fill only over obscured portions. Preserve line-only selection colors and insertion preview tint, and suppress bounding box corners in outline mode.

Keep the existing tint and edges mode as a preference and fallback when outline rendering is unavailable. Own outline framebuffers in each view, keep OpenGL operations in lcContext, and capture selection visibility before the grid through a callback scoped to each scene draw.

Validation: debug build and desktop OpenGL checks passed for occlusion, transparency, MSAA, HiDPI, line-only selection, framebuffer fallback, grid exclusion, and widget resource cleanup.
2026-10-10 15:54:13 -07:00
Leonardo Zide 6438bf2682 Expand far clipping distance when fitting large models
Large models can extend beyond the default far plane after fitting,
leaving the view blank or clipped. Pass an explicit adjustment flag
through view, model, and camera fitting, and reuse the fitted bounds
to expand clipping with a margin, rounded up to multiples of 10,000.

Adjust restored ordinary cameras after applying their saved state.
Preserve named cameras and explicit command-line clipping planes,
and avoid recalculating clipping during redraws or navigation.

Route output fitting through the view and move the bounds policy
definition out of the precompiled header.
2026-10-09 15:00:18 -07:00
Leonardo Zide 83d129997a Fix OpenGL widget event forwarding 2026-09-13 16:31:31 -07:00
Leonardo Zide 7bb457f948 Formatting fixes. 2026-09-12 15:54:44 -07:00
Leonardo Zide b6f7f92e7e Update all views during piece insert. Fixes #942. 2026-05-06 20:59:46 -07:00
Leonardo Zide 596bb0c9cf Add Zoom and SmartZoom gesture. 2026-04-05 22:14:33 -07:00
Leonardo Zide a8e37df8ce Whitespace cleanup. 2026-03-10 21:11:40 -07:00
Leonardo Zide f12794e9e0 Fixed ui scale on retina displays. 2026-03-07 16:11:38 -08:00
Leonardo Zide 910c3de13e Added zoom region action. 2025-12-08 21:08:48 -08:00
Leonardo Zide 18255f367f Update mouse after closing the train track popup. 2025-02-08 18:31:15 -08:00
Leonardo Zide 23a93b4afb Added Qt version check. 2022-06-05 11:22:44 -07:00
Leonardo Zide d2f22773e3 Added support for trackpad pan gesture. 2022-05-07 18:46:26 -07:00
Leonardo Zide 4b9ecf4227 Slow down mouse wheel zoom when the shift key is down. 2021-10-02 17:40:21 -07:00
Leonardo Zide 989373155f Draw timer on screen. 2021-03-28 11:50:28 -07:00
Leonardo Zide c613ff6bb4 Added simple draw timer. 2021-03-27 19:19:29 -07:00
Leonardo Zide d0404d9fbb gcc fix. 2021-02-28 13:11:54 -08:00
Leonardo Zide 27734f2469 Moved bricklink color table to the mapping file. 2021-02-28 13:02:58 -08:00
Leonardo Zide 40983db71c View cleanup. 2021-02-28 10:57:14 -08:00
Leonardo 4f8252eff9 Fixed retina displays again. Fixes #447. 2021-01-26 17:07:51 -08:00
Leonardo Zide a85bbec789 Updated deprecated functions. 2021-01-14 14:51:43 -08:00
Leonardo Zide dbb4c9e44b QGLWidget cleanup. 2021-01-08 11:25:24 -08:00
Leonardo Zide ab9df4a712 Require Qt 5.4. 2021-01-08 10:57:39 -08:00
Leonardo Zide b70fab3059 Require Qt5. 2021-01-08 10:35:52 -08:00
Leonardo Zide 72763ddc11 Create offscreen context at startup and reuse it. 2021-01-01 18:41:28 -08:00
Leonardo Zide 7ec71d8602 Reorganized view sphere and preview options. Fixes #584. 2020-12-30 10:39:04 -08:00
Leonardo Zide 80adb54acf Always keep 1 context valid. 2020-12-29 14:42:59 -08:00
Leonardo Zide 4ed04e4e25 Use an offscreen buffer when saving images from the command line. 2020-12-28 17:30:41 -08:00
Leonardo Zide 0499e055e1 Crash fix #578. 2020-12-28 12:08:10 -08:00
Leonardo Zide 4e6cbca31c Switch to QOpenGLWidget. 2020-12-27 13:05:55 -08:00
Leonardo Zide 7de5d4eb22 Renamed view class. 2020-12-25 10:54:33 -08:00
Leonardo Zide 939e80ab4b Renamed view files. 2020-12-25 10:43:22 -08:00
Leonardo Zide 620ac457e5 Merged View and lcGLWidget. 2020-12-25 10:37:59 -08:00
Leonardo Zide 56daed4182 Removed OnInitialUpdate. 2020-12-24 17:14:36 -08:00
Leonardo Zide e27b235936 Derive preview from view. 2020-12-24 11:32:56 -08:00
Leonardo 9f5782294e Fixed view preferred size. 2020-12-21 17:34:42 -08:00
Leonardo Zide b77210db22 Use a regular View for the Minifig Wizard. 2020-12-19 16:05:29 -08:00
Leonardo Zide baa0a70de2 Refactored duplicate code. 2020-12-18 12:15:35 -08:00
Leonardo a492a935b6 Renamed lcQGLWidget to lcViewWidget. 2020-12-17 17:59:11 -08:00