Share via


InputScope (Compact 7)

3/12/2014

This enumeration contains all of the limiting factors that you can apply to the edit control.

Syntax

typedef enum
{
        // Extended InputScope values
        IS_PHRASELIST = -1,
        IS_REGULAREXPRESSION = -2, //Reserved, not supported
        IS_SRGS = -3,
        IS_XML = -4, //Reserved, not supported
        IS_ENUMSTRING = -5, //Reserved, not supported

        // Standard InputScope values 
        IS_DEFAULT = 0x0000,
        IS_URL = 0x0001,
        IS_FILE_FULLFILEPATH = 0x0002,
        IS_FILE_FILENAME = 0x0003,
        IS_EMAIL_USERNAME = 0x0004,
        IS_EMAIL_SMTPEMAILADDRESS = 0x0005,
        IS_LOGINNAME = 0x0006,
        IS_PERSONALNAME_FULLNAME = 0x0007,
        IS_PERSONALNAME_PREFIX = 0x0008,
        IS_PERSONALNAME_GIVENNAME = 0x0009,
        IS_PERSONALNAME_MIDDLENAME = 0x000A,
        IS_PERSONALNAME_SURNAME = 0x000B,
        IS_PERSONALNAME_SUFFIX = 0x000C,
        IS_ADDRESS_FULLPOSTALADDRESS = 0x000D,
        IS_ADDRESS_POSTALCODE = 0x000E,
        IS_ADDRESS_STREET = 0x000F,
        IS_ADDRESS_STATEORPROVINCE = 0x0010,
        IS_ADDRESS_CITY = 0x0011,
        IS_ADDRESS_COUNTRYNAME = 0x0012,
        IS_ADDRESS_COUNTRYSHORTNAME = 0x0013,
        IS_CURRENCY_AMOUNTANDSYMBOL = 0x0014,
        IS_CURRENCY_AMOUNT = 0x0015,
        IS_DATE_FULLDATE = 0x0016,
        IS_DATE_MONTH = 0x0017,
        IS_DATE_DAY = 0x0018,
        IS_DATE_YEAR = 0x0019,
        IS_DATE_MONTHNAME = 0x001A,
        IS_DATE_DAYNAME = 0x001B,
        IS_DIGITS = 0x001C,
        IS_NUMBER = 0x001D,
        IS_ONECHAR = 0x001E,
        IS_PASSWORD = 0x001F,
        IS_TELEPHONE_FULLTELEPHONENUMBER = 0x0020,
        IS_TELEPHONE_COUNTRYCODE = 0x0021,
        IS_TELEPHONE_AREACODE = 0x0022,
        IS_TELEPHONE_LOCALNUMBER = 0x0023,
        IS_TIME_FULLTIME = 0x0024,
        IS_TIME_HOUR = 0x0025,
        IS_TIME_MINORSEC = 0x0026,
        IS_NUMBER_FULLWIDTH = 0x0027,
        IS_ALPHANUMERIC_HALFWIDTH = 0x0028,
        IS_ALPHANUMERIC_FULLWIDTH = 0x0029,
        IS_CURRENCY_CHINESE = 0x002A,
        IS_BOPOMOFO = 0x002B,
        IS_HIRAGANA = 0x002C,
        IS_KATAKANA_HALFWIDTH = 0x002D,
        IS_KATAKANA_FULLWIDTH = 0x002E,
        IS_HANJA = 0x002F,
        IS_YOMI = 0x0030,
        IS_APPLICATION_END = 0x0030
} InputScope

