code: def get_all_styles(document, style):
      
  
      classes = []
  
      while True:
          classes.insert(0, get_style_name(style))
  
          if style.based_on:
              style = document.styles.get_by_id(style.based_on)
          else:
              break
  
      return classes
docs: Returns list of styles on which specified style is based on.
  
      :Args:
        - document (:class:`ooxml.doc.Document`): Document object
        - style (:class:`ooxml.doc.Style`): Style object
  
      :Returns:
        List of style objects.