Typing accented characters in JavaFX 2 applications not working? - javafx-2

I'm developing a javafx-2 application and I want the user to be able to type Greek accented characters in a Textfield using a 'dead key'. Unfortunately, the accents are ignored. The javafx-2 samples provided by oracle behave the same way.
I've only checked on a mac running Lion. Java Swing applications don't have this problem. I have installed the latest JRE provided by apple (1.6.0_31-b04-414).
Thanks,
Nikos

You may want to try JavaFX 2.1 (dev preview: http://www.oracle.com/technetwork/java/javafx/downloads/index.html)
I had no problems with Greek accented characters there:
UPD: Typing these characters works as well in 2.1, see screenshot with characters entered from keyboard using dead keys for Greek Polytonic keyboard:

I am having the same problem with FX8. One solution would be to write a textproperty listener to take care of that, unless it is fixed later on. Coming from Swing it is true I did not have that problem either. I am using Windows7.

Related

Accented characters in Chrome Packaged app webview not showing up

I am developing a Chrome Packaged app that has a webview in it. The problem is that I cannot type any sort of accented character (such as é, ç, ê) in a text input that is inside the webview. When I try to type é, for instance, I only get e in the text field. Strangely I can copy and paste accented characters into the webview text field without a problem.
Text inputs that are outside the webview work ok. This issue only seems to happen when running the packaged app on Mac OSX (It works fine on Windows). Other official sample apps that use webviews also have the same issue.
I have already checked if UTF-8 is being used by both the app and the webview itself, and it is.
Any idea of what might be happening?
Like lazyboy commented, this has been fixed since Chrome 34. It was actually a bug in previous versions of Chrome.

Accented characters using JavaFX on Linux

I'm developing an application and just noticed that not a single accented character, for example, the Brazilian Portuguese "é", neither "ã" are displayed when I'm running the JavaFX application on Linux.
BUT, if I copy/paste those characters they appear normally, so I don't think it's an encoding problem.
On the other hand, the exactly same code works on Windows and those characters are displayed normally.
Is this a known bug?
Thanks in advance.
I've seen this problem in a project which a team member was using Eclipse on Windows, with default encoding to ISO-8859-1, while I was using UTF-8 on Linux.
So, if you're using Eclipse, check your encoding at Window > Preferences > General > Workspace, then Text file encoding group.

[mono]Arabic text rendering in linux / monodevelop 2.6

I've been instructed to port a .NET/C# Windows application to linux (XUbuntu 11.10 or SliTaz 4). This application should be capable of rendering Arabic texts in part or all of its texts.
I managed to modify the Windows application so that it properly shows Arabic texts. I had to switch UseCompatibilityText to true.
When in linux, I tried to look for the same property. No luck. Is it a question of being using an old version of Mono? Is it something not yet supported?
Is there any way around this issue?
Thanks a lot in advance!
Antonio
Ok, I'm new to MonoDevelop, but I saw your posting, and I have to say that when I tried to use Arabic in an "entry" box as a quick test, I had no trouble. This MD is straight out of the box, I didn't have to do anything other than coding and grab a small piece of Arabic text. I am using MD 2.8.8.6 on my mac.
Oops, let me check the same on my Linux box. I am using Kubuntu 12.04, and MD 2.8.6.3, and the same test above works. I'm not sure what exactly isn't working on yours, maybe my test is not extensive enough, or maybe you want to upgrade your version?
Cheers

How to display unicode strings of variables in Netbeans

I recently changed into Netbeans for developing my C++ codes, but I faced a strange problem. While trying to watch the program step by step, Netbeans doesn't show the value of Unicode variables correctly, while it doesn't have any problem with ASCII characters.
I checked the settings of my environment, but I couldn't find anything helpful.
Could anyone tell me how I can solve the problem? (I use Netbeans in ubuntu)
Bests.
Are you having an issue seeing the output in the console? If so, take a look at: Netbeans console does not display Bangla unicode characters for a possible solution.

Arabic words problem in LWUIT on some models

I've created a gui using LWUIT which uses Arabic words (and so it is right to left)
It works fine on some models (Sony Ericsson T700 or Elm for example). But on some other models (e.g. Sony Ericsson w800) words are not displayed correctly: letters are separated and displayed one by one from left to right.
I have absolutely no clues about the reason.
I found this thread:
LWUIT : issue in showing arabic words ?
This post is answered by Shai Almog who is one of LWUIT developers.
So I added below line to my code:
list.getStyle().setFont(Font.createSystemFont(Font.FACE_SYSTEM, Font.STYLE_PLAIN, Font.SIZE_MEDIUM));
But it doesn't solve the problem.
1- Shai has answered that system fonts should be used. Is my code correct in order to set system font?
2- any other clues?
I have tested my application with both LWUIT 1.5 and 1.4 and both are the same regarding this problem.
Can anybody help me out of this?
Thank you in advance
AFAIK some Sony Ericsson mobiles having problem while showing Arabic font. It will be discussed in this forum.
OK, I searched for the problem and now I got something to say:
It seems there's a problem when we use LWUIT on old SonyEricsson models to show Arabic texts. The problem doesn't show up on newer SE models and you won't have this problem when you use standard jme or j2me polish. (As you see in my original post, w800 has the problem but T700 doesn't. so somewhere between 2005 and 2008 the problem is solved).
System fonts have this problem and you can't use bitmap fonts since LWUIT doesn't support bitmap fonts for Arabic words. (see this: LWUIT : issue in showing arabic words ? )
How to solve it :
A friend on the net guided me to this solution:
To fix the first problem you should reshape the string yourself, I
tried to search for some similar code, this might help you
http://code.google.com/p/glyph-util/source/browse/trunk/src/com/ahmadiv/dari/DariGlyphUtils.java
You should map each character to the correct glyph according to its
location in the word, and the characters surrounding the characters.
This might help you: http://unicode.org/charts/PDF/UFE70.pdf
Then, mirror the words to finally fix the problem.
Finally, add the fix to drawString() method of LWUIT.
Just, final note..this don't worth the headache. The handsets that
have this problem are very old handsets. I think you could skip
supporting them. We already stop supporting them.
I accepted his final advice, so I didn't solved the problem at last, I simply left it :-)

Resources