PHP Class Box\Spout\Writer\ODS\Helper\StyleHelper

Inheritance: extends Box\Spout\Writer\Common\Helper\AbstractStyleHelper
显示文件 Open project: box/spout Class Usage Examples

Protected Properties

Property Type Description
$usedFontsSet [FONT_NAME] => [] Map whose keys contain all the fonts used

Public Methods

Method Description
getContentXmlAutomaticStylesSectionContent ( integer $numWorksheets ) : string Returns the contents of the "" section, inside "content.xml" file.
getContentXmlFontFaceSectionContent ( ) : string Returns the contents of the "" section, inside "content.xml" file.
getStylesXMLFileContent ( integer $numWorksheets ) : string Returns the content of the "styles.xml" file, given a list of styles.
registerStyle ( Style $style ) : Style Registers the given style as a used style.

Protected Methods

Method Description
getAutomaticStylesSectionContent ( integer $numWorksheets ) : string Returns the content of the "" section, inside "styles.xml" file.
getFontFaceSectionContent ( ) : string Returns the content of the "" section, inside "styles.xml" file.
getMasterStylesSectionContent ( integer $numWorksheets ) : string Returns the content of the "" section, inside "styles.xml" file.
getStyleSectionContent ( Style $style ) : string Returns the contents of the "" section, inside "" section
getStylesSectionContent ( ) : string Returns the content of the "" section, inside "styles.xml" file.
getUsedFonts ( ) : string[]

Private Methods

Method Description
getBackgroundColorXMLContent ( Style $style ) : string Returns the contents of the background color definition for the "" section
getBorderXMLContent ( Style $style ) : string Returns the contents of the borders definition for the "" section
getFontSectionContent ( Style $style ) : string Returns the contents of the "" section, inside "" section
getTableCellPropertiesSectionContent ( Style $style ) : string Returns the contents of the "" section, inside "" section
getTextPropertiesSectionContent ( Style $style ) : string Returns the contents of the "" section, inside "" section
getWrapTextXMLContent ( ) : string Returns the contents of the wrap text definition for the "" section

Method Details

getAutomaticStylesSectionContent() protected method

Returns the content of the "" section, inside "styles.xml" file.
protected getAutomaticStylesSectionContent ( integer $numWorksheets ) : string
$numWorksheets integer Number of worksheets created
return string

getContentXmlAutomaticStylesSectionContent() public method

Returns the contents of the "" section, inside "content.xml" file.
public getContentXmlAutomaticStylesSectionContent ( integer $numWorksheets ) : string
$numWorksheets integer Number of worksheets created
return string

getContentXmlFontFaceSectionContent() public method

Returns the contents of the "" section, inside "content.xml" file.

getFontFaceSectionContent() protected method

Returns the content of the "" section, inside "styles.xml" file.
protected getFontFaceSectionContent ( ) : string
return string

getMasterStylesSectionContent() protected method

Returns the content of the "" section, inside "styles.xml" file.
protected getMasterStylesSectionContent ( integer $numWorksheets ) : string
$numWorksheets integer Number of worksheets created
return string

getStyleSectionContent() protected method

Returns the contents of the "" section, inside "" section
protected getStyleSectionContent ( Style $style ) : string
$style Box\Spout\Writer\Style\Style
return string

getStylesSectionContent() protected method

Returns the content of the "" section, inside "styles.xml" file.
protected getStylesSectionContent ( ) : string
return string

getStylesXMLFileContent() public method

Returns the content of the "styles.xml" file, given a list of styles.
public getStylesXMLFileContent ( integer $numWorksheets ) : string
$numWorksheets integer Number of worksheets created
return string

getUsedFonts() protected method

protected getUsedFonts ( ) : string[]
return string[] List of used fonts name

registerStyle() public method

Duplicate styles won't be registered more than once.
public registerStyle ( Style $style ) : Style
$style Box\Spout\Writer\Style\Style The style to be registered
return Box\Spout\Writer\Style\Style The registered style, updated with an internal ID.

Property Details

$usedFontsSet protected_oe property

[FONT_NAME] => [] Map whose keys contain all the fonts used
protected $usedFontsSet