feat: 增加Face偏移保持一级关系策略

This commit is contained in:
2026-08-10 15:26:35 +08:00
parent 83c44265ba
commit 415e8a0f27
9 changed files with 357 additions and 16 deletions
+14 -1
View File
@@ -491,6 +491,19 @@ def main() -> int:
_assert_label(plane_specs, "local_face_width", "面内长度")
_assert_label(plane_specs, "local_face_height", "面内宽度")
_assert_label(plane_specs, "face_target_normal_position", "偏移")
offset_keep_relations = _scope_mode(plane_specs, "face_target_normal_position", "keep_relations")
if str(offset_keep_relations.get("label") or "") != "保持关系":
raise SystemExit(f"Face plane-offset keep-relations scope should be labelled clearly: {offset_keep_relations}")
if str(offset_keep_relations.get("action") or "") != "push_pull_face_keep_relations":
raise SystemExit(f"Face plane-offset keep-relations scope should use its own action: {offset_keep_relations}")
if not bool(offset_keep_relations.get("enabled", False)):
raise SystemExit(f"Face plane-offset keep-relations scope should be available on simple planar Face: {offset_keep_relations}")
_assert_scoped_hint_fragments(
plane_specs,
"face_target_normal_position",
"keep_relations",
("一级", "平行/垂直", "会直接阻止"),
)
_assert_actionable_rows_first(
plane_info,
(
@@ -575,7 +588,7 @@ def main() -> int:
mode,
("5%", "5 倍", "会被阻止"),
)
for mode in ("push_pull", "local", "owning"):
for mode in ("push_pull", "keep_relations", "local", "owning"):
_assert_scoped_hint_fragments(
plane_specs,
"face_target_normal_position",