Skip to content

Dimensions measure to structural columns' faces and centre lines - #293

Merged
IPedrax merged 1 commit into
IPedrax:mainfrom
meococ:dimension-column-refs
Nov 9, 2026
Merged

IPedrax merged 1 commit into
IPedrax:mainfrom
meococ:dimension-column-refs

Conversation

@meococ

@meococ meococ commented Nov 7, 2026

Copy link
Copy Markdown
Contributor

Fixes #268.

Aligned and Linear dimensions could only pick grid lines in a plan: Model::reference_line, reference_lines and reference_points had no column arms, so pick_all returned the column, dimension_pick found no reference, and the cursor fell through to the grid.

  • A column now offers six reference lines: the centre line along its angle, the line across it (a new Face::Across), its left and right faces, and its start and end caps. A round column offers its two centre lines.
  • Its corners and the ends of its centre lines are reference points.
  • near_point, nearest_reference and nearest_end see columns standing on the plan, so [x, y] and {endpoint: [x, y]} references find them too.

Tests:

  • a_dimension_measures_between_structural_column_faces_and_centre_lines (core): face to face 3700, centre to centre 4000 across and 2000 along, a point on a face, and all of them follow the column as it moves.
  • aligned_dimensions_pick_structural_column_faces_and_centre_lines (UI): clicks the faces and both centre lines of two 3000 mm columns.
  • cargo test -p bimcraft-core --lib: 1,521 passed, 9 ignored.
  • cargo test -p bimcraft-ui-egui --lib tests::dimensions: 10 passed.
  • cargo fmt --check, cargo clippy --workspace --all-targets -- -D warnings and cargo i18n check clean.

Tab cycling between a column's faces and centre lines is a follow-up: the Dimension tool tracks one hovered id per frame, not the references under the cursor.

@IPedrax
IPedrax merged commit d7a4959 into IPedrax:main Nov 9, 2026
5 checks passed
IPedrax added a commit that referenced this pull request Nov 9, 2026
Dimensions measure to structural columns' faces and centre lines
emilianocapasso added a commit to acpvarchitects/BIMCraft that referenced this pull request Nov 9, 2026
…ents, pipe networks, title blocks, joins

Upstream's 92 commits: IPedrax#280 (the room of each component), IPedrax#288 (pipe networks), IPedrax#287, IPedrax#304 (editable title blocks), IPedrax#293,
IPedrax#305, IPedrax#294, IPedrax#273, a dry_run for script commands, and alignment guides on F8 only.

Rooms: one rule. IPedrax#280's `Rooms::room_at` and this branch's were the same rule (the walls' centre lines, 3d9ce13); ours stays,
with its `Rc` cache (`regions`), and IPedrax#280's duplicate (`room_at`, `centre_of`, `centre`) goes. Every caller now asks
`Rooms::component` (the family's room calculation point, else the insertion point, in the room's plan at the centre lines
and between its bottom and top): `element_json_with` (so `elements`, `inspect`'s palette JSON and schedules' Room Number and
Room Name), `load_points`' count of outlets and luminaires, and IFC's IfcRelReferencedInSpatialStructure. `elements` no
longer overrides `room` itself: a component outside every room leaves `room` out, as IPedrax#280 has it, rather than null.
IPedrax#280's test of an outlet on the bottom wall's north face turns it to face north (angle 180): the Outlet's room calculation
point stands 150 mm in front of it, toward -y, and at angle 0 it fell inside the wall, south of its centre line, as
docs/areas/families.md says it should.

Conflicts:
- model.rs: FORMAT stays 19. Upstream is at 18, title blocks included (IPedrax#304's merge: "Title blocks stay in the file format
  18"), so our Family Editor step stays 18 to 19; the 18 paragraph and the 17-to-18 comment are upstream's (title blocks,
  `join: false`, `across`), and our step's note says it leaves all of 18 alone.
- views-and-graphics.md: both sections (Doors > Opening; sheet sizes). The title-block paragraph's "FORMAT 19" is 18.
- commands.rs: upstream's arms_at, same_way and host_line, and ours' face_hosted and side_mirrored; relocate's doc comment
  back on relocate (it had drifted onto face_hosted), with upstream's "one wall or one run".
- render.rs: `part` pub(crate) beside our `sub`; a section's wall cut finds its solids either side of a butt interface
  (upstream) and keeps our door and window voids' shape.
- view3d.rs: upstream's tube end cuts, with our `vis: 0`.
- schedule.rs: components get Room Number and Room Name beside our Elevation from Level, Work Plane, Offset from Host, Host.
- tests.rs (core): both sides' hostile values, ours' nested families and upstream's strip-footing grips.
- properties.rs: element_json_with, and our Group import. ui-egui tests.rs: both tests.
- CLAUDE.md: ours, with upstream's titleblock.rs (2841 words).
- Docs: schedules.md, structure-and-mep.md and families.md name `Rooms::component` as the one rule.
- Catalogs (ui and project): ours, `cargo i18n update`, then each msgstr from either parent filled in by a 3-way merge on
  (msgctxt, msgid) with the base; nothing translated was lost where its msgid still exists.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01NVBR7rAfyvMsaXhi1B3YLr
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

BIMCraft_bug_dimension_columns

2 participants