Moodle PHP Documentation 5.1
Moodle 5.1dev (Build: 20250711) (9addea9f0ac)
OpenSpout\Common\Entity\Style\Style Class Reference

Public Member Functions

 __sleep ()
 
 getBackgroundColor ()
 
 getBorder ()
 
 getCellAlignment ()
 
 getCellVerticalAlignment ()
 
 getFontColor ()
 
 getFontName ()
 
 getFontSize ()
 
 getFormat ()
 
 getId ()
 
 hasSetCellAlignment ()
 
 hasSetCellVerticalAlignment ()
 
 hasSetFontBold ()
 
 hasSetFontColor ()
 
 hasSetFontItalic ()
 
 hasSetFontName ()
 
 hasSetFontSize ()
 
 hasSetFontStrikethrough ()
 
 hasSetFontUnderline ()
 
 hasSetShrinkToFit ()
 
 hasSetTextRotation ()
 
 hasSetWrapText ()
 
 isEmpty ()
 
 isFontBold ()
 
 isFontItalic ()
 
 isFontStrikethrough ()
 
 isFontUnderline ()
 
 isRegistered ()
 
 markAsRegistered (?int $id)
 
 setBackgroundColor (string $color)
 Sets the background color.
 
 setBorder (Border $border)
 
 setCellAlignment (string $cellAlignment)
 
 setCellVerticalAlignment (string $cellVerticalAlignment)
 
 setFontBold ()
 
 setFontColor (string $fontColor)
 Sets the font color.
 
 setFontItalic ()
 
 setFontName (string $fontName)
 
 setFontSize (int $fontSize)
 
 setFontStrikethrough ()
 
 setFontUnderline ()
 
 setFormat (string $format)
 Sets format.
 
 setId (int $id)
 
 setShouldShrinkToFit (bool $shrinkToFit=true)
 Sets should shrink to fit.
 
 setShouldWrapText (bool $shouldWrap=true)
 
 setTextRotation (int $rotation)
 
 shouldApplyCellAlignment ()
 
 shouldApplyCellVerticalAlignment ()
 
 shouldApplyFont ()
 
 shouldShrinkToFit ()
 
 shouldWrapText ()
 
 textRotation ()
 

Public Attributes

const DEFAULT_FONT_COLOR = Color::BLACK
 
const DEFAULT_FONT_NAME = 'Arial'
 
const DEFAULT_FONT_SIZE = 11
 Default values.
 

Member Function Documentation

◆ setBackgroundColor()

OpenSpout\Common\Entity\Style\Style::setBackgroundColor ( string $color)

Sets the background color.

Parameters
string$colorARGB color (
See also
Color)

◆ setCellAlignment()

OpenSpout\Common\Entity\Style\Style::setCellAlignment ( string $cellAlignment)
Parameters
string$cellAlignmentThe cell alignment

◆ setCellVerticalAlignment()

OpenSpout\Common\Entity\Style\Style::setCellVerticalAlignment ( string $cellVerticalAlignment)
Parameters
string$cellVerticalAlignmentThe cell vertical alignment

◆ setFontColor()

OpenSpout\Common\Entity\Style\Style::setFontColor ( string $fontColor)

Sets the font color.

Parameters
string$fontColorARGB color (
See also
Color)

◆ setFontName()

OpenSpout\Common\Entity\Style\Style::setFontName ( string $fontName)
Parameters
string$fontNameName of the font to use

◆ setFontSize()

OpenSpout\Common\Entity\Style\Style::setFontSize ( int $fontSize)
Parameters
int$fontSizeFont size, in pixels

◆ setShouldWrapText()

OpenSpout\Common\Entity\Style\Style::setShouldWrapText ( bool $shouldWrap = true)
Parameters
bool$shouldWrapShould the text be wrapped

◆ setTextRotation()

OpenSpout\Common\Entity\Style\Style::setTextRotation ( int $rotation)
Parameters
int$rotationRotate text

◆ shouldApplyCellAlignment()

OpenSpout\Common\Entity\Style\Style::shouldApplyCellAlignment ( )
Return values
boolWhether specific cell alignment should be applied

◆ shouldApplyFont()

OpenSpout\Common\Entity\Style\Style::shouldApplyFont ( )
Return values
boolWhether specific font properties should be applied

◆ shouldShrinkToFit()

OpenSpout\Common\Entity\Style\Style::shouldShrinkToFit ( )
Return values
boolWhether format should be applied

The documentation for this class was generated from the following file: