How to automatically select font for Arabic in English / Arabic word document

SAbboushi used Ask the Experts™
Using word 2007 under Vista.

I type English and Arabic in the same document.  I want my english to use the "normal" style and I want Arabic to use a different style (or at a minimum, a different point size).  I have to keep highlighting the Arabic words I type so that I can change the font size... there has gotta be an easier way.  Anyone...?
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®

You should create separate styles for English and Arabic. If individual paragraphs have only one language, then you could use paragraph styles. But if a single para might have both English
and Arabic, you would need character styles. Open the styles dialog by clicking the small arrow at the lower right corner of the styles group on the Home ribbon. Click the New Style button and create a style called EnglishText. Set the style type to Character, and select the font you want to use. When you're done, create another style called ArabicText, and select the font attributes for it.

Now you can switch between languages quickly simply by selecting the EnglishText or ArabicText style. To speed things up, define a keyboard shortcut for each style. Right-click on any ribbon and choose Customize Quick Access Toolbar. At the bottom, click the Shortcut Keys buttkn. In the Categories box, choose styles, then select your EnglishText style. Assign a shortcut key (perhaps Ctrl+Shift+E). Do the same for the ArabicText style. You can now switch between English and Arabic with a single keystroke.

When you define the styles, be sure to select the font size you need for each style.
You should install the Language Pack for Office 2007.


Thanks puppydogbuddy - However, I am not looking to localize office to Arabic (i.e. Menus, User Interface, Help, Dictionary, Thesaurus, and Spell Checker)

lwebber - Great tip on the shortcut key!  It sounds like your suggested approach will require me to switch styles manually; if I paste Arabic into my word doc, it seems I will still need to highlight what I have pasted and select the ArabicText style?

I have been hoping there is a way to select a style by e.g. code page so that if Arabic letters are typed/pasted, the style is already defined...
Rowby Goren Makes an Impact on Screen and Online

Learn about longtime user Rowby Goren and his great contributions to the site. We explore his method for posing questions that are likely to yield a solution, and take a look at how his career transformed from a Hollywood writer to a website entrepreneur.

Nope -- Word won't apply a style automatically in those circumstances. But you could create a very simple macro to paste text and apply a style in a single keystroke. See the code snippet below for a suggestion. You could assign this macro to a keystroke, and simply press that keystroke instead of Ctrl+V to paste and style all in one step.
Sub PasteArabic()
    Dim targetRange As Range
    Dim oldLength As Long
    Set targetRange = Selection.Range.Duplicate
    oldLength = Len(ActiveDocument.Range.Text)
    targetRange.PasteAndFormat wdFormatPlainText
    targetRange.MoveEnd unit:=wdCharacter, Count:=Len(ActiveDocument.Range.Text) - oldLength
    targetRange.LanguageID = wdArabic
    targetRange.Style = "ArabicText"
End Sub

Open in new window


Great - thanks for your help!
I know you have accepted a solution and I have no problem with that, but I think you should know that the Single Language Pack is flexible as to what components you can activate and use. ...e.g. you can choose to activate only the proofing tools (which will enable the auto-detection and auto-correction of Arabic text in an English document.

See this link:

And they provide the flexibility of switching the entire user experience, including menus and help <<<<<or>>>>>>> only using proofing tools, such as spell checker, dictionary and thesaurus to any of 37 different languages.


>>  auto-detection and auto-correction of Arabic text in an English document
Thanks - I checked your link but did not see anything that confirmed that the Language Pack would automatically use a DIFFERENT style (that I configure) from that used for English for any Arabic text that is typed or pasted into the document.

Is it your understanding that the Language Pack can do so, and if so, can you tell me how you know this (or post a link that confirms it)?

I don't think Word ever applies styles automatically to pasted text. But I agree that you should install the language pack -- if only to loss those red squiggles!
I am going by the information provided in the last link I gave you.  Just scroll down to the first image [the Language Configuration Dialog] in the link I gave you and look at the options that you can choose or not choose.

mark selected Text as:  Arabic
      the speller and other proofing tools automatically use dictionaries of the selected language, if available

checkbox1:  Do not check spelling or grammar
checkbox2:  Detect language automatically

I am alerting you to the above as a courtesy.  If you choose not to investigate further, that is your decision.


k thanks-

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial