Rem  IpapanMacro  for  IpapanAdd(Ipapan.ttf)
Rem  MS word97-2000 (IpaPan.ttf)򡣼뷨
Rem  һ װ
Rem  1ƴȫ(ɰ˵УɾRem)
Rem  2word///(IpapanMacro)
Rem  3ճݣ沢رպ괰
Rem  4word//Զ//IpapanMacro/ָΪalt+lݼ
Rem   뷨
Rem  ĸݼ" alt+l"(Լ), 갴ѭ
Rem  (Ҫipapan.ttfkeymanȼ̶ʱѡ)
Rem   
Rem  http://www.eastling.org(塢ꡢ뷨)
Rem  뷨ΪȺ2000-2ƣ2002-7޸

Sub IpaPanMacro()

Selection.MoveLeft Unit:=wdCharacter, Count:=1, Extend:=wdExtend
If AscW(Selection.Text) + 4096 < 123 And AscW(Selection.Text) + 4096 > 96 Then
    Selection.Font.Name = "Times New Roman"
    If AscW(Selection.Text) < 0 Then
    Selection.TypeText Text:=ChrW(AscW(Selection.Text) + 4096)
    Else
    Selection.TypeText Text:=ChrW(AscW(Selection.Text))
    End If
    Selection.MoveLeft Unit:=wdCharacter, Count:=1, Extend:=wdExtend
End If
Selection.Font.Name = "Times New Roman"
    Select Case Selection.Text
 
Case "?"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(47)

Case ChrW(47)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(214)

Case ChrW(214)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(192)

Case ChrW(192)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(179)

Case ChrW(179)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(47)

Case "l"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(194)

Case ChrW(194)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(201)

Case ChrW(201)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(59)

Case ChrW(59)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(76)

Case ChrW(76)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(241)

Case ChrW(241)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(108)


Case "n"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(78)

Case ChrW(78)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(420)
Case ChrW(420)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61618)
Case ChrW(61618)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(203)
Case ChrW(203)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(503)
Case ChrW(503)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(248)
Case ChrW(248)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(110)
Case ChrW(110)

Case "a"

    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(65)
Case ChrW(65)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(140)
Case ChrW(140)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(129)
Case ChrW(129)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(162)
Case ChrW(162)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(81)
Case ChrW(81)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(97)

 
Case "b"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(66)
Case ChrW(66)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(245)
Case ChrW(245)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61626)
Case ChrW(61626)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(158)
Case ChrW(158)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(688)
Case ChrW(688)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(98)
 
Case "c"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(254)
Case ChrW(254)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(141)
Case ChrW(141)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(67)
Case ChrW(67)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(130)
Case ChrW(130)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(99)

 
Case "d"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(165)
Case ChrW(165)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(68)
Case ChrW(68)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61674)
Case ChrW(61674)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(235)
Case ChrW(235)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(100)

 
Case "e"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(171)
Case ChrW(171)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(69)
Case ChrW(69)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(212)
Case ChrW(212)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(163)
Case ChrW(163)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(206)
Case ChrW(206)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(157)
Case ChrW(157)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(101)

 
Case "f"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61624)
Case ChrW(61624)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(727)
Case ChrW(727)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(102)


Case "g"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(71)
Case ChrW(71)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(169)
Case ChrW(169)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(253)
Case ChrW(253)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(103)

Case "h"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61690)
Case ChrW(61690)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(72)
Case ChrW(72)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(75)
Case ChrW(75)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(238)
Case ChrW(238)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(231)
Case ChrW(231)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(240)
Case ChrW(240)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(104)


Case "i"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(73)
Case ChrW(73)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(246)
Case ChrW(246)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(152)
Case ChrW(152)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(153)
Case ChrW(153)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(174)
Case ChrW(174)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(105)
 
Case "j"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(74)
Case ChrW(74)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(239)
Case ChrW(239)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61630)
Case ChrW(61630)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(198)
Case ChrW(198)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(106)

 
Case "k"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(251)
Case ChrW(251)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(107)
 
Case "m "
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(109)
Case ChrW(109)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(181)
Case ChrW(181)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(77)
Case ChrW(77)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(229)
Case ChrW(229)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(109)

Case "o"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(447)
Case ChrW(447)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61615)
Case ChrW(61615)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(79)
Case ChrW(79)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(439)
Case ChrW(439)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(135)
Case ChrW(135)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(80)
Case ChrW(80)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(84)
Case ChrW(84)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(111)

 
Case "p"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61625)
Case ChrW(61625)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(112)
 
Case "q"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(207)
Case ChrW(207)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(113)

 
Case "r"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(680)
Case ChrW(680)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61563)
Case ChrW(61563)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(82)
Case ChrW(82)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(211)
Case ChrW(211)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(210)
Case ChrW(210)
        Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(125)
Case ChrW(125)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(228)
Case ChrW(228)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(114)


Case "s"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(423)
Case ChrW(423)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61523)
Case ChrW(61523)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(115)
 
Case "t"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(166)

