python programming goto goto goto endfill xml files are text files they just contain extra xml formatted data to help standardize how xml files are read writing an xml file is as simple as writing text file while indentation is not necessary in xml filesit is often used to highlight the format of the file in sect the graphicscommands element contains one command element for each drawing command in the picture each drawing command contains the command type as its text the command types are gotocirclebeginfillendfillpenupand pendown the attributes of command are data like xywidthradiusand color that are used by the various types of commands to write the commands to fileeach of the command classes can be modified to produce an xml element when converted to string using the special __str__ method for instancesect contains the modified gotocommand class supporting the creation of an xml element the gotocommand with xml creation code the following classes define the different commands that are supported by the drawing application class gotocommanddef __init__(self, , ,width= ,color="black")self self self width width self color color the draw method for each command draws the command using the given turtle def draw(self,turtle)turtle width(self widthturtle pencolor(self colorturtle goto(self ,self the __str__ method is special method that is called when command is converted to string the string version of the command is how it appears in the graphics file format def __str__(self)return '<command ="str(self ' ="str(self 'width="str(self width'color="self color '">gotoby returning string like this from each of the command objectsthe code to write the draw program' data to file is very simple all that is needed is some code that writes the xml line as the first linefollowed by the tag and the command elements finallythe tag must be written the code in sect accomplishes this this copy belongs to 'acha