Behold the Table Driven Text Service, Part 8 (Configuration 'junk in the trunk', part 2)

by Michael S. Kaplan, published on 2008/02/11 10:16 -05:00, original URI: http://blogs.msdn.com/b/michkap/archive/2008/02/11/7588649.aspx


Prior posts in the series:

After last time, I had it impressed on me that the majoritry of the people who read this series over time will not care so much about the order of blogs as the actual information, so that posts wih settings in them before every single window is fully defined is not necessarily a bad thing.

So today we're going to do some more settings! :-)

Configuration section for text candidate list window

This is group for text candidate list window however should be inside “[Configuration]” section.

Text candidate list item should sort by keystroke order.

Form of keystroke sort is:
KeystrokeSort = integer value
Where:     0     - turn off keystroke sort (default)
           Not 0 – turn on keystroke sort

Text candidate list item should sort by text string order.

Form of text sort is:
TextSort = integer value
Where:     0     - turn off text sort (default)
           Not 0 – turn on text sort

Form of hide text candidate list window is:

CandidateList.Text.HideWindow = integer value
Where:     0     - show text candidate window (default)
           Not 0 – hide text candidate window

When convert some keystroke and result of text candidate list item is only one item or if phrase file is available however doesn’t find match phrase list with converted key, then converted key should finalized.

Form of conversion only one item is:

Composition.ConversionOnlyOneItem = integer value
Where:     0     - turn off conversion only one item (default)
           Not 0 – turn on conversion only one item

For example, Chinese Traditional Array, keystroke “AAES” has only one text string as "虣", and phrase file doesn’t have it character. In this keystroke, character "虣" is finalized when press Conversion key.

When convert some keystroke and result of text candidate list item is only one item or if phrase file is available however doesn’t find match phrase list with converted key, then converted key should finalized.

Form of conversion only one item on convert is:

Composition.ConversionOnlyOneItemOnConvert = integer value
Where:     0     - turn off conversion only one item on convert (default)
           Not 0 – turn on conversion only one item on convert

For example, Chinese Traditional DaYi, keystroke “,,,” has only one text string as “劦”, and phrase file doesn’t have it character. In this keystroke, character “劦” is finalized when press Conversion key.

You might be wondering at this point: What is different with ConversionOnlyOneItem and ConversionOnlyOneItemOnConvert?

Imagine you have two different profiles (one with each setting). Both profiles defined below strings which particular keystroke should be one candidate converted string.

[Text]
"KB" = "㎅"
"MB" = "㎆"
"GB" = "㎇"
"Hz" = "㎐"
"kHz" = "㎑"
"MHz" = "㎒"
"GHz" = "㎓"
"THz" = "㎔"

In “ConversionOnlyOneItem” profile, when we type “kb”, then converted string “㎅” is finalized immediately.

On the other hand, in “ConversionOnlyOneItemOnConvert” profile, when we type “kb”, then converted string “㎅” is not yet finalized until we press Convert key.

Configuration section for phrase candidate list window

This is group for phrase list window however should be inside “[Configuration]” section.

Phrase candidate list item should sort by phrase string order.

Form of phrase sort is:

PhraseSort = integer value
Where:     0     - turn off phrase sort (default)
           Not 0 – turn on phrase sort

If profile doesn’t have phrase file, however would like to shows some phrase which browse from text dictionary, then turn this switch on.

Form of make phrase from text is:

MakePhraseFromText = integer value

For example, Chinese Simplified QuanPin, keystroke “ZHONG” shows some texts and select one item which “中”, then Table Driven TIP makes phrase list as start “中” character into text dictionary which phrase list corrected below:

"zhongbiao"="中标"
"zhongbu"="中部"
"zhongceng"="中层"
"zhongdang"="中档"
"zhongdeng"="中等"
"zhongdengche"="中等城市"
"zhongdengjia"="中等教育"

Form of hide phrase candidate list window is:

CandidateList.Phrase.HideWindow = integer value
Where:     0     - show phrase candidate window (default)
           Not 0 – hide phrase candidate window

