- Home
- About
- Testimonials
- Demos
- Download
- Documentation
- Blogs
- Forum
- Support

Packages:
default
System
System.Caching
System.Collections
System.Data
System.Data.ActiveRecord
System.Data.ActiveRecord.Relations
System.Data.ActiveRecord.Scaffold
System.Data.ActiveReecord.Scaffold.InputBuilder
System.Data.Commom.Sqlite
System.Data.Common
System.Data.Common.Mssql
System.Data.Common.Mysql
System.Data.Common.Oracle
System.Data.Common.Pgsql
System.Data.Common.Sqlite
System.Data.DataGateway
System.Data.SqlMap
System.Data.SqlMap.Configuration
System.Data.SqlMap.Statements
System.Exceptions
System.I18N
System.IO
System.Security
System.Util
System.Web
System.Web.Services
System.Web.UI
System.Web.UI.ActiveControls
System.Web.UI.WebControls
System.Web.UI.WebControls.assets
System.Xml
Classes:
IDataSource
IItemDataRenderer
IRepeatInfoUser
TActiveFileUpload
TBaseDataList
TBaseValidator
TBoundColumn
TBulletedList
TBulletedListDisplayMode
TBulletedListEventParameter
TBulletStyle
TButton
TButtonColumn
TButtonColumnType
TButtonType
TCaptcha
TCaptchaValidator
TCheckBox
TCheckBoxColumn
TCheckBoxList
TCircleHotSpot
TClientScript
TClientScriptLoader
TClientSideValidationSummaryOptions
TColorPicker
TColorPickerClientSide
TColorPickerMode
TCompareValidator
TCompleteWizardStep
TConditional
TContent
TContentDirection
TContentPlaceHolder
TCustomValidator
TDataBoundControl
TDataGrid
TDataGridColumn
TDataGridColumnCollection
TDataGridCommandEventParameter
TDataGridItem
TDataGridItemCollection
TDataGridItemEventParameter
TDataGridItemRenderer
TDataGridPageChangedEventParameter
TDataGridPager
TDataGridPagerButtonType
TDataGridPagerEventParameter
TDataGridPagerMode
TDataGridPagerPosition
TDataGridPagerStyle
TDataGridSortCommandEventParameter
TDataList
TDataListCommandEventParameter
TDataListItem
TDataListItemCollection
TDataListItemEventParameter
TDataListItemRenderer
TDataRenderer
TDataSourceControl
TDataSourceSelectParameters
TDataSourceView
TDataTypeValidator
TDatePicker
TDatePickerClientScript
TDatePickerInputMode
TDatePickerMode
TDatePickerPositionMode
TDisplayStyle
TDraggable
TDropContainer
TDropDownList
TDropDownListColumn
TEditCommandColumn
TEmailAddressValidator
TExpression
TFileUpload
TFont
THiddenField
THorizontalAlign
THotSpot
THotSpotCollection
THotSpotMode
THtmlArea
THtmlElement
THyperLink
THyperLinkColumn
TImage
TImageButton
TImageClickEventParameter
TImageMap
TImageMapEventParameter
TInlineFrame
TInlineFrameAlign
TInlineFrameScrollBars
TItemDataRenderer
TJavascriptLogger
TKeyboard
TLabel
TLinkButton
TListBox
TListControl
TListControlValidator
TListItem
TListItemCollection
TListItemType
TListSelectionMode
TLiteral
TLiteralColumn
TMarkdown
TMetaTag
TMetaTagCollection
TMultiView
TOutputCache
TOutputCacheCalculateKeyEventParameter
TOutputCacheCheckDependencyEventParameter
TPager
TPagerButtonType
TPagerMode
TPagerPageChangedEventParameter
TPanel
TPanelStyle
TPlaceHolder
TPolygonHotSpot
TRadioButton
TRadioButtonList
TRangeValidationDataType
TRangeValidator
TRatingList
TReadOnlyDataSource
TReadOnlyDataSourceView
TRectangleHotSpot
TRegularExpressionValidator
TRepeatDirection
TRepeater
TRepeaterCommandEventParameter
TRepeaterItem
TRepeaterItemCollection
TRepeaterItemEventParameter
TRepeaterItemRenderer
TRepeatInfo
TRepeatLayout
TRequiredFieldValidator
TSafeHtml
TScrollBars
TServerValidateEventParameter
TSlider
TSliderClientScript
TSliderDirection
TStatements
TStyle
TStyleSheet
TTable
TTableCaptionAlign
TTableCell
TTableCellCollection
TTableFooterRow
TTableGridLines
TTableHeaderCell
TTableHeaderRow
TTableHeaderScope
TTableItemStyle
TTableRow
TTableRowCollection
TTableRowSection
TTableStyle
TTabPanel
TTabView
TTabViewCollection
TTemplateColumn
TTemplatedWizardStep
TTextAlign
TTextBox
TTextBoxAutoCompleteType
TTextBoxMode
TTextHighlighter
TTextHighlighterLineNumberStyle
TValidationCompareOperator
TValidationDataType
TValidationSummary
TValidationSummaryDisplayMode
TValidationSummaryDisplayStyle
TValidatorClientSide
TValidatorDisplayStyle
TVerticalAlign
TView
TViewCollection
TWebControl
TWebControlAdapter
TWizard
TWizardFinishNavigationTemplate
TWizardNavigationButtonStyle
TWizardNavigationButtonType
TWizardNavigationContainer
TWizardNavigationEventParameter
TWizardNavigationTemplate
TWizardSideBarListItemTemplate
TWizardSideBarTemplate
TWizardStartNavigationTemplate
TWizardStep
TWizardStepCollection
TWizardStepNavigationTemplate
TWizardStepType
TXmlTransform

