JavaScript Editor js editor     Web development 

Main Page

Specifies the character set, or language script, of the font used to display text for every object that supports fonts. Read/write at design and run time.

Object.FontCharSet [ = nFontCharSet ]


Term Definition


Specifies a numerical value for the language script you want.


Applies To: CheckBox Control | Column Object | ComboBox Control | CommandButton Control | EditBox Control | Form Object | Grid Control | Header Object | Label Object | ListBox Control | OptionButton Control | Page Object | _SCREEN System Variable | Spinner Control | TextBox Control (Visual FoxPro)

The operating system and font determine the default setting for FontCharSet. Setting FontCharSet to 1 indicates the Visual FoxPro to use the default setting. If you set FontCharSet in the Properties window explicitly by choosing a language script from the Font dialog box, the Properties window displays the specific font. For example, suppose you set the FontCharSet property for a text box to 1 (Western) in the Properties window. If you open the Font Picker Dialog Box and select 0 (Western), the Properties window displays 0 (Western) because it was set explicitly.

To reset the property to the default setting, right-click the property in the Properties window and click Reset to Default.

Visual FoxPro attempts to retrieve the character set identifier for the font you specify. If Visual FoxPro cannot find the character set identifier, or if you pass an invalid FontCharSet value for a particular font set, the Windows font manager makes the appropriate substitution using the Default character set, usually ANSI or Symbol.

Fonts support only certain language scripts. To choose a language script that a font can support, select the FontCharSet property in the Properties window and click the ellipsis (...) button that appears to open the Font dialog box. You can select a language script from the Script drop-down list. You can also change the font, size, and style. Visual FoxPro updates the font properties with the changed values.

If you change the font to one for which the current FontCharSet value is not supported, Visual FoxPro resets the FontCharSet property.

If the Style property for a Label is set to 3 (Themed), the FontCharSet property is ignored. If the Themes property is set to True (.T.) for a grid, the FontCharSet property for the grid Header is ignored. To display the grid Header using the FontCharSet property, set Themes of the grid to False (.F.).

The GETFONT(В ) function supports the passing or retrieving of a font script.

See Also

JavaScript Editor js editor     Web development