Parameters

  • IS_PHRASELIST
    The input field contains a phrase list. If IS_PHRASELIST is returned by GetInputScopes, the input method can retrieve the phrase list by using GetInputScopePhrases.
  • IS_REGULAREXPRESSION
    Reserved for desktop compatibility. Not supported.
  • IS_SRGS
    The input field contains a SRGS definition. When IS_SRGS is returned by GetInputScopes, the input method can retrieve the SRGS string by using GetInputScopeSRGS.
  • IS_XML
    Reserved for desktop compatibility. Not supported.
  • IS_ENUMSTRING
    Reserved for desktop compatibility. Not supported.
  • IS_DEFAULT
    The standard recognition bias that utilizes the default lexicon (vocabulary). If combined with another input scope, it does not force coercion on the other input scope.
  • IS_FILE_FULLFILEPATH
    The characters used in a file path, according to the following conditions:

    • For server name and share name, allows all IS_ONECHAR characters except: * ? : < > |
    • For file name, allows all IS_ONECHAR characters except: \ / : < > |
    • Input must start with \\ or drive name or \ or ..\ or .\ or /
    • Spaces are allowed.

    Examples:

    • \\servername\sharename\filename.txt
    • C:\temp\current work.doc
    • ..\images/\picture.jpg
  • IS_FILE_FILENAME
    The characters used in a file name, according to the following conditions:

    • Accepts either extension or no extension.
    • Allows all IS_ONECHAR characters except: \ / : < > |
    • Spaces are allowed.

    Examples:

    • filename.txt
    • filename
    • file name.txt
  • IS_EMAIL_USERNAME
    An email user name or email alias. This is generally the characters to the left of the @ (at) character in an email address.
  • IS_EMAIL_SMTPEMAILADDRESS
    A complete SMTP email address. For example, someone@example.com.
  • IS_LOGINNAME
    A login name or a login name and domain, according to the following conditions:

    • Allows all IS_ONECHAR characters.
    • Does not allow domain or username to start or end in a non-alphanumeric character.
    • Spaces are not allowed.
    • The following characters are not allowed: + * / (plus sign, asterisk, forward slash).
  • IS_PERSONALNAME_FULLNAME
    A combination of the first, middle, and last names, possibly including a prefix or suffix.
  • IS_PERSONALNAME_PREFIX
    Honorific or title preceding a name.
  • IS_PERSONALNAME_GIVENNAME
    First name or initial.
  • IS_PERSONALNAME_MIDDLENAME
    Middle name or initial.
  • IS_PERSONALNAME_SURNAME
    Last name or family name.
  • IS_PERSONALNAME_SUFFIX
    Name suffix abbreviations and Roman numerals.
  • IS_ADDRESS_FULLPOSTALADDRESS
    Full address, including numbers. Generally includes a street address or post office box, a town or city, a state or province, and a postal code.
  • IS_ADDRESS_POSTALCODE
    Alphanumeric postal code. May include hyphens.
  • IS_ADDRESS_STREET
    House number, street name, apartment name and number, or postal box.
  • IS_ADDRESS_STATEORPROVINCE
    Full name or abbreviation of state or province.
  • IS_ADDRESS_CITY
    Name or abbreviation of city.
  • IS_ADDRESS_COUNTRYNAME
    Name of country/region.
  • IS_ADDRESS_COUNTRYSHORTNAME
    Abbreviation for country/region.
  • IS_CURRENCY_AMOUNTANDSYMBOL
    Currency symbols and numbers.
  • IS_CURRENCY_AMOUNT
    Numeric values for currency, excluding currency symbols.
  • IS_DATE_FULLDATE
    Full date, in many possible formats. Generally specifies a month, day, and sometimes a year.
  • IS_DATE_MONTH
    Numeric representation of months, a value from 1 through 12.
  • IS_DATE_DAY
    Numeric representation of days, a value from 1 through 31.
  • IS_DATE_YEAR
    Numeric representation of years. May include two digits, four digits, and possibly an apostrophe.
  • IS_DATE_MONTHNAME
    Month name or month abbreviation, in words.
  • IS_DATE_DAYNAME
    Day name or day abbreviation, in words.
  • IS_DIGITS
    Positive whole numbers. Digit strings made of 0 through 9 are allowed.
  • IS_NUMBER
    Numbers, including commas, negative sign, and decimal.
  • IS_ONECHAR
    A single ANSI character, code page 1252. For United States locales, this includes the following characters:

    ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789!\"#$%&'()*+,-./:;<=>?@[\]^_`{|}~

  • IS_PASSWORD
    Not used by Windows Embedded Compact recognizers.
  • IS_TELEPHONE_FULLTELEPHONENUMBER
    Telephone number. May include country/region codes, area codes, or extensions. Does not support letters. May include formatting symbols, including spaces, decimals, hyphens, parentheses, plus signs, extension indicators (x).
  • IS_TELEPHONE_COUNTRYCODE
    Telephone country/region codes. May be preceded by a plus sign (+).
  • IS_TELEPHONE_AREACODE
    Telephone area codes. May be surrounded by parentheses.
  • IS_TELEPHONE_LOCALNUMBER
    Telephone number, excluding country/region or area code.
  • IS_TIME_FULLTIME
    Hours, minutes, seconds, and alphabetic time abbreviations. US English uses the 12 hour clock. Leading zeros are optional for hours but required for minutes and seconds. Hours can be a value from 0 through 24; minutes and seconds can be values from 0 through 59.
  • IS_TIME_HOUR
    Numeric representation of hours. A value from 0 through 24.
  • IS_TIME_MINORSEC
    Numeric representation of minutes or seconds. A value from 0 through 59.
  • IS_NUMBER_FULLWIDTH
    Full-width number (Japanese locales only). Includes only full-width numbers and Kanji numbers.
  • IS_ALPHANUMERIC_HALFWIDTH
    Half-width alphanumeric (East-Asian languages only). Includes only half-width alphabet characters and numbers.
  • IS_ALPHANUMERIC_FULLWIDTH
    Full-width alphanumeric (East-Asian languages only). Includes only full-width alphabet characters and numbers.
  • IS_CURRENCY_CHINESE
    Reserved.
  • IS_BOPOMOFO
    Reserved.
  • IS_HIRAGANA
    Reserved.
  • IS_KATAKANA_HALFWIDTH
    Reserved.
  • IS_KATAKANA_FULLWIDTH
    Reserved.
  • IS_HANJA
    Reserved.
  • IS_YOMI
    Reserved.

Remarks

