Font.DiacriticColor プロパティ (Publisher)

右から左に書き進む文書で Diacritics に使用されている 24 ビットの色を表す ColorFormat オブジェクトを取得します。

構文

DiacriticColor

Font オブジェクトを表す変数。

戻り値

ColorFormat

次の使用例は、現在の文書の最初のストーリーのテキストをテストして、その色が赤かどうか、および右から左に書式設定されているかどうかを判断します。

Sub FontDiColor() 
 
 Dim fntDiColor As Font 
 
 Set fntDiColor = Application.ActiveDocument. _ 
 Stories(1).TextRange.Font 
 
 If fntDiColor.UseDiacriticColor = msoTrue And _ 
 fntDiColor.DiacriticColor.RGB = RGB(255, 0, 0) Then 
 MsgBox "Your text is red" 
 Else 
 MsgBox "This is not a right-to-left language" _ 
 & " or your color is not red" 
 End If 
 
End Sub

サポートとフィードバック

Office VBA またはこの説明書に関するご質問やフィードバックがありますか? サポートの受け方およびフィードバックをお寄せいただく方法のガイダンスについては、Office VBA のサポートおよびフィードバックを参照してください。