File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 44Custom element classes related to the styles part
55"""
66
7- from ..ns import qn
8- from ..xmlchemy import BaseOxmlElement , ZeroOrOne
7+ from ..xmlchemy import BaseOxmlElement , ZeroOrMore , ZeroOrOne
98
109
1110class CT_Style (BaseOxmlElement ):
@@ -22,6 +21,8 @@ class CT_Styles(BaseOxmlElement):
2221 ``<w:styles>`` element, the root element of a styles part, i.e.
2322 styles.xml
2423 """
24+ style = ZeroOrMore ('w:style' , successors = ())
25+
2526 def style_having_styleId (self , styleId ):
2627 """
2728 Return the ``<w:style>`` child element having ``styleId`` attribute
@@ -32,10 +33,3 @@ def style_having_styleId(self, styleId):
3233 return self .xpath (xpath )[0 ]
3334 except IndexError :
3435 raise KeyError ('no <w:style> element with styleId %d' % styleId )
35-
36- @property
37- def style_lst (self ):
38- """
39- List of <w:style> child elements.
40- """
41- return self .findall (qn ('w:style' ))
You can’t perform that action at this time.
0 commit comments