Case ChrW(166)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(255)

Case ChrW(255)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(116)

 
Case "u"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(85)
Case ChrW(85)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61601)
Case ChrW(61601)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(172)
Case ChrW(172)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(117)

 
Case "v"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(196)
Case ChrW(196)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(70)
Case ChrW(70)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61622)
Case ChrW(61622)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(195)
Case ChrW(195)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(86)
Case ChrW(86)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61676)
Case ChrW(61676)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(118)

 
Case "w"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(87)
Case ChrW(87)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(227)
Case ChrW(227)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(119)
Case ChrW(119)

 
Case "x"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(88)
Case ChrW(88)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(120)

 
Case "y"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(147)
Case ChrW(147)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(148)
Case ChrW(148)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(89)
Case ChrW(89)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(436)
Case ChrW(436)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(121)

 
Case "z"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61692)
Case ChrW(61692)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61629)
Case ChrW(61629)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(90)
Case ChrW(90)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(143)
Case ChrW(143)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(144)
Case ChrW(144)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(122)

 
Case "."
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(202)
    Selection.MoveLeft Unit:=wdCharacter, Count:=2
    Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
    If Selection.Text = ChrW(61621) Or Selection.Text = ChrW(61549) Or Selection.Text = "m" Then
        With Selection.Font
         .NameFarEast = ""
         .NameAscii = "IpaPanADD"
         .NameOther = "IpaPanADD"
         .Spacing = -1.5
         End With
        Selection.MoveRight Unit:=wdCharacter, Count:=1
        Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
        With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = 1.5
        End With
        Selection.MoveRight Unit:=wdCharacter, Count:=1
        With Selection.Font
        .NameFarEast = ""
        .NameAscii = "IpaPanADD"
        .NameOther = "IpaPanADD"
        .Spacing = 0
        End With
    Else
        If Selection.Text = ChrW(61521) Then
            With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = -1
            End With
            Selection.MoveRight Unit:=wdCharacter, Count:=1
            Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
            With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = 1
            End With
            Selection.MoveRight Unit:=wdCharacter, Count:=1
            With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = 0
            End With
        Else
            If Selection.Text = "l" Or Selection.Text = ChrW(61548) Or Selection.Text = ChrW(61545) Or Selection.Text = "i" Then
                With Selection.Font
                .NameFarEast = ""
                .NameAscii = "IpaPanADD"
                .NameOther = "IpaPanADD"
                .Spacing = 1
                End With
                Selection.MoveRight Unit:=wdCharacter, Count:=1
                Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
                With Selection.Font
                .NameFarEast = ""
                .NameAscii = "IpaPanADD"
                .NameOther = "IpaPanADD"
                .Spacing = -1
                End With
                Selection.MoveRight Unit:=wdCharacter, Count:=1
            End If
        End If
        Selection.MoveRight Unit:=wdCharacter, Count:=2
    End If

Case ChrW(202)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61613)
Case ChrW(61613)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(136)
Case ChrW(136)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(46)

Case ChrW(61486)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(202)
    Selection.MoveLeft Unit:=wdCharacter, Count:=2
    Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
    If Selection.Text = ChrW(61621) Or Selection.Text = ChrW(61549) Or Selection.Text = "m" Then
        With Selection.Font
         .NameFarEast = ""
         .NameAscii = "IpaPanADD"
         .NameOther = "IpaPanADD"
         .Spacing = -1.5
         End With
        Selection.MoveRight Unit:=wdCharacter, Count:=1
        Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
        With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = 1.5
        End With
        Selection.MoveRight Unit:=wdCharacter, Count:=1
        With Selection.Font
        .NameFarEast = ""
        .NameAscii = "IpaPanADD"
        .NameOther = "IpaPanADD"
        .Spacing = 0
        End With
    Else
        If Selection.Text = ChrW(61521) Then
            With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = -1
            End With
            Selection.MoveRight Unit:=wdCharacter, Count:=1
            Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
            With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = 1
            End With
            Selection.MoveRight Unit:=wdCharacter, Count:=1
            With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = 0
            End With
        Else
            If Selection.Text = "l" Or Selection.Text = ChrW(61548) Or Selection.Text = ChrW(61545) Or Selection.Text = "i" Then
                With Selection.Font
                .NameFarEast = ""
                .NameAscii = "IpaPanADD"
                .NameOther = "IpaPanADD"
                .Spacing = 1
                End With
                Selection.MoveRight Unit:=wdCharacter, Count:=1
                Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
                With Selection.Font
                .NameFarEast = ""
                .NameAscii = "IpaPanADD"
                .NameOther = "IpaPanADD"
                .Spacing = -1
                End With
                Selection.MoveRight Unit:=wdCharacter, Count:=1
            End If
        End If
        Selection.MoveRight Unit:=wdCharacter, Count:=2
    End If

 
Case "|"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(146)
Case ChrW(146)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(150)
Case ChrW(150)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(132)
Case ChrW(132)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(199)
Case ChrW(199)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(200)
Case ChrW(200)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(142)