Keyword

# Class TFont

    TComponent
       |
       --TFont

TFont class

TFont encapsulates the CSS style fields related with font settings.

Since: 3.0
Author: Qiang Xue <qiang.xue@gmail.com>

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

Methods Inherited From TComponent

TComponent::addParsedObject(), TComponent::attachEventHandler(), TComponent::canGetProperty(), TComponent::canSetProperty(), TComponent::createdOnTemplate(), TComponent::detachEventHandler(), TComponent::evaluateExpression(), TComponent::evaluateStatements(), TComponent::getEventHandlers(), TComponent::getSubProperty(), TComponent::hasEvent(), TComponent::hasEventHandler(), TComponent::hasProperty(), TComponent::raiseEvent(), TComponent::setSubProperty(), TComponent::__get(), TComponent::__set()

Constant Summary
int | IS_BOLD | Bits indicating the font states.
int | IS_ITALIC |
int | IS_OVERLINE |
int | IS_SET_BOLD | Bits indicating whether particular font states are changed.
int | IS_SET_ITALIC |
int | IS_SET_NAME |
int | IS_SET_OVERLINE |
int | IS_SET_SIZE |
int | IS_SET_STRIKEOUT |
int | IS_SET_UNDERLINE |
int | IS_STRIKEOUT |
int | IS_UNDERLINE |

Method Details

## addAttributesToRender

public void addAttributesToRender | (THtmlWriter $writer )

Adds attributes related to CSS styles to renderer.

Input
THtmlWriter | $writer | the writer used for the rendering purpose
Output
Exception

## copyFrom

public void copyFrom | (TFont $font )

Copies the fields in a new font to this font.

If a font field is set in the new font, the corresponding field in this font will be overwritten.

Input
TFont | $font | the new font
Output
Exception

## getBold

public boolean getBold | ()

Output
boolean | whether the font is in bold face. Defaults to false.
Exception

## getIsEmpty

public boolean getIsEmpty | ()

Output
boolean | whether the font is empty
Exception

## getItalic

public boolean getItalic | ()

Output
boolean | whether the font is in italic face. Defaults to false.
Exception

## getName

public string getName | ()

Output
string | the font name (family)
Exception

## getOverline

public boolean getOverline | ()

Output
boolean | whether the font is overlined. Defaults to false.
Exception

## getSize

public string getSize | ()

Output
string | the font size
Exception

## getStrikeout

public boolean getStrikeout | ()

Output
boolean | whether the font is strikeout. Defaults to false.
Exception

## getUnderline

public boolean getUnderline | ()

Output
boolean | whether the font is underlined. Defaults to false.
Exception

## mergeWith

public void mergeWith | (TFont $font )

Merges the font with a new one.

If a font field is not set in the font, it will be overwritten with the new one.

Input
TFont | $font | the new font
Output
Exception

## reset

public void reset | ()

Clears up the font.

Output
Exception

## setBold

public void setBold | (boolean $value )

Input
boolean | $value | whether the font is in bold face
Output
Exception

## setItalic

public void setItalic | (boolean $value )

Input
boolean | $value | whether the font is italic
Output
Exception

## setName

public void setName | (string $value )

Input
string | $value | the font name (family)
Output
Exception

## setOverline

public void setOverline | (boolean $value )

Input
boolean | $value | whether the font is overlined
Output
Exception

## setSize

public void setSize | (string $value )

Input
string | $value | the font size
Output
Exception

## setStrikeout

public void setStrikeout | (boolean $value )

Input
boolean | $value | whether the font is strikeout
Output
Exception

## setUnderline

public void setUnderline | (boolean $value )

Input
boolean | $value | whether the font is underlined
Output
Exception

## toString

public string toString | ()

Output
string | the font in a css style string representation.
Exception

Constant Details

### IS_BOLD

Bits indicating the font states.

#### Type:

int

#### Value:

0x01

### IS_ITALIC

#### Type:

int

#### Value:

0x02

### IS_OVERLINE

#### Type:

int

#### Value:

0x04

### IS_SET_BOLD

Bits indicating whether particular font states are changed.

#### Type:

int

#### Value:

0x01000

### IS_SET_ITALIC

#### Type:

int

#### Value:

0x02000

### IS_SET_NAME

#### Type:

int

#### Value:

0x40000

### IS_SET_OVERLINE

#### Type:

int

#### Value:

0x04000

### IS_SET_SIZE

#### Type:

int

#### Value:

0x20000

### IS_SET_STRIKEOUT

#### Type:

int

#### Value:

0x08000

### IS_SET_UNDERLINE

#### Type:

int

#### Value:

0x10000

### IS_STRIKEOUT

#### Type:

int

#### Value:

0x08

### IS_UNDERLINE

#### Type:

int

#### Value:

0x10