Microsoft Word Right Vertical Zhuyin Tone Mark Workaround マイクロソフト・ワード右縦寄せ注音声調記号ワークアラウンド

Introduction 紹介
To keep myself occupied during the pandemic, I have been reading and translating kanbun 漢文 and kanshi 漢詩. These refer to texts and poetry written in Classical Chinese. Sometimes these Classical Chinese texts were even written by Japanese authors. Following academic tradition, when I translate these texts to English, I render proper nouns into Hanyu Pinyin. Therefore, I would render 蓬莱 as Pénglái or Penglai rather than Hōrai. When I encountered a proper noun while reading a Classical Chinese text, to remind myself of the Chinese reading for my translation, I originally would gloss the character with Pinyin. For horizontal texts, Pinyin is quite easy to read as it follows the same text orientation of the Latin alphabet, e.g. (zhī). But as Classical Chinese is traditionally written vertically, Pinyin can be quite difficult to read. One can write the Pinyin gloss vertically without rotation (zhī) or rotated 90 degrees (zhī). I find both formats quite cumbersome to read. Therefore, I began to use Zhuyin Fuhao 注音符号.


Zhuyin Fuhao 注音符号
Zhuyin Fuhao, also known as Bopomofo or Zhuyin, is a transliteration system for Mandarin Chinese. In 1912 the government of the Republic of China established the Commission on the Unification of Pronunciation, an organization to standardize Mandarin pronunciation and create a Mandarin phonetic system. The system they created, Zhuyin, was used in mainland China until 1958, when Hanyu Pinyin became the official transliteration system of the People’s Republic of China. However, Zhuyin continues to be used in Taiwan for teaching Mandarin pronunciation.


As for the actual system itself, each Zhuyin character represents either a Mandarin initial, or a medial/final. For example, the Zhuyin character ㄇ is the initial /m/ while the Zhuyin character ㄚ is the final /a/. Therefore, the reading of 媽, /ma/, is written in Zhuyin as ㄇㄚ. Here is a chart of Zhuyin characters with their Pinyin and IPA equivalents.



Zhuyin is flexible because it can be written both vertically and horizontally. For example, one can gloss 媽 as ㄇㄚ in horizontal writing and ㄇㄚ in vertical writing. Zhuyin can be considered analogous to katakana, because not only are the characters used for phonetic transcription, but they also originate from Chinese characters. For example, the Zhuyin character ㄖ comes from the Chinese character 日 and the Zhuyin character ㄓ comes from the Chinese character 之.


(I would like to have discussed the promulgation and origin of the Zhuyin characters more in-depth, but I encountered much difficulty in finding primary sources on the creation of Zhuyin and its adoption in the early 20th century. Maybe I will return to this one day.)


I saved the discussion of Zhuyin tones for last because it is the most relevant to this article and thus requires a more in-depth discussion. To indicate tone in Zhuyin four tone markers are utilized. They are as follows.


Tone 声調
1Omitted 省かれた

According to The Manual of the Phonetic Symbols of Mandarin Chinese by the Ministry of Education of the Republic of China, “Marks of the four tones should be noted at the upper-right corner of Bopomofo in both portrait and landscape text.



However, “The mark of neutral tone should be
   a. Noted on the top of Bopomofo in portrait text. For example:
   a. 縦書きでボポモフォの上に記すものとする。例えば

   b. Noted at the very front of Bopomofo in landscape text. For example:
   b. 横書きでボポモフォの最初に記すものとする。例えば

Using Microsoft Word to Gloss Chinese Characters マイクロソフト・ワードで漢字に注音を振る方法
So now that we have a basic understanding of Zhuyin, let’s talk about how I ended up finding this problem in the first place. In addition to kanbun and kanshi, I also have been reading Classical Chinese poems aloud in Mandarin. However, because I find memorizing tones to be quite difficult, I prefer to gloss every single word. Originally, I would gloss them manually, but soon I found that Microsoft Word could do this for me.


Now I’m going to discuss how to install Zhuyin support for Microsoft Word. Because Microsoft Office and Windows are frequently being updated, the process to set up Zhuyin glossing for you may be different than what I will describe. If you are having difficulty, please leave a comment and I will try my best to help.


