Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 3.11.x will end 14 Nov 2022 (12 months plus 6 months extension).
  • Bug fixes for security issues in 3.11.x will end 13 Nov 2023 (18 months plus 12 months extension).
  • PHP version: minimum PHP 7.3.0 Note: minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is supported too.

Differences Between: [Versions 310 and 311] [Versions 39 and 311]

(no description)

File Size: 509 lines (10 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class


Class: Style  - X-Ref

Class Style
Represents a style to be applied to a cell

getId()   X-Ref

return: int|null

setId($id)   X-Ref

param: int $id
return: Style

getBorder()   X-Ref

return: Border

setBorder(Border $border)   X-Ref

param: Border $border
return: Style

shouldApplyBorder()   X-Ref

return: bool

isFontBold()   X-Ref

return: bool

setFontBold()   X-Ref

return: Style

hasSetFontBold()   X-Ref

return: bool

isFontItalic()   X-Ref

return: bool

setFontItalic()   X-Ref

return: Style

hasSetFontItalic()   X-Ref

return: bool

isFontUnderline()   X-Ref

return: bool

setFontUnderline()   X-Ref

return: Style

hasSetFontUnderline()   X-Ref

return: bool

isFontStrikethrough()   X-Ref

return: bool

setFontStrikethrough()   X-Ref

return: Style

hasSetFontStrikethrough()   X-Ref

return: bool

getFontSize()   X-Ref

return: int

setFontSize($fontSize)   X-Ref

param: int $fontSize Font size, in pixels
return: Style

hasSetFontSize()   X-Ref

return: bool

getFontColor()   X-Ref

return: string

setFontColor($fontColor)   X-Ref
Sets the font color.

param: string $fontColor ARGB color (@see Color)
return: Style

hasSetFontColor()   X-Ref

return: bool

getFontName()   X-Ref

return: string

setFontName($fontName)   X-Ref

param: string $fontName Name of the font to use
return: Style

hasSetFontName()   X-Ref

return: bool

getCellAlignment()   X-Ref

return: string

setCellAlignment($cellAlignment)   X-Ref

param: string $cellAlignment The cell alignment
return: Style

hasSetCellAlignment()   X-Ref

return: bool

shouldApplyCellAlignment()   X-Ref

return: bool Whether specific cell alignment should be applied

shouldWrapText()   X-Ref

return: bool

setShouldWrapText($shouldWrap = true)   X-Ref

param: bool $shouldWrap Should the text be wrapped
return: Style

hasSetWrapText()   X-Ref

return: bool

shouldApplyFont()   X-Ref

return: bool Whether specific font properties should be applied

setBackgroundColor($color)   X-Ref
Sets the background color

param: string $color ARGB color (@see Color)
return: Style

getBackgroundColor()   X-Ref

return: string

shouldApplyBackgroundColor()   X-Ref

return: bool Whether the background color should be applied

setFormat($format)   X-Ref
Sets format

param: string $format
return: Style

getFormat()   X-Ref

return: string

shouldApplyFormat()   X-Ref

return: bool Whether format should be applied

isRegistered()   X-Ref

return: bool

markAsRegistered(?int $id)   X-Ref
No description

unmarkAsRegistered()   X-Ref
No description

isEmpty()   X-Ref
No description