Solved

TXPManifest affects TEdit's text (D7)

Posted on 2004-10-11
6
394 Views
Last Modified: 2008-01-09
I have a form with an edit box. At run time I press Alt+Shift (XP) to change language and set edit1.text. Setting CharSet to ARABIC_CHARSET every thing is ok. I can draw edit1.text on image1.canvas using above charset.
Now I add XPManifest1 to form1. I redo above procedure and obtain ????... .
Is edit1 using unicode characters inside? How can I use edit1.text, either by making edit1 act as normal or using a function to get the simple string?
In fact, how can I store edit1.text in a variable and draw it on image1.canvas when needed?
0
Comment
Question by:szayeri
  • 3
  • 2
6 Comments
 
LVL 14

Accepted Solution

by:
DragonSlayer earned 125 total points
ID: 12278321
In order to use Unicode, you have to use the Unicode-enabled 3rd party controls at http://tnt.ccci.org/delphi_unicode_controls/
0
 

Author Comment

by:szayeri
ID: 12287908
Dear DragoSlaver
Thank you for your comment. I'm not searching for unicode-enabled components. I do know TNT (of course, I still do not know how to create and use unicode string tables!). I prefer NOT to use 3rd party components. My problem is with TEdit + TXPManifest.
0
 
LVL 14

Assisted Solution

by:DragonSlayer
DragonSlayer earned 125 total points
ID: 12289667
How did you draw the text? If I recall correctly, you need DrawTextW in order to draw in unicode.
0
 

Author Comment

by:szayeri
ID: 12299188
Thank you DragoSlayer
Your comment does not help or I could not use it.
I found something more interesting. Putting two TEdit and using Edit1.Text:=Edit2.Text in a button click after I have pressed Alt+Shift (as above) and Edit2.Text is in my languge (Arabic) sets those arabic characters of Edit1.Text to question marks and English characters are correct (both in Edit1.Text and Image1.Canvas)!
Is it a bug in D7?
I should say again that this problem does not happen without TXPManifest.
Can I use XP styles without using TXPManifest (if it helps)?
0
 

Author Comment

by:szayeri
ID: 13362786
I did not find the reason to my problem but I found that changing the windows "default language" to "Arabic" solves it.
Ofcourse, the above comments are quite true (as I know). So I have splitted the points to those who spent time to help me.
Thanks again!
0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

759 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now