Microsoft Office does not have any Chinese character dictionary itself, so to provide one you need to install the Windows Chinese (Traditional, Taiwan) language pack. To do such, open Word, click on Review, then Language, then Language Preferences, and Install additional keyboards from Windows Settings. From there, press Add a language, and select Chinese (Traditional, Taiwan).








After that finishes installing, you need to install the Traditional Chinese Language Pack for Office. You can do this by opening Word, clicking on Review, then Language, then Language Preferences, and finally Install additional display languages from From that list choose Chinese (Traditional) and run the file from to install the language pack.



インストールを終えた後、「オフィス用中国語 (繁体字)パック」をインストールする必要がある。インストールするために、ワードの「校閲」をクリックし、「言語」をクリックし、「言語の設定」をクリックして、「Office.comから追加の表示言語をインストール」をクリックする。その表から「中国語 (繁体字)」を選んで、Office.comからファイルを実行する。



Now that that is installed, let’s try to gloss some characters. First, copy and paste some Chinese characters into Microsoft Word. If Word does not automatically set the proofreading language to Chinese (Taiwan), then do such manually by highlighting the text, click Review, then Language, and then Set Proofreading Language. From there select Chinese (Taiwan) and hit Ok.




Now finally, highlight the text and click the Phonetic Guide button.




Thereupon this menu will open.




Word is now using Windows’ Zhuyin dictionary to easily gloss the text for you. From my experience, Word is even pretty good at glossing Chinese characters with multiple Mandarin readings, known as duōyīnzì 多音字 or pòyīnzì 破音字, based on the context of the sentence. The only downside is that this method cannot gloss more than about 30 characters at a time, so it is necessary to click the Phonetic Guide button for each sentence.


So let’s look at how Word glosses Li Bai’s 李白 8th century poem Quiet Night Thought 靜夜思.
Please note that the text orientation is currently horizontal. The first line is 床前明月光.



Overall, this glossing is pretty good in my opinion. I would note that the tone marks are a little high, but that’s just a nitpick. As for the readings themselves, they are also pretty good. Word was able to correctly gloss the duōyīnzì 地 and 頭. The only point of contention is 地上. While I have seen this word glossed as ㄉㄧˋㄕㄤ ˋ(dìshàng) in some sources, the more contemporary pronunciation is ㄉㄧˋ˙ㄕㄤ (dìshang). You can modify the gloss by highlighting the text and pressing Phonetic Guide again.

大抵上手く、注音を振ったと思う。声調記号が少し高すぎるが、まあいいだろう。候補に出てきた北京語の読みもいいと思う。ワードは多音字の「地」と「頭」に正しい読みの注音を振った。問題の一つは「地上」である。この言葉の読みは「ㄉㄧˋㄕㄤ ˋ」(dìshàng)と振られたが、より現代的なの読みは「ㄉㄧˋ˙ㄕㄤ」(dìshang)である。読みを変えるためにテキストをハイライトして、もう一度「ルビ」をクリックする。

After changing the gloss of 地上, here is the result.


But while this looks good, I would argue that Pinyin should be the preferred phonetic guide system of horizontal text, on the basis of how widespread it is. The only reason I am even interested in using Zhuyin is because of the awkwardness of using Pinyin with a vertical text orientation. (That’s also why I will not be commenting on the strange glitches Word has in rendering horizontal Zhuyin). So, let’s change the text orientation to Vertical and see how it affects the Zhuyin. You can change the text direction by going to Layout, and then Text Direction.




This yields


For those unfamiliar with Chinese, you may not notice the difference at first, but compare the Zhuyin in the vertically oriented text to that of the horizontally oriented text. You may notice that the tone of 床 appears to be 4th tone in the vertical text and 2nd tone in the horizontal text. Looking at 舉 reveals the problem: the Zhuyin tone marks are rotated 90 degrees in vertical text orientation. Looking at old Microsoft Community Forums, this bug has existed in Word for a long time. I imagine this is because the user base who would use this feature is so small that there’s little demand to correct it, even if the change in code to do such would likely be quite small. I could get over the tone marks being a tad too high, but the fact that the rotated 4th tone mark looks like the standard 2nd tone mark, and vice versa, is simply unacceptable.


I tried to find some way to fix this bug, but in short of patching Word, I do not think this bug can be fixed by a user. However, I have created some workarounds to this problem which have decent results.


