Opened 14 months ago

Closed 14 months ago

Last modified 13 months ago

#7099 closed defect (fixed)

DXF: Entities on layer 0 within a block should inherit the style of the layer the INSERT is on

Reported by: Alan Thomas Owned by: warmerdam
Priority: normal Milestone:
Component: OGR_SF Version: svn-trunk
Severity: normal Keywords: dxf
Cc:

Description

See https://knowledge.autodesk.com/support/autocad/learn-explore/caas/CloudHelp/cloudhelp/2015/ENU/3PP-ACD-Wiley/files/GUID-1207CBD9-5EA9-497C-AFA2-C7FBEF6DFA86-htm.html:

When objects assigned to layer 0 are used as parts of a block and that block is inserted on another layer, those objects take on the characteristics of their new layer.

This is easy to fix for entities with a PEN style string - we can just call OGRDXFLayer::PrepareLineStyle again. Solving the problem for other entities (TEXT, MTEXT and HATCH) looks to be more challenging.

Attachments (1)

OGR-DXF-block-layer-0.diff (1.1 KB) - added by Alan Thomas 14 months ago.
Patch

Download all attachments as: .zip

Change History (3)

Changed 14 months ago by Alan Thomas

Attachment: OGR-DXF-block-layer-0.diff added

Patch

comment:1 Changed 14 months ago by Even Rouault

Resolution: fixed
Status: newclosed

In 40483:

DXF: entities on layer 0 within a block should inherit the style of the layer the INSERT is on. Do that for entities with a PEN style string for now. (patch by atlight + null-pointer deref check by myself, fixes #7099)

comment:2 Changed 13 months ago by Alan Thomas

In 40712:

DXF: Correct color for ByBlock? text features; respect hidden objects (refs #5592, refs #7099, refs #7121)

Note: See TracTickets for help on using tickets.