Locale


Section contents


Overview

Defined in

ce32base.oxh

Description

<TBS>


Construction / destruction


NewLocale - Constructor

Usage

this& = NewLocale&:

Description

Creates a locale object and returns a handle which allows the object to be manipulated.

Return Value
this& An value which represents the created locale
Error Handling

If the object could not be created then an error is generated which should be trapped by an ONERR handler.

Example
  LOCAL this&

  this& = NewLocale&:
  DeleteLocale:(this&) 

DeleteLocale - Destructor

Usage

DeleteLocale:(BYREF this&)

Description

Destroys the locale object.

Arguments
BYREF this& A handle to a locale object
Example
  LOCAL this&

  this& = NewLocale&:
  DeleteLocale:(this&) 

Methods provided


LocaleAmPmSpaceBetween - get whether space between am/pm text and time

Usage

bool% = LocaleAmPmSpaceBefore%:(this&)

Description

Returns TRUE(-1) if a space should be placed before the AM/PM text..

Parameters
this& A handle to a locale object
Return value
bool% TRUE(-1) is a space should be placed before the AM/PM text, otherwise FALSE(0)

LocaleAmPmSymbolPosition - position of am/pm text

Usage

pos% = LocaleAmPmSymbolPosition%:(this&)

Description

Get whether the am/pm text should be inserted before or after the time...

Parameters
this& A handle to a locale object
Return value
pos% The locale position

LocaleClockFormat - clock format

Usage

format% = LocaleClockFormat%:(this&)

Description

Get whether the clock is an analogue or digit clock..

Parameters
this& A handle to a locale object
Return value
format% The clock format

LocaleCountryCode - get country code

Usage

code& = LocaleCountryCode&:(this&)

Description

Returns the country code which is the international dialing code prefix.

Parameters
this& A handle to a locale object
Return value
code& The country code

LocaleCurrencyDecimalPlaces - get currency decimal places

Usage

places% = LocaleCurrencyDecimalPlaces%:(this&)

Description

Returns the number of decimal places used for currency.

Parameters
this& A handle to a locale object
Return value
places% The number of decimal places used for currency

LocaleCurrencyNegativeInBrackets - get currency negative in brackets

Usage

bool% = LocaleCurrencyNegativeInBrackets%:(this&)

Description

Get whether negative currency values would be display in brackets.

Parameters
this& A handle to a locale object
Return value
bool% KTrue%(-1) if negative currency values should be display in brackets, otherwise KFalse%(0)

LocaleCurrencySpaceBetween

Usage

bool% = LocaleCurrencySpaceBetween%:(this&)

Description

Get whether a space should be placed between the currency symbol and the value.

Parameters
this& A handle to a locale object
Return value
bool% KTrue%(-1) if space should be placed between the currency symbol and the value, otherwise KFalse%(0)

LocaleCurrencySymbolPosition

Usage

bool% = LocaleCurrencySymbolPosition%:(this&)

Description

Get whether the currency symbol should be placed before or after the value.

Parameters
this& A handle to a locale object
Return value
bool% KTrue%(-1) if the currency symbol should be placed before the value, otherwise KFalse%(0)

LocaleCurrencyTriadsAllowed

Usage

bool% = LocaleCurrencyTriadsAllowed%:(this&)

Description

Get whether the currency values should be split into groups of 3 digit nunbers.

Parameters
this& A handle to a locale object
Return value
bool% KTrue%(-1) if triads are allowed in currency values, otherwise KFalse%(0)

LocaleDateFormat - get date format

Usage

format% = LocaleDateFormat%:(this&)

Description

Get the date format.

Parameters
this& A handle to a locale object
Return value
format% The date format

LocaleDateSeparator - get date separator

Usage

char% = LocaleDateSeparator%:(this&,index%)

Description

Get the date seperator index%.

The format use is as follows:

separator[0] dateComponent1 separator[1] dateComponent2 separator[2] dateComponent3 separator[3]

Parameters
this& A handle to a locale object
index% The index of the date seperator to set. Allowable values are 0 to 3
Return value
char% The character value of the date seperator

LocaleDaylightSaving

Usage

bool% = LocaleDaylightSaving%:(this&)

Description

Get whether daylight saving is in effect.

Parameters
this& A handle to a locale object
Return value
bool% KTrue%(-1) if daylight saving is in effect, otherwise KFalse%(0)

LocaleDecimalSeparator - get decimal separator

Usage

char% = LocaleDecimalSeparator%:(this&)

Description

Get the decimal seperator character.