Case "1"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(218)
Case ChrW(218)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(219)
Case ChrW(219)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(220)
Case ChrW(220)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(221)
Case ChrW(221)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(222)
Case ChrW(222)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(223)
Case ChrW(223)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61664)
Case ChrW(61664)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61665)
Case ChrW(61665)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(218)

Case ChrW(61489)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(218)
 
Case "`"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(41)
    Selection.MoveLeft Unit:=wdCharacter, Count:=1
    Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
    If Selection.Text = ChrW(61621) Or Selection.Text = ChrW(61549) Or Selection.Text = "m" Then
        With Selection.Font
         .NameFarEast = ""
         .NameAscii = "IpaPanADD"
         .NameOther = "IpaPanADD"
         .Spacing = -1.5
         End With
        Selection.MoveRight Unit:=wdCharacter, Count:=1
        Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
        With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = 1.5
        End With
        Selection.MoveRight Unit:=wdCharacter, Count:=1
        With Selection.Font
        .NameFarEast = ""
        .NameAscii = "IpaPanADD"
        .NameOther = "IpaPanADD"
        .Spacing = 0
        End With
    Else
        If Selection.Text = ChrW(61521) Then
            With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = -1
            End With
            Selection.MoveRight Unit:=wdCharacter, Count:=1
            Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
            With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = 1
            End With
            Selection.MoveRight Unit:=wdCharacter, Count:=1
            With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = 0
            End With
        Else
            If Selection.Text = "l" Or Selection.Text = ChrW(61548) Or Selection.Text = ChrW(61545) Or Selection.Text = "i" Then
                With Selection.Font
                .NameFarEast = ""
                .NameAscii = "IpaPanADD"
                .NameOther = "IpaPanADD"
                .Spacing = 1
                End With
                Selection.MoveRight Unit:=wdCharacter, Count:=1
                Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
                With Selection.Font
                .NameFarEast = ""
                .NameAscii = "IpaPanADD"
                .NameOther = "IpaPanADD"
                .Spacing = -1
                End With
                Selection.MoveRight Unit:=wdCharacter, Count:=1
            End If
        End If
    End If
Case ChrW(41)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(40)
Case ChrW(40)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(36)
Case ChrW(36)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(64)
Case ChrW(64)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(94)
Case ChrW(94)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(209)
Case ChrW(209)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(230)
Case ChrW(230)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(42)
Case ChrW(42)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(35)
Case ChrW(35)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(95)
Case ChrW(95)
   Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:="`"
    
Case ChrW(61536)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(41)
    Selection.MoveLeft Unit:=wdCharacter, Count:=2
    Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
    If Selection.Text = ChrW(61621) Or Selection.Text = ChrW(61549) Or Selection.Text = "m" Then
        With Selection.Font
         .NameFarEast = ""
         .NameAscii = "IpaPanADD"
         .NameOther = "IpaPanADD"
         .Spacing = -1.5
         End With
        Selection.MoveRight Unit:=wdCharacter, Count:=1
        Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
        With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = 1.5
        End With
        Selection.MoveRight Unit:=wdCharacter, Count:=1
        With Selection.Font
        .NameFarEast = ""
        .NameAscii = "IpaPanADD"
        .NameOther = "IpaPanADD"
        .Spacing = 0
        End With
    Else
        If Selection.Text = ChrW(61521) Then
            With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = -1
            End With
            Selection.MoveRight Unit:=wdCharacter, Count:=1
            Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
            With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = 1
            End With
            Selection.MoveRight Unit:=wdCharacter, Count:=1
            With Selection.Font
            .NameFarEast = ""
            .NameAscii = "IpaPanADD"
            .NameOther = "IpaPanADD"
            .Spacing = 0
            End With
        Else
            If Selection.Text = "l" Or Selection.Text = ChrW(61548) Or Selection.Text = ChrW(61545) Or Selection.Text = "i" Then
                With Selection.Font
                .NameFarEast = ""
                .NameAscii = "IpaPanADD"
                .NameOther = "IpaPanADD"
                .Spacing = 1
                End With
                Selection.MoveRight Unit:=wdCharacter, Count:=1
                Selection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtend
                With Selection.Font
                .NameFarEast = ""
                .NameAscii = "IpaPanADD"
                .NameOther = "IpaPanADD"
                .Spacing = -1
                End With
                Selection.MoveRight Unit:=wdCharacter, Count:=1
            End If
        End If
        Selection.MoveRight Unit:=wdCharacter, Count:=2
    End If

Case "\"
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61689)
Case ChrW(61689)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61610)
Case ChrW(61610)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(193)
Case ChrW(193)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:="\"

Case ChrW(61532)
    Selection.Font.Name = "IpaPanADD"
    Selection.TypeText Text:=ChrW(61689)

 
Case Else
        Selection.TypeText Text:=Selection.Text
       End Select
                With Selection.Font
                .NameFarEast = ""
                .NameAscii = "Times New Roman"
                .NameOther = "Times New Roman"
                .Spacing = 0
                End With

End Sub
