Import DXF Layout/paper space
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Inkscape |
New
|
Wishlist
|
Unassigned |
Bug Description
This is to put in wishlist.
It would be great to be able to import dxf layout(s) instead of model space, keeping layers.
I researched a bit, but I'm unable to implement this myself quicly (don't know anything about SVG :( )
According to DXF specifications, in the section OBJECTS under the code 0 LAYOUT you can get dimensions of the paper in mm (100 AcDbPlotSettings -> 44 and 45 codes) and the layout name (100 AcDbLayout -> 1; code 330 can be used as id).
The Entity VIEWPORT has all the information to transform objects from model space:
10, 20: X and Y of the viewport center in mm
40, 50: width and height of viewport in mm (if the viewport is rotated, they are the horizontal and vertical dimension)
17, 27: X and Y of the center of the model space shown in the viewport, in model units
45: height of the model shown in viewport, in model units (same as 40 for rotated views)
51: rotation of the model shown in viewport, degrees, counterclockwise
331: frozen layer id (multiple occurrences)
So, for every viewport on the layout (that share the same 330 code) importer should:
- detect entities within the viewport range
- scale, rotate and move entities in place.
There's the need to choose if ignore layer status in each viewport (= include all entities in all viewports) or deleting entities of frozen layers in that viewport. maybe a user option can solve this issue.
If there are multiple viewports that displays the same model area, there's the need to duplicate entities of that area.
Changed in inkscape: | |
importance: | Undecided → Wishlist |