Parameters
this& A handle to a locale object
Return value
char% The character value of the decimal seperator

LocaleHomeDaylightSavingZone - get home daylight saving zone

Usage

zone% = LocaleHomeDaylightSavingZone%:(this&)

Description

Get the home daylight saving zone.

Parameters
this& A handle to a locale object
Return value
zone% The home daylight saving zone

LocaleQueryHomeHasDaylightSavingZone - get whether home has daylight saving

Usage

bool% = LocaleQueryHomeDaylightSavingZone%:(this&)

Description

Get whether the home city has a daylight saving zone.

Parameters
this& A handle to a locale object
Return value
bool% KTrue%(-1) if home has a daylight saving zone, otherwise KFalse%(0)

LocaleRefresh - refresh with system wide settings

Usage

LocaleRefresh:(this&)

Description

Refreshes the contents of the locale object this& with the current system settings.

Parameters
this& A handle to a locale object

LocaleSet - system wide settings

Usage

LocaleSet:(this&)

Description

Sets the current system locale settings with the contents of the locale object this&.

Parameters
this& A handle to a locale object

LocaleSetAmPmSpaceBetween - set whether a space between the am/pm text

Usage

LocaleSetAmPmSpaceBetween:(this&,bool%)

Description

Set whether a space should be inserted before the am/pm text..

Parameters
this& A handle to a locale object
bool% TRUE(-1) is a space is to be inserted before the am/pm text, otherwise FALSE(0)

LocaleSetAmPmSymbolPosition- set position between the am/pm text and time

Usage

LocaleSetAmPmSymbolPosition:(this&,pos%)

Description

Set whether the am/pm text should be before or after the time.

Parameters
this& A handle to a locale object
pos% The locale position

LocaleSetClockFormat - set clock format

Usage

LocaleSetClockFormat:(this&,format%)

Description

Set whether the clock should be analogue or digit.

Parameters
this& A handle to a locale object
format% The clock format

LocaleSetCountryCode - set country code

Usage

LocaleSetCountryCode:(this&,code&)

Description

Set the country code which is the international dialing code prefix.

Parameters
this& A handle to a locale object
code& The country code

LocaleSetCurrencyDecimalPlaces - set currency decimal places

Usage

LocaleSetCurrencyDecimalPlaces:(this&,places&)

Description

Set the number of deciaml places in a currency value.

Parameters
this& A handle to a locale object
places& The number of decimal places

LocaleSetCurrencyNegInBrackets - set currency negative in brackets

Usage

LocaleSetCurrencyNegInBrackets:(this&,bool%)

Description

Set whether negative values should be displayed in brackets.

Parameters
this& A handle to a locale object
bool% KTrue%(-1) if negative values should be displayed in brackets, otherwise KFalse%(0)

LocaleSetCurrencySpaceBetween - set currency space between

Usage

LocaleSetCurrencySpaceBetween:(this&,bool%)

Description

Set whether a space should be inserted between the currency symbol and the value.

Parameters
this& A handle to a locale object
bool% KTrue%(-1) if a space should be displayed between the currency symbol and value, otherwise KFalse%(0)

LocaleSetCurrencySymbolPosition - set currency symbol position

Usage

LocaleSetCurrencySymbolPosition:(this&,bool%)

Description

Set whether the currency symbol should be inserted before or after the value.

Parameters
this& A handle to a locale object
bool% KTrue%(-1) if the currency symbol should be display before the value, otherwise KFalse%(0)

LocaleSetCurrencyTriadsAllowed - set currency triad allowed

Usage

LocaleSetCurrencyTriadsAllowed:(this&,bool%)

Description

Set whether triads are allowed in currency values.

Parameters
this& A handle to a locale object
bool% KTrue%(-1) if triads are allowed in currency values, otherwise KFalse%(0)

LocaleSetDateFormat - set date format

Usage

LocaleSetDateFormat:(this&,format%)

Description

Set the date format.

Parameters
this& A handle to a locale object
format% The date format

LocaleSetDateSeparator - set date separator

Usage

LocaleSetDateSeparator&:(this&,char%,index%)

Description

Set the date seperator index% with the character char%.

The format use is as follows:

separator[0] dateComponent1 separator[1] dateComponent2 separator[2] dateComponent3 separator[3]

Parameters
this& A handle to a locale object
char% The character value to set the date seperator
index% The index of the date seperator to set. Allowable values are 0 to 3

LocaleSetDaylightSaving - set daylight saving

Usage

LocaleSetDaylightSaving:(this&,bool%)

Description

Set whether daylight saving is in effect.

