PHP Class Prado\Web\UI\WebControls\TFont

TFont encapsulates the CSS style fields related with font settings.
Since: 3.0
Author: Qiang Xue ([email protected])
Inheritance: extends Prado\TComponent
Mostra file Open project: pradosoft/prado

Public Methods

Method Description
addAttributesToRender ( $writer ) Adds attributes related to CSS styles to renderer.
copyFrom ( $font ) Copies the fields in a new font to this font.
getBold ( ) : boolean
getIsEmpty ( ) : boolean
getItalic ( ) : boolean
getName ( ) : string
getOverline ( ) : boolean
getSize ( ) : string
getStrikeout ( ) : boolean
getUnderline ( ) : boolean
mergeWith ( $font ) Merges the font with a new one.
reset ( ) Clears up the font.
setBold ( $value )
setItalic ( $value )
setName ( $value )
setOverline ( $value )
setSize ( $value )
setStrikeout ( $value )
setUnderline ( $value )
toString ( ) : string

Protected Methods

Method Description
_getZappableSleepProps ( &$exprops ) Returns an array with the names of all variables of this object that should NOT be serialized because their value is the default one or useless to be cached for the next page loads.

Method Details

_getZappableSleepProps() protected method

Reimplement in derived classes to add new variables, but remember to also to call the parent implementation first.
protected _getZappableSleepProps ( &$exprops )

addAttributesToRender() public method

Adds attributes related to CSS styles to renderer.
public addAttributesToRender ( $writer )

copyFrom() public method

If a font field is set in the new font, the corresponding field in this font will be overwritten.
public copyFrom ( $font )

getBold() public method

public getBold ( ) : boolean
return boolean whether the font is in bold face. Defaults to false.

getIsEmpty() public method

public getIsEmpty ( ) : boolean
return boolean whether the font is empty

getItalic() public method

public getItalic ( ) : boolean
return boolean whether the font is in italic face. Defaults to false.

getName() public method

public getName ( ) : string
return string the font name (family)

getOverline() public method

public getOverline ( ) : boolean
return boolean whether the font is overlined. Defaults to false.

getSize() public method

public getSize ( ) : string
return string the font size

getStrikeout() public method

public getStrikeout ( ) : boolean
return boolean whether the font is strikeout. Defaults to false.

getUnderline() public method

public getUnderline ( ) : boolean
return boolean whether the font is underlined. Defaults to false.

mergeWith() public method

If a font field is not set in the font, it will be overwritten with the new one.
public mergeWith ( $font )

reset() public method

Clears up the font.
public reset ( )

setBold() public method

public setBold ( $value )

setItalic() public method

public setItalic ( $value )

setName() public method

public setName ( $value )

setOverline() public method

public setOverline ( $value )

setSize() public method

public setSize ( $value )

setStrikeout() public method

public setStrikeout ( $value )

setUnderline() public method

public setUnderline ( $value )

toString() public method

public toString ( ) : string
return string the font in a css style string representation.