These workarounds come in the form of macros. A macro is a sequence of inputtable computer instructions. For example, there can be a macro that capitalizes the name of every file in a folder. While a human could manually go through each file and capitalize its name, a macro can save time by doing this task automatically. Microsoft Office macros are written in a programing language called Visual Basic for Applications (VBA). I should note that Office macros have been used as a vector to send computer viruses before, so one should always take caution when enabling or running Office macros of an unknown source. To create a macro in Word, go to View then Macros.


このワークアラウンドはマクロである。マクロとはインプットできる命令の順序である。例えば、パソコンでいうと、フォルダーの中にあるファイルの名前の頭文字を大文字にするマクロを作れる。人は手動で各ファイルの名前の頭文字を大文字にすることができるけれど、マクロは自動で頭文字を大文字にすることを可能にするため、使い手の手間が省ける。マイクロソフト・オフィスのマクロはビジュアルベーシック・フォー・アプリケーションズ(Visual Basic for ApplicationsあるいはVBA)というプログラミング言語で書かれた。オフィスのマクロを使う前に、注意するべきことがある。オフィスのマクロを実行すると、ウィルスをもらうことがある。だから起源不明なオフィスのマクロを実行する時には、注意する必要がある。マクロを作るために、ワードで「表示」をクリックし、そして「マクロ」をクリックする。


Then name your macro and then press Create.




This will cause a window titled Microsoft Visual Basic for Applications to open. In this window there will be a text box, and in that text box, you paste the code for your macro.

するとMicrosoft Visual Basic for Applicationsというウィンドウが開かれる。このウィンドウにあるテキストボックスにマクロのコードを貼り付ける。


To run your macro, go to the Macros menu again, select the macro you want, and hit Run.




Before we begin discussing the macros, I would like to note that my macros involve replacing all instances of certain text sequences. While possible to undo the macro’s changes using the standard Word undo button, you will need to press undo for each replaced sequence, which can be very cumbersome. So, I recommend backing up your original text before running any of these macros, especially when you are not exactly sure which macro would best suit your needs.


So, without further ado, let’s get macroing.

Workaround #1: Reverse Tones 2 and 4 ワークアラウンド#1:第二声記号と第四声記号を交換
As I said before, the most egregious problem of having the rotated tone marks is that the rotated 2nd tone mark looks like the standard 4th tone mark and vice versa. While the 3rd tone mark looks unappealing, at least there is no confusion in what it is. Therefore, the simplest solution is to change the 2nd tone marks into 4th tone marks and the 4th tone marks into 2nd tone marks. To do this
   1. I replace all 2nd tone marks (U+02CA) with the string “UPTONE”
   2. I replace all 4th tone marks (U+02CB) with 2nd tone marks
   3. I replace all instances of the string “UPTONE” with 4th tone marks

   1. すべての第二声記号(U+02CA)を「UPTONE」という文字列とする
   2. すべての第四声記号(U+02CB)を第二声記号とする
   3. すべての 「UPTONE」という文字列を第四声記号(U+02CB)とする

Keep in mind that if your document has the string “UPTONE” in it, that string will be changed into a 4th tone mark. Also, in case you do not like the results, running this macro again will revert the tones to their original form. This macro also runs very quickly because it only needs to search the document three times.


The output of this macro is


The code for this macro is

Sub ReverseTones_Bopomofo()
Dim rngStory As Range
For Each rngStory In ActiveDocument.StoryRanges
With rngStory.Find
.Text = ChrW(714)
.Replacement.Text = "UPTONE"
.Wrap = wdFindContinue
.Execute Replace:=wdReplaceAll
End With
With rngStory.Find
.Text = ChrW(715)
.Replacement.Text = ChrW(714)
.Wrap = wdFindContinue
.Execute Replace:=wdReplaceAll
End With
With rngStory.Find
.Text = "UPTONE"
.Replacement.Text = ChrW(715)
.Wrap = wdFindContinue
.Execute Replace:=wdReplaceAll
End With
Next rngStory
End Sub

While not perfect, someone with a rudimentary understanding of Zhuyin tone marks should have no difficulty in identifying the tone of the glossed character. But even if understandable, the rotated 3rd tone mark still does not conform to the Zhuyin standard. The quest to properly rotate the 3rd tone mark led me to Workaround #2.