Parameters
this& A handle to a locale object
bool% KTrue%(-1) if daylight saving is in effect, otherwise KFalse%(0)

LocaleSetDecimalSeparator - set decimal separator

Usage

LocaleSetDecimalSeparator:(this&,char%)

Description

Set the decimal separator with the character char%.

Parameters
this& A handle to a locale object
char% The character value to set the decimal seperator

LocaleSetHomeDaylightSavingZone - set home daylight saving zone

Usage

LocaleSetHomeDaylightSavingZone:(this&,zone&)

Description

Set the home daylight saving zone.

Parameters
this& A handle to a locale object
zone& The daylight saving zone

LocaleSetStartOfWeek - set start of week

Usage

LocaleSetStartOfWeek:(this&,day%)

Description

Set the day of the week which is to be concidered the start of a week.

Parameters
this& A handle to a locale object
day% A day of the week

LocaleSetThousandsSeparator - set thousands separator

Usage

LocaleSetThousandsSeparator:(this&,char%)

Description

Set the thousands separator with the character char%.

Parameters
this& A handle to a locale object
char% The character value to set as the thousands separator

LocaleSetTimeFormat - set time format

Usage

LocaleSetTimeFormat:(this&,format%)

Description

Set the thousands separator with the character char%.

Parameters
this& A handle to a locale object
char% The character value to set as the thousands separator

LocaleSetTimeSeparator - set time separator

Usage

LocaleSetTimeSeparator&:(this&,char%,index%)

Description

Set the time separator index% with the character char%.

The format use is as follows:

separator[0] hour separator[1] minute separator[2] seconds separator[3]

Parameters
this& A handle to a locale object
char% The character value to set the time seperator
index% The index of the date seperator to set. Allowable values are 0 to 3

LocaleSetUnitsDistanceLong - set units for long distances

Usage

LocaleSetUnitsDistanceLong:(this&,units%)

Description

Set the units used for long distances..

Parameters
this& A handle to a locale object
units% The units to use for long distances

LocaleSetUnitsDistanceShort - set units for short distances

Usage

LocaleSetUnitsDistanceShort:(this&,units%)

Description

Set the units used for short distances..

Parameters
this& A handle to a locale object
units% The units to use for short distances

LocaleSetUnitsGeneral - set units

Usage

LocaleSetUnitsGeneral:(this&,units%)

Description

Set the units used for units..

Parameters
this& A handle to a locale object
units% The units to use

LocaleSetWorkDays - set work days

Usage

LocaleSetWorkDays:(this&,mask%)

Description

Set the days of the week that are to be concidered work days..

Parameters
this& A handle to a locale object
mask% A mask which contains a set bit for each day of the week which is a work day

LocaleStartOfWeek - get start of week

Usage

day% = LocaleStartOfWeek%:(this&)

Description

Get the day of the week that is to be concidered the first day of the week.

Parameters
this& A handle to a locale object
Return value
day% A day of the week

LocaleTimeSeparator - get time separator

Usage

char% = LocaleTimeSeparator%:(this&,index%)

Description

Set the time separator index% with the character char%.

The format use is as follows:

separator[0] hours separator[1] minutes separator[2] second separator[3]

Parameters
this& A handle to a locale object
index% The index of the time seperator to set. Allowable values are 0 to 3
Return value
char% The character value of the time separator

LocaleThousandsSeparator - get thousands separator

Usage

char% = LocaleThousandsSeparator%:(this&)

Description

Get the thousands separator character.

Parameters
this& A handle to a locale object
Return value
char% The character value of the thousand separator

LocaleUnitsDistanceLong - get units for long distances

Usage

units% = LocaleUnitsDistanceLong%:(this&)

Description

Get the units to be used for long distances.

Parameters
this& A handle to a locale object
Return value
units% The units of measurement

LocaleUnitsDistanceShort - get units for short distances

Usage

units% = LocaleUnitsDistanceShort%:(this&)

Description

Get the units to be used for short distances.

Parameters
this& A handle to a locale object
Return value
units% The units of measurement

LocaleUnitsGeneral - get units of measurement

Usage

units% = LocaleUnitsGeneral%:(this&)

Description

Get the units to be used for measurements.

Parameters
this& A handle to a locale object
Return value
units% The units of measurement

LocaleWorkDays - get work days

Usage

mask% = LocaleWorkDays%:(this&)

Description

Get the days of the week that are to be concidered work days..

Parameters
this& A handle to a locale object
Return value
mask% A mask which contains a set bit for each day of the week which is a work day