ours: наш оверлей к апстриму 1.5.1 (дельта для переноса в 1.6.0)

10 изменённых файлов + 2 новых (engineering/gost_titleblock.py, _fonts/isocpeur.ttf).
Ветка-донор для трёхстороннего переноса в ours-1.6.
This commit is contained in:
2026-10-05 18:04:55 +03:00
parent ca1c79fd01
commit 2e2a2b96a9
12 changed files with 3232 additions and 159 deletions
+23
View File
@@ -28,6 +28,29 @@ class LayoutContract(ABC):
"""Activate a layout tab ('Model' or a paper-space layout name)."""
...
# MCP card t_b950b5c4 (01.10.2026). A sheet's format is part of the page
# setup, and every plot of the sheet reads it: without a way to state the
# format, a 210x297 frame drawn on a layout that still says A3 exports onto
# A3 with the frame in a corner. The headless backend stores it in the
# layout's paper fields; ActiveX exposes no verified equivalent.
@capability( # noqa: B027
"paper_space",
reason=(
"ActiveX has no verified member for a layout's sheet format (the page setup lives in "
"the drawing's plot configuration, which has not been exercised against a live "
"AutoCAD). Set the format in AutoCAD's Page Setup, or use the headless backend "
"(AUTOCAD_MCP_BACKEND=ezdxf), where layout_create + layout_set_paper store it."
),
)
async def layout_set_paper(self, name: str, width: float, height: float) -> dict:
"""Set the sheet a layout is set up for, in millimetres.
Returns ``{ok, layout, paper_mm}``. This is what
``drawing_export_pdf(page_size='layout')`` reads to size the page, so a
sheet exported at 1:1 is the format it was drawn for.
"""
...
@abstractmethod
async def layout_delete(self, name: str) -> dict:
"""Delete a paper-space layout and everything drawn on it.