|
-
Sep 11th, 2009, 01:38 PM
#1
Thread Starter
Hyperactive Member
[RESOLVED] Charsets, Fonts and Codepage questions
Hello everybody,
I have a question about charsets. I have an application in which on load I initialize the fonts the form and controls using whatever fonts are set in the users windows. Now I am porting this application to use arabic fonts. I am able to this by simply calling the charset property
obj.Font.Charset = 178 'Arabic Charset
My question is this, what if the current font doesn't support arabic script? I can always set the font name
obj.Font.Name = "Traditional Arabic" 'Some arabic font
but would like to use the font that is set in the users windows interface.
Here are my questions
1. Is there way of knowing if the current font can display arabic script or not? And if so use it, and if not then use a specfic arabic font?
2. What is the best way of determining if a system can display arabic fonts? Is it GetSystemMetrics(SM_MIDEASTENABLD) the only way or is there something else?
3. Should the codepage be set? Or by setting the charset that is enough?
4. I read this on the internet
cmdMyButton.Font.Charset = charsetCyrillic
cmdMyButton.Font.Name = ""
cmdMyButton.Caption = "Чао а тутто ил мондо!"
Setting the font name to an empty strings causes the Font object to choose the default font for the control's code page. Of course, you can also explicitly set a font name that you know supports that code page.
Does this mean that I just use the above code and it will select the default font that works with that specfic charset?
Thanks for your assistance.
Last edited by Hassan Basri; Sep 11th, 2009 at 01:43 PM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|