Input scopes enable an application to define the type of input that an edit control can receive, such as addresses, names, numbers, or selections from a defined list. By specifying the type of input for each edit control, a user enters input faster and more accurately.

The standard InputScope values describe the type of data required for the input field. You can set one or more of these values to an input field with SetInputScope or SetInputScopes, and input methods can retrieve the value set for the application by using GetInputScopes.

You use extended InputScope values only when input methods call GetInputScopes to retrieve input scopes. These values indicate that additional data applies to an input field.

The following table explains how the InputScope values are translated to the legacy EIM_* values that are shown in EM_GETINPUTMODE.

Input Scope EIM Mode

IS_DEFAULT

EIM_SPELL

IS_URL

EIM_SPELL

IS_FILE_FULLFILEPATH

EIM_SPELL

IS_FILE_FILENAME

EIM_SPELL

IS_EMAIL_USERNAME

EIM_SPELL

IS_EMAIL_SMTPEMAILADDRESS

EIM_SPELL

IS_LOGINNAME

EIM_SPELL

IS_PERSONALNAME_FULLNAME

EIM_SPELL + IMMF_SHIFT

IS_PERSONALNAME_PREFIX

EIM_SPELL + IMMF_SHIFT

IS_PERSONALNAME_GIVENNAME

EIM_SPELL + IMMF_SHIFT

IS_PERSONALNAME_MIDDLENAME

EIM_SPELL + IMMF_SHIFT

IS_PERSONALNAME_SURNAME

EIM_SPELL + IMMF_SHIFT

IS_PERSONALNAME_SUFFIX

EIM_SPELL + IMMF_SHIFT

IS_ADDRESS_FULLPOSTALADDRESS

EIM_SPELL + IMMF_SHIFT

IS_ADDRESS_POSTALCODE

EIM_SPELL

IS_ADDRESS_STREET

EIM_SPELL

IS_ADDRESS_STATEORPROVINCE

EIM_SPELL + IMMF_SHIFT

IS_ADDRESS_CITY

EIM_SPELL + IMMF_SHIFT

IS_ADDRESS_COUNTRYNAME

EIM_SPELL + IMMF_SHIFT

IS_ADDRESS_COUNTRYSHORTNAME

EIM_SPELL + IMMF_CAPSLOCK

IS_CURRENCY_AMOUNTANDSYMBOL

EIM_NUMBERS

IS_CURRENCY_AMOUNT

EIM_NUMBERS

IS_DATE_FULLDATE

EIM_NUMBERS

IS_DATE_MONTH

EIM_NUMBERS

IS_DATE_DAY

EIM_NUMBERS

IS_DATE_YEAR

EIM_NUMBERS

IS_DATE_MONTHNAME

EIM_SPELL + IMMF_SHIFT

IS_DATE_DAYNAME

EIM_SPELL + IMMF_SHIFT

IS_DIGITS

EIM_NUMBERS

IS_NUMBER

EIM_NUMBERS

IS_ONECHAR

EIM_SPELL

IS_PASSWORD

EIM_SPELL

IS_TELEPHONE_FULLTELEPHONENUMBER

EIM_NUMBERS

IS_TELEPHONE_COUNTRYCODE

EIM_NUMBERS

IS_TELEPHONE_AREACODE

EIM_NUMBERS

IS_TELEPHONE_LOCALNUMBER

EIM_NUMBERS

IS_TIME_FULLTIME

EIM_NUMBERS

IS_TIME_HOUR

EIM_NUMBERS

IS_TIME_MINORSEC

EIM_NUMBERS

IS_NUMBER_FULLWIDTH

EIM_NUMBERS

IS_ALPHANUMERIC_HALFWIDTH

EIM_SPELL

IS_ALPHANUMERIC_FULLWIDTH

EIM_SPELL

IS_CURRENCY_CHINESE

EIM_SPELL

IS_BOPOMOFO

EIM_TEXT

IS_HIRAGANA

EIM_TEXT

IS_KATAKANA_HALFWIDTH

EIM_TEXT

IS_KATAKANA_FULLWIDTH

EIM_TEXT

IS_HANJA

EIM_TEXT

Undefined

InputScopes that are not defined in this table set the default mode to EIM_SPELL.

If more than one input scope is set, the input scope API will set the legacy mode based on the following priority ranking:

  1. EIM_SPELL+IMMF_SHIFT
  2. EIM_SPELL
  3. EIM_SPELL+IMMF_CAPSLOCK
  4. EIM_NUMBERS
  5. EIM_TEXT

InputScope-aware IMEs must ignore the legacy EIM_* value if an Input Scope function returns an input scope other than IS_DEFAULT. Application developers must use the SetInputScope function exclusively and avoid using the legacy EM_SETINPUTMODE message, if possible. If the IMMF_DEFAULT flag is set on an edit control, it indicates that the control accepts the legacy input modes, EM_SETINPUTMODE and SHSetImeMode.

SetInputScope only sets the legacy input mode if IMMF_DEFAULT is currently set for the control.

Requirements

Header

inputscope.h

See Also

Reference

Input Scope Enumerations
Input Method Editor Reference