A good understanding of the Illustrator object model will improve your scripting abilities. The figure below shows the containment hierarchy of the object model, starting with the Application object. The
GroupItem classes and all text classes can contain additional objects of the same class which can, in turn, contain additional nested objects.
Within text, characters, words, paragraphs, and lines are all represented ...