ACadSharp icon indicating copy to clipboard operation
ACadSharp copied to clipboard

Create new DWG, Color control and Line Type Control and Model

Open sigster opened this issue 1 year ago • 7 comments

When I create new DWG

Color control = Color 0 Should it be = Bylayer as default ?

Line Type Control = notthing is default Should it be = Bylayer as default ?

Model and Layout1 Layout1 is Default activate Should it be = Model as default ?

Regards Sigster

sigster avatar Jan 31 '24 22:01 sigster

Hi @sigster

What do you mean by control? Are you referring to the header variables?

DomCR avatar Feb 01 '24 11:02 DomCR

This , when I open DWG file

Test55.zip

image image

sigster avatar Feb 01 '24 11:02 sigster

Edit: I'm not sure how those values are actually changed because I believe they are proprietary AutoCAD variables. I don't think that all DWG viewers/editors respect those values.

DJGosnell avatar Feb 01 '24 14:02 DJGosnell

These values are set by default but they are not constraint to anything in particular.

If you want a sort of defaults for your document you can change the values in the header of the document, here is an example with the LineType by default:

doc.Header.CurrentLineTypeName = LineType.ByBlockName;

Not sure which variable holds the current Layout, I would have to check that.

DomCR avatar Feb 01 '24 14:02 DomCR

Thanks

Do you have sample how to change Header color to Bylayer

image

sigster avatar Feb 01 '24 14:02 sigster

It seems that, there is a limitation with colors, the colors in the header are written in a different way than the other entities and by now the writer cannot write the colors in the header property, so by now I think that this value cannot change.

I'll open a branch assigned to this issue to take a look at this bug.

DomCR avatar Feb 01 '24 15:02 DomCR

Thanks

and thanks for the

doc.Header.CurrentLineTypeName = LineType.ByBlockName;

Regards Sigster

sigster avatar Feb 01 '24 15:02 sigster