Set up Accent Mark Options

 

This page is to set up accent mark options for Vietnamese typing only.  This version of WinVNKey offers a rich set of options and features to support smart typing.  These options are conveniently grouped into a page and are referred to as "Viet Option Page".  Each page has six main options numbered from 1 to 6 and two uncustomizable features numbered 7 and 8.  Each page is given a name, which is associated with a filename in the subdirectory <INSTALLDIR>\VietOption.

 

 

 

 

 

WinVNKey predefines 11 option pages.  But the user can modify/add/delete them.  This is done via a dropdown menu accessible by the downward arrow on the "Option Page" button.   This menu offers many operations similar to the menu on the Viet Chars page that defines typing methods.

 

The ? button at the top right corner offers mini-help for this page.   Because writing manual is usually the very last step in the development process, mini-help is an attempt by the author to provide temporary help during development and beta testing.  The main advantage of mini-help is that text is displayed in the same language as the user interface (English, Vietnamese, etc).  The reason is mini-help is part of the user interface and hence is stored as plain text in files English.ini, Vietnamese.ini, etc under <INSTALLDIR>\Display.

 

The following are detailed descriptions of the eight main options.

 

1.  Enable Smart Typing Method

 

For WinVNKey 4.0 beta 3 and earlier, you must type an accent mark immediately after the base letters.  Starting with this release the restriction is removed because WinVNKey has a smart algorithm to handle accent marks.   You can type a mark freely anywhere in the syllable.  There is a small toggle button to the right of option #1 as follows:

 

 

Clicking the toggle button will display further details on smart typing.  Specifically, you can control where to type an accent mark and when to combine it.   The display above shows just the summary "Enable smart typing method 3.2".  The first number, 3, refers to suboption A3 for  typing an accent mark.  The second number, 2, refers to suboption B2 for combining an accent mark.  The details of these suboptions are as follows:

A.  Where to type an accent mark?

A1.  Type accent mark immediately after vowel

This is the old way in WinVNKey.  However, this method is now smart.  The mark may not combine with the preceding letter if the result is not Vietnamese.  For instance, consider typing "lai.".  When you select this method A1, the dot is supposed to combine with the immediate vowel i, not the vowel a far away. But because laị is not correct in spelling, WinVNKey will not combine it.

 

A2.  Type accent mark immediately after word

Knowing that accent marks are always typed at the end of a word helps simplify WinVNKey combining and spell checking algorithm as well as improve the autocorrection accuracy.   In this methood, when you type an accent mark, WinVNKey knows that the current word is complete and can check dictionary right away.

 

A3.  Type accent mark anywhere in the syllable

This is the most user-friendly feature that most users prefer.  They do not have to worry about where to type an accent mark.  They can type the mark anywhere as they please.  This method is indeed how people write accent marks in practice.  The tradeoff is a very complicated algorithm to handle combining, spelling, and correcting errors.  In fact, in this method, when you type an accent mark, say, con~, WinVNKey cannot check dictionary right away because the word may not be completed yet.  In this example, cõn is incomplete because the user may still type 'g' or a space.  If he types 'g', only cõng is complete whereas cõn is not.  If he types a space, cõn is then a complete word.

 

B. When to combine an accent mark?

In general, WinVNKey will combine an accent mark with a base letter as long as the result is Vietnamese.  What is the result?  Well, the result can be a syllable or a word.  Specifically, WinVNKey will combine as long as

 

B1. the result is forming a Vietnamese syllable of a monosyllable word

Note that the requirement is that the word be monosyllable;  the word does not have to be Vietnamese.  Only the syllable part is required to be Vietnamese.  For example, "brom" is a monosyllable word although it is not Vietnamese.  The syllable part is "om".   Thus if this case (case B1)  is turned on, typing brom^ will combine into brôm.

 

B2. the result is forming a pronounceable Vietnamese word regardless of spelling

Note there are two requirements:  the word must be Vietnamese and the word must be pronounceable.  The word does not have to be legitimate or correct in spelling.  For example, biễn is such a word: it's a Vietnamese word, pronounceable, but does not exist in dictionary.   This method is also known as combining based on syllables.  If the syllable is Vietnamese, the full word will be pronounceable as long as the starting consonants are Vietnamese. Because the combination is based on syllables, WinVNKey will not attempt to spell check the word thoroughly.

 

B3. the result is forming a pronounceable Vietnamese word with correct spelling

This case is the same as case B2, except that WinVNKey will make full spelling check.  If the word fails spell check, WinVNKey will not combine the accent mark.  However, if the user also enables various correction options,  WinVNKey will attempt to make corrections first.  If correction is successful, the mark will be combined.  Otherwise, the mark is left uncombined.

 

 

