In AutoCAD , It can set line weight to ByLayer , ByBlock and Default.
But by the Aspose.CAD in Java API, how can i get the dwg Default line weight?
In AutoCAD, the Default line weight comes from LWDEFAULT system variable.
I have observed your requirements and suggest you to please share the sample DWG file with desired entity for which you need to change the line weight. Please elaborate your requirements so that we may help you further in this regard.
The line weigh information as below. Attached is the dwg file。
From CadLine’s getLineWeight API, I got the value -1, and from CadLayerTable’s getLineWeight API, I got the value -3.
My question is how can got the system default line weight which is set by the third picture.
Thanks a lot。Drawing1.zip (26.8 KB)
image.jpg (134.0 KB)
image.jpg (30.7 KB)
Thank you for sharing the information. An issue with ID CADJAVA-173 has been created in our issue tracking system to further investigate the requirements on our end. We will get back to you with a feedback as soon as it will be shared by our product team.
Our product team has investigated the issue on their end. It has been observed that when we change “system default line weight” property in AutoCad it saves this property only in AutoCad environment, but not in DWG or DXF files. The files only have an information about where entities or layers should get line weight or actually line weight of entities or layers.
About CadLine getLineWeight API:
If it returns:
-1 => by layer;
-2 => by block;
-3 => default;
About CadLayerTable getLineWeight API:
If it returns:
-3 => default
In Aspose.CAD “system Default line weight” is always 0.25 mm (as default value in AutoCad). I hope the shared elaboration will be helpful.