Show title on phrase candidate window with specified string.

Form of title of phrase candidate list window is:

CandidateList.Phrase.Title = String value

For example, Chinese Traditional DaYi has “Shift + Numeric” string in title bar when keystroke “A”+”Space”+”Space”.

For select an item in phrase candidate list by keyboard, could be specified some modifier value.

Form of modifier of phrase candidate list window is:

CandidateList.Phrase.Modifier = Modifier value
Where:     Modifier value is TF_MOD_xxx value, as previously discussed here.

For example, Chinese Tradition DaYi has TF_MOD_SHIFT which phrase candidate item should finalized by Shift + Numeric key.

Preserved key section

Preserved key section should begin as “[PreservedKey]” section name.

Table Driven TIP could specify below three preserved keys:

Each preserved key has similar item which is:

In [PreservedKey] section, Table Driven TIP could see the below definitions specified:

Preserved key section for IME mode
GuidImeMode = GUID value
KeyDefineImeMode = Key code value
DescriptionImeMode = String value
ImeMode = integer value

Preserved key section for Double/Single byte
GuidDoubleSingleByte = GUID value
KeyDefineDoubleSingleByte = Key code value
DescriptionDoubleSingleByte = String value
DoubleSingleByte = integer value

Preserved key section for Punctuation
GuidPunctuation = GUID value
KeyDefinePunctuation = Key code value
DescriptionPunctuation = String value
Punctuation = integer value

Language bar section

Language bar section should begin as “[LanguageBar]” section name.

Table Driven TIP can specify the below three language bars:

Each language bar has similar items, which are:

The icon file/index entries are the same as were prevuously discussed here.

In [LanguageBar] section, Table Driven TIP could specifiy the following definitions:

Language bar section for IME mode
DescriptionImeMode = String value
TooltipImeMode = String value
EnableImeMode = integer value
ImeModeOnIcon = Path and file name value
ImeModeOnIconIndex = integer value or predefined value
ImeModeOffIcon = Path and file name value
ImeModeOffIconIndex = integer value or predefined value

Language bar section for Double/Single byte
DescriptionDoubleSingleByte = String value
TooltipDoubleSingleByte = String value
EnableDoubleSingleByte = integer value
DoubleSingleByteOnIcon = Path and file name value
DoubleSingleByteOnIconIndex = integer value or predefined value
DoubleSingleByteOffIcon = Path and file name value
DoubleSingleByteOffIconIndex = integer value or predefined value

Language bar section for Punctuation
DescriptionPunctuation = String value
TooltipPunctuation = String value
EnablePunctuation = integer value
PunctuationOnIcon = Path and file name value
PunctuationOnIconIndex = integer value or predefined value
PunctuationOffIcon = Path and file name value
PunctuationOffIconIndex = integer value or predefined value

Shortcut section

Table Driven TIP could define shortcut keys for text candidate list.

In [Candidate.Shortcut.Original] section, form is below and integer value is mentioned as item number in candidate list.

“Key” = integer value

Next part, I'll finish up the definitions by defining the actual content sections of the file, and jump into some more examples. Stay tuned!


no comments

Please consider a donation to keep this archive running, maintained and free of advertising.
Donate €20 or more to receive an offline copy of the whole archive including all images.

referenced by

2008/10/21 Behond the Table Driven Text Service, Part 14 (Don't expect too much from numbers)

2008/07/25 Behold the Table Driven Text Service, Part 13 (Sinhalification proclamation!)

2008/06/30 Behold the Table Driven Text Service, Part 12 (The knights who say நீ, redux, #2)

2008/06/21 Back to Sri Lanka (conceptually)

2008/02/25 Behold the Table Driven Text Service, Part 11 (The knights who say நீ, redux, #1)

2008/02/15 Behold the Table Driven Text Service, Part 10 ("Even Jove nods," Atlas shrugged, "so we'll convert their old files, now.")

2008/02/12 Behold the Table Driven Text Service, Part 9 (Will you be content if I tell you how some content can be defined?)

go to newer or older post, or back to index or month or day