Note that below the two combo boxes is a list box which shows examples applicable to the choices in the combo boxes.  If you change your selection in any of these two combo boxes, the example will change as well.

 

2. Autochange Letters

Autochange consonants before vowels

When typing Vietnamese text only, you can ask WinVNKey to do the following for you:

   - Change q into qu automatically when typing a vowel immediately after q

   - Change g into gh automatically when typing i or e immediately after g

   - Change ng into ngh automatically when typing i or e immediately after ng

   - Change f into ph automatically when typing a vowel immediately after f

   - Change z into gi automatically when typing a vowel other than i immediately after z

 

However, if you are typing text in both Vietnamese and English or other foreign languages, the features above may produce incorrect words.  For example, you want to type "get" in English but obtain "ghet" instead.  For this reason WinVNKey offers a finer control of when the autochange should occur.  You can click on the downward arrow associated with each autochange feature to specify whether the autochange occurs when and only when typing an accent mark.  For example, typing "ge" still gives you "ge", but as soon as you type ', the result will be changed to "ghé".   The bottom line is when a word has an accent mark, it must be Vietnamese if what you type is only English and Vietnamese.

Autochange consonants after vowels ic, k, g, h

The Vietnamese language does not have words ending in "ic" except for a few imported foreign words such as bic (bút BIC) and chic.  WinVNKey relies on this observation to offer an option to automatically expand ic into ich.

 

Vietnamese words do not end in 'k'.  Thus you can speed up your typing by asking WinVNKey to replace it with ch.

 

Vietnamese words do not have g or h immediately following a vowel.  Instead, if g or h is to appear at the end of a word, it must be preceded by n.  Based on this fact, WinVNKey offers an option to automatically convert g to ng and h to nh after a vowel.

 

These options are great if you know you are typing Vietnamese text only.  If you also type both Vietnamese and English or other languages, the result may not be what you want.  For example, when these options are on and if you want to type "bag" in English, you will get "bang" instead.  

 

For this reason WinVNKey offers a finer control of when the autochange should occur.  You can specify whether the autochange occurs when and only when the word already has an accent mark.   If you choose this option, then

 

 

Support quick vowels

Quick vowels are a kind of smart autocorrection.   In a broader sense it means changing a sequence of characters into another sequence automatically.   The following facts are observed regarding Vietnamese syllables:

 

  - ie always requires ^ to become iê, ie itself does not exist.

  - ye always requires ^ to become yê, ye itself does not exist.

  - ue always requires ^ to become uê, ue itself does not exist.

  - except when following 'q', ua always requires ^ to become uâ, ua itself does not exist.

  - ưo always requires an extra + to become ươ, ưo itself does not exist.

  - uơ always requires an extra + to become ươ, uơ itself does not exist.

  - ưô is always a typo error and should be changed to ươ to make sense.

 

This version of WinVNKey is smart enough to recognize these rules and can add the missing accent marks or correct them if requested.  WinVNKey offers options to autochange ie into iê, ye into yê, ue into uê, ua into uâ,  ưo or uơ into ươ, and ưô into ươ.

 

 

In addition, the following letter combinations never occur in Vietnamese and rarely in English:

ae, ii, yy, oq, uq, uv, uz.  

 

WinVNKey relies on this fact to offer quick syllable options to convert

 

ae into ây

ii into iê

yy into yê or uyê depending on the previous characters

oq into oă

uq into ươ

uv into uô

uz into uâ

 

Typing iê requires 4 key strokes: i, e, shift, and ^.  Typing ii requires 2 key strokes: i i.  Because your fingers need not move when typing the same i again, this is like one and a half key strokes.  This results in a saving of 2.5 keystrokes.  Even if you turn on the ie -> iê feature, typing ii is still faster than typing ie.  In particular, the Vietnamese language has no words with syllable yy and the most frequently seen syllables that contain y is uyên or uyêt.  Based on this observation WinVNKey offers you an option to automatically expand yy (1.5 keystrokes) into uyê (5 keystrokes: u, y, e, shift, ^).  This results in 3.5/5 or 70% faster.

 

It should be noted that the quick syllables are smarter than autoexpand macros because they do not carry out text replacement blindly.   If the replacement would yield non Vietnamese, quick syllables will not perform replacement. For example, WinVNKey

 

- will change tuyy into tuyê

- will change tyy into tuyê

- will not  change byy into buyê, cyy into cuyê, or kyy into kuyê

 

 This is because the Vietnamese language does not have any words beginning with buyê, cuyê, or kuyê.

 

 

3. Enable Syllable Correction

Tonemark on strong vowel

For words ending in oe/oa/uy the tonemark can appear in the first or the second vowel depending on personal preference.  Usually, the word looks more balanced if the tonemark appears in the first vowel.  This is the preferred style in the South before 1975 or in the Vietnamese communities overseas.  After 1975 Vietnam prefers the tonemark to be in the second vowel based on the argument that the second vowel is the main or strong vowel.  It is pronounced more strongly than the first and hence should carry the tonemark.

 

Autoadd second horn

If the vowels uo already carries one horn such as ưo or uơ, automatically add the second horn to it to form ươ.

 

Autochange ưn to ương

To the best of this author's knowledge, official (formal) Vietnamese writing does not allow words ending in ưn.  When n appears after ư, it must be accompanied by g.   This rule is not observed  in colloquial Vietnamese.  In fact, people in the South usually say bàn chưn instead of bàn chân.  Nevertheless, WinVNKey offers an option to automatically add g to ưn to speed up your typing if you wish.

 

Autoadd circumflex ^

As discussed above, Vietnamese writing requires ^ to accompany ie, ue, ye.  It also requires ^ to go with ua if the starting consonant is not 'q'.  WinVNKey offers an option to automatically add ^ for you.  

 

However, even though ^ is automatically added as soon as the second letter e is typed, many users may still type an additional circumflex because they cannot change their habit overnight.  WinVNKey realizes this scenario and fully accommodates this habit by just ignoring the second circumflex.

 

Autoinsert ơ into ưm and ưp

To the best of this author's knowledge, ưm and ưp are not legal Vietnamese syllables accepted in formal writing although they are pronounceable.  The presence of ư clearly states that these syllables are uniquely Vietnamese. Thus WinVNKey offers an option to automatically

- change ưm into ươm, and

- change ưp into ươp.

 

 

4. Uncombine as soon as syllable becomes non Vietnamese

 

 

If an accent mark is already combined and you next type a character that makes the syllable non Vietnamese, WinVNKey will undo the mark combinantion.   This option is very useful when you type both English and Vietnamese text at the same time.  In general, if you are typing a long English or foreign word and if some character becomes combined, you just keep typing.  Sooner or later, the syllable wull become non Vietnamese and WinVNKey will automatically uncombine for you.

 

For instance, you want to type "book".   After typing boo, you get bô.  Don't worry, keep typing k.  WinVNKey realizes ôk is not a Vietnamese syllable and will undo the combination.  In the end you will get book.

 

However, there are instances where the word is ambiguous: it can be English and Vietnamese as well.  For instance,

- you want to type moon  (English), but get môn (legal Vietnamese).

- you want to type boon  (English), but get bôn (legal Vietnamese).

- you want to type seen  (English), but get sên (legal Vietnamese).

- you want to type been  (English), but get bên (legal Vietnamese).

 

When this occurs and even though you may have type spaces after the word, you can still press and release the right Shift key to undo the preceding word.   This is option #7 discussed below.

5. Enable Word Correction On Word Completion

 

A word is said to be completed when either one of the following conditions occurs:

 

  1. when the user types a space or a punctuation such as comma, semicolon, or period. For example, when typing a space after "ba", the word "ba" is completed.

  2. when the word can no longer accept any letter or accent mark.  For example,

 

As soon as a word is completed, WinVNKey will begin checking the spelling and correct it if possible.  In the example above,

because "bấng" does not exist in formal writing (e.g. dictionary), WinVNKey will go through the list of all the word correction features that are enabled to fix it.  For this particular word, the fix is to delete 'g' because the remaining "ba^'n" is a good Vietnamese word.

5A. Correct tonemark

On word completion, if the word already has a question mark or tilde, it will be checked against dictionary and will be corrected accordingly.  For example

 

If you do want to get nỏn, you must better press and release a CTRL key after "nỏ" or "nỏn".   Pressing and releasing a CTRL key makes WinVNKey forget all the past and begin a new word.  That is, if you press and release a CTRL key after "nỏn", WinVNKey will forget everything about "nỏn" and hence does not do any correction.  The result is that nỏn will stay as is.

 

 

All Vietnamese words ending in c, ch, p, or t must have either an acute or dot-below accent mark.  Thus on word completion, if the user has not typed any accent mark, WinVNKey can automatically add an acute to the word.  For example, typing a space after "bac" means the user has finished the word and is about to type the next word.  If this option is enabled, WinVNKey will automatically add an acute as soon as typing the space.

 

But if the user is typing text in mixed Vietnamese/English or other foreign languages, this autochange feature may produce a wrong word.  For example, the user intends to type the English word "bet", not Vietnamese word "be't".  To alleviate this problem, WinVNKey allows the user to limit the autochange feature to words that already carry an accent mark, such as ba(c, ta^t, bie^t, etc.

 

5B. Correct vowels

If a word contains e^ and is not in dictionary, WinVNKey will try to delete e^ and then check against dictionary.  If the new word exists then it will be accepted.   For example, typing hiêu will result in hiu.

 

If a word contains o^ and is not in dictionary, WinVNKey will try to delete o^ and then check against dictionary.  If the new word exists, then it will be accepted.  For example, typing lun will result in luôn.

 

If a word contains o+ and is not in dictionary, WinVNKey will try to delete o+ and then check against dictionary.  If the new word exists, then it will be accepted.  For example, typing mưi will result in mươi, cưp in  cươp.

 

If a word carries a circumflex ^ and is not in dictionary, WinVNKey will try to delete it and then check against dictionary.  If the new word exists, then it will be accepted.  For example, typing gay` will result in gầy, tien' in tiến.

 

5C. Correct beginning consonants

If a word beginning with s or x does not exist, WinVNKey will try to change s to x and vice versa.  If the new word exist, then it will be accepted.  But if the user is typing text in mixed Vietnamese/English or other foreign languages, this correction feature may produce a wrong word.  To alleviate this problem, WinVNKey allows the user to limit the correction to words that already carries an accent mark, such as ba(c, ta^t, bie^t, etc.

 

If a word beginning with p does not exist, WinVNKey will try to change p to ph.  If the new word exist, then it will be accepted.   But if the user is typing text in mixed Vietnamese/English or other foreign languages, this correction feature may produce a wrong word.  To alleviate this problem, WinVNKey allows the user to limit the correction to words that already carries an accent mark, such as pa', pu`

 

5D. Correct ending consonants

 

If a word carries accent marks and  ends in c or t and is not in dictionary, WinVNKey will try to change the ending c to t and ending t to c.  If the new word exists in dictionary, it will be accepted.

 

If a word ends in 'g' or 'h' and does not exist in dictionary, WinVNKey will try to delete the ending 'g' or 'h'.  If the new word exists in dictionary, it will be accepted.

 

If the user is typing text in mixed Vietnamese/English or other foreign languages, this correction feature may produce a wrong word.  To alleviate this problem, WinVNKey allows the user to limit the correction to words that already carry an accent mark, such as pa', pu`

 

6. Uncombine as soon as word becomes non Vietnamese

 

 

This option is exactly like option #4 except it applies to word.

 

 

7. Undo with Right Shift Key

If a mark is wrongly combined, you can undo it simply by pressing and releasing the right shift key immediately.  WinVNKey then assumes the word is English and uncombines every accent mark in the word.

 

If a mark is wrongly uncombined, you can also undo it simply by pressing and releasing the right shift key immediately. WinVNKey then tries to recombine all the accent marks that have recently been uncombined.

 

You can  undo as long as you have not begun typing a new word.  That is, you can undo even if you already typed one or more spaces after the word that you want to undo.

 

For example, suppose you already typed "I have bên  "  (without the double quotes).  Note that you already typed a space after "bên".  Now, pressing and releasing the right Shift key will restore to "I have been  ".   Undo was successful because you have not started a new word after "bên".

 

NOTE: It is easy to make a mistake of pressing and releasing the right Shift key unintentionally.  To avoid this mistake, the author can redefine this option by requiring press and release of both the right and left Shift keys at the same time.  However, the author thinks this causes unnecessary pain to users because undoing is frequently needed when typing mixed Vietnamese and English text.  In addition, if a user makes an undo mistake, he/she can simply undo again to restore.   Thus the author decides to keep the undo  definition with using one Shift key.  The right Shift key is chosen to avoid conflict with hot key sequences that require CTRL-LeftSHIFT or LeftSHIFT-CTRL.

 

8. Forget Current Word With Ctrl Key

 

 

When you type a new character, WinVNKey may change it to another character or combine with a previous character or simply begin a spell check and correction process.  If you do not want this to happen, you can make WinVNKey forget all past characters and treat the new character as beginning a new word.  This is accomplished by pressing and releasing a CTRL key immediately before typing the new character.

 

Let's see how you apply this feature in practice, assuming that you turned on smart typing option (Viet Option page #5):

 

 

 

t e ' CTRL l e ' CTRL phone

The two CTRL keys separated the typing into 3 separate words as far as accent marks are concerned:   té   lé   phone.

 

 

Next Topic:          Viet Word Processing

Previous Topic:  Remap