Overview | Module | Use | Devguide | Index

Methods' Summary | Methods' Details | Attributes' Summary | Attributes' Details

:: com :: sun :: star :: util ::
interface XNumberFormatPreviewer
  Base Hierarchy
      ::com::sun::star::uno::XInterface
       |
       +-XNumberFormatPreviewer
Description represents a number formatter which can preview number formats without inserting them. See also NumberFormatter Developers Guide 6.2.5 Office Development - Common Application Features - Number Formats

Methods' Summary
convertNumberToPreviewString | formats a value using a format string, without inserting a number format into the list.
queryPreviewColorForNumber | returns the color which is to be used for a number.

Methods' Details
convertNumberToPreviewString
string convertNumberToPreviewString( | [in] string [in] double [in] ::com::sun::star::lang::Locale [in] boolean raises( | aFormat, fValue, nLocale, bAllowEnglish ) MalformedNumberFormatException );
Description formats a value using a format string, without inserting a number format into the list. Parameter aFormat is the format string that is used for formatting. Parameter fValue is the value that is formatted. Parameter nLocale is the locale that is used to interpret the format string. Parameter bAllowEnglish specifies if English language number format strings are accepted in addition to those from the selected locale. Returns the formatted string. Throws com::sun::star::util::MalformedNumberFormatException if the format string is invalid.
queryPreviewColorForNumber
color queryPreviewColorForNumber( | [in] string [in] double [in] ::com::sun::star::lang::Locale [in] boolean [in] color raises( | aFormat, fValue, nLocale, bAllowEnglish, aDefaultColor ) MalformedNumberFormatException );
Description returns the color which is to be used for a number. Parameter aFormat is the format string that is used for formatting. Parameter fValue is the value that is formatted. Parameter nLocale is the locale that is used to interpret the format string. Parameter bAllowEnglish specifies if English language number format strings are accepted in addition to those from the selected locale. Parameter aDefaultColor is the color that should be returned if no color is set by the number format. Returns the color that should used to output the formatted string. Throws com::sun::star::util::MalformedNumberFormatException if the format string is invalid.

Top of Page

Copyright © 2003 Sun Microsystems, Inc.