Workaround #2: Use Combining Characters ワークアラウンド#2:結合文字の使用
Without going into character encoding too much, a Combining Character is a diacritic that combines with another character. For example, the combining character ◌̅ (U+0305) can combine with ‘e’ to create e̅. These contrast with Spacing Modifier Letters, the type of independent characters which the Zhuyin tone marks are. And fortunately, when the combining characters ◌̀ (U+0300), ◌́ (U+0301), and ◌͐ (U+0350) are rotated 90 degrees, they look very similar to the Zhuyin 2nd, 4th, and 3rd tone marks respectively.


But to which characters will these Combining Characters combine? For the output most accurate to the Zhuyin standard, they should combine with the final Zhuyin character. The simplest way to do this is to look for every combination of Zhuyin final and Zhuyin tone mark. This means that the entire document needs to be searched sixty-nine times. Therefore, this macro can take some time to run.


The output for this macro is


The code for this macro is

Sub Vertical_Bopomofo()
Dim rngStory As Range
For zhuyinchar = 12563 To 12585
For Each rngStory In ActiveDocument.StoryRanges
With rngStory.Find
.Text = ChrW(zhuyinchar) & ChrW(714)
.Replacement.Text = ChrW(832) & ChrW(zhuyinchar)
.Wrap = wdFindContinue
.Execute Replace:=wdReplaceAll
End With
With rngStory.Find
.Text = ChrW(zhuyinchar) & ChrW(715)
.Replacement.Text = ChrW(833) & ChrW(zhuyinchar)
.Wrap = wdFindContinue
.Execute Replace:=wdReplaceAll
End With
With rngStory.Find
.Text = ChrW(zhuyinchar) & ChrW(711)
.Replacement.Text = ChrW(848) & ChrW(zhuyinchar)
.Wrap = wdFindContinue
.Execute Replace:=wdReplaceAll
End With
Next rngStory
End Sub

I like how the lines are much closer together than when using Spacing Modifier Letters, but unfortunately this leads to the tone marks occasionally being quite difficult to see. For example the tone mark on 是 can be easy to miss, especially if one prints out the page. On top of this, there is the quite lengthy search process. To combat a few of these issues I present Workaround #3.


Workaround #3: Use Combining Characters after the Final ワークアラウンド#3:声母後における結合文字の使用
To help alleviate the problems of the second macro, difficulty in seeing the tone marks and how long it needs to run, I created my third macro. This macro uses Combining Characters, but instead of attaching them to the Zhuyin final, they are instead attached to a whitespace character (U+0020) which is appended after the final. This macro only searches the document three times, so it is quite fast.


This macro results in


The code for this macro is

Sub Vertical_ModifyLast_Bopomofo()
Dim rngStory As Range
For Each rngStory In ActiveDocument.StoryRanges
With rngStory.Find
.Text = ChrW(714)
.Replacement.Text = ChrW(832) + " "
.Wrap = wdFindContinue
.Execute Replace:=wdReplaceAll
End With
With rngStory.Find
.Text = ChrW(715)
.Replacement.Text = ChrW(833) + " "
.Wrap = wdFindContinue
.Execute Replace:=wdReplaceAll
End With
With rngStory.Find
.Text = ChrW(711)
.Replacement.Text = ChrW(848) + " "
.Wrap = wdFindContinue
.Execute Replace:=wdReplaceAll
End With
Next rngStory
End Sub

I don’t think this macro completely resolves the difficulty in seeing the tone marks, for example 床, but for other characters, like 是, it does help.


Conclusion 結論
At the end of the day, these macros are only workarounds to the problem. If you want true Zhuyin support, you are likely better off using another program rather than Microsoft Word. However, if you just need basic vertical Zhuyin support, I think my macros make Word an option. They may not have the cleanest execution, but at least their results do adhere to the Zhuyin standard. I also would like to note that I have very limited experience in VBA, so I am sure that there is some way to make this code more efficient or the output more presentable. If you have any suggestions, please leave a comment. Also, if you are interested in getting this bug fixed, feel free to leave feedback within Microsoft Word (Help, Feedback, and then I don’t like something) and also upvote this UserVoice suggestion.




I am pessimistic that this issue will be resolved because it affects so few people, but because I imagine the fix to be quite simple, who knows, maybe we’ll get lucky.