Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Very special Chars #1

Open
elbajo opened this issue Nov 27, 2013 · 3 comments
Open

Very special Chars #1

elbajo opened this issue Nov 27, 2013 · 3 comments
Labels

Comments

@elbajo
Copy link

elbajo commented Nov 27, 2013

Before i start,
Any ideas if your project would solve my issue?
http://code.google.com/p/android/issues/detail?id=62906

Thank you!

@sumio
Copy link
Owner

sumio commented Dec 3, 2013

@elbajo, thank you for having interest!
In issue 62906, is your example of character "PERSON WITH FOLDED HANDS" (U+1F64F)?

I wrote simple Activity with a EditText whose contentDescription is "\uD83D\uDE4F" (which is Java expression of U+1F64F) and launched uiautomatorviewer.

protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);
    EditText editText = (EditText)findViewById(R.id.editText1);
    editText.setContentDescription("\uD83D\uDE4F");
}

The results was the same as yours. the same exception occurred.

By contrast, uiautomator script to search the EditText was finished correctly with normal IME. Is it the same as you?

public void testEmoji() throws Exception {
    UiObject editText = new UiObject(new UiSelector().description("\uD83D\uDE4F"));
    editText.setText("Hello World!");
}

Anyway, Uiautomator Unicode Input Helper, my project, doesn't solve the issue of uiautomatorviewer,
but enable you to input any android smileys (aka emoji) defined by Unicode 6.0 as follows:

public void testEmojiInput() throws Exception {
    UiObject editText = new UiObject(new UiSelector().description("\uD83D\uDE4F"));
    editText.setText(Utf7ImeHelper.e("\uD83D\uDE4F"));
}

But I tested the above code only on Nexus7 (2013), Android 4.4, it would run properly on Android 4.1 to 4.3.

Thank you!

@elbajo
Copy link
Author

elbajo commented Dec 3, 2013

Thank you for your response, I use the github project "AndroidViewClient" so intreract with an android Phone but this project uses Uiautomator to locate the elements so it crashes each time there is an emoji...
It's wired that when you use uiautomator it works and when "AndroidViewClient" uses it it crashes.
But yes you reproduced the bug correctly, i hope google will do the same!

@sumio
Copy link
Owner

sumio commented Dec 7, 2013

@elbajo, if you don't use AndroidViewClient, do you reproduce the bug?
I wonder if AndroidViewClient triggers the bug or not.
If the bug is reproduced by using with ONLY AndroidViewClient, I guess that AndroidViewClient parses a xml of view hierarchy like uiautomatorviewer and uiautomator doesn't.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants