I am using ezdxf to generate a DXF file for a tool. This tool needs to have in the dxf a comment containing informations for each layer. The comments must be formatted in a particular way.
Is there a way to create a comment and save it with ezdxf
NB: Currently I use a "dirty" hook to do this
I create an XDATA with a MYAPP ID for each layer with :
layer.set_xdata (myapp_id, [(999, comment)])
then I save the dxf file with
doc.saveas ("./ my_dxf_file.dxf")
after with a python script I delete all the occurrences 1001 \ nMYAPP_DATA \ n
in the dxf file to keep only the 999 tags (otherwise autocadLT cannot read the file... others tools like nanocad or babacad can but not autocadLT)