openpyxl.styles.named_styles module¶
- class openpyxl.styles.named_styles.NamedStyle(name='Normal', font=<openpyxl.styles.fonts.Font object> Parameters: name=None, charset=None, family=None, b=False, i=False, strike=None, outline=None, shadow=None, condense=None, color=None, extend=None, sz=None, u=None, vertAlign=None, scheme=None, fill=<openpyxl.styles.fills.PatternFill object> Parameters: patternType=None, fgColor=<openpyxl.styles.colors.Color object> Parameters: rgb='00000000', indexed=None, auto=None, theme=None, tint=0.0, type='rgb', bgColor=<openpyxl.styles.colors.Color object> Parameters: rgb='00000000', indexed=None, auto=None, theme=None, tint=0.0, type='rgb', border=<openpyxl.styles.borders.Border object> Parameters: outline=True, diagonalUp=False, diagonalDown=False, start=None, end=None, left=None, right=None, top=None, bottom=None, diagonal=None, vertical=None, horizontal=None, alignment=<openpyxl.styles.alignment.Alignment object> Parameters: horizontal=None, vertical=None, textRotation=0, wrapText=None, shrinkToFit=None, indent=0.0, relativeIndent=0.0, justifyLastLine=None, readingOrder=0.0, number_format=None, protection=<openpyxl.styles.protection.Protection object> Parameters: locked=True, hidden=False, builtinId=None, hidden=False, xfId=None)[源代码]¶
基类:
openpyxl.descriptors.serialisable.Serialisable
Named and editable styles
- alignment¶
Values must be of type <class ‘openpyxl.styles.alignment.Alignment’>
- border¶
Values must be of type <class ‘openpyxl.styles.borders.Border’>
- builtinId¶
Values must be of type <class ‘int’>
- fill¶
Values must be of type <class ‘openpyxl.styles.fills.Fill’>
- font¶
Values must be of type <class ‘openpyxl.styles.fonts.Font’>
Values must be of type <class ‘bool’>
- name¶
Values must be of type <class ‘str’>
- number_format¶
Values must be of type <class ‘str’>
- protection¶
Values must be of type <class ‘openpyxl.styles.protection.Protection’>
- property xfId¶
Index of the style in the list of named styles