ankushsachdeva / emojicon Goto Github PK
View Code? Open in Web Editor NEWAndroid library to show emojicon dialog box over soft keyboard
Android library to show emojicon dialog box over soft keyboard
Is there anyway you can add this to jCenter. It would make it easier to distribute and use your library in other projects :)
I've implemented this library, but when I compile the project, I get this error:
Error:Execution failed for task ':app:processDebugResources'.
com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command '/home/orion/Android/Sdk/build-tools/21.1.2/aapt'' finished with non-zero exit value 1
I opened certain classes in the library and in the EmojiconsPopup class, when there's a reference to the R class, it says that R file does not exist.
Sorry for my bad English.
What could be the problem?
I tried to send emojiconEditText.getText().toString() into http request.Now on another web-service i tried to get those string from the server and display in on EmojiconTextView
But it show only "?????" insted of emoji icons..text show perfect but emoji icons not working fine..
How to use EmojiEditText in Dialog?
When i use that Edit Text in dialog it didn't show emoji layout properly.It open s Soft Keyboard & Emojis Dialog both combine.
Give me solution of this please.
Is there a way to modify this library to display the unicode character in the popup (edittext) instead of the corresponding drawable? I want to do this so that every device can display the emojii according to its own style and font
When using build tools 21.1.2 and compiling on api level 21, the emoji popup doesn't appear.clicking on the emoji icon just opens the keyboard. Please help
Isn't there any function or something that converts EmojiEditText getText to proper unicode bytes.
my JSON post return a 500 Response Code
I am using Python & MongoDB as backend
This emoji library is part of one of my android application,same application have desktop client also. Sent emoji can view mobile to mobile. But for cross platform facing issue that while passing emoji through desktop to mobile n vice versa,respective emoji is not reflecting at another client, Rather it shows single box only.
Kindly advice for cross platform emoji support.
As the title says. I found this project, that should be helpful (maybe you already know it): https://github.com/iamcal/emoji-data
I use this lib for add emojis to my chat app. But only in one chat activity works fine. When i chat with 2 peoples or more only one of them has emoji and in other activities click on emojiload image button not working... so whats the problem? I used example demo method for do this
I am facing this issue in all the devices i have tested in my office.
Whenever i try to open emojicon keyboard , first the Alphabetical Appears for a second and
then the Emojicon Keyboard.
Is there any way we can stop this from happening ?
Hi Sir,
I'm referring your emoji library from github. But I am not receiving some emoji from database server which used Emojicon.fromCodePoint(0x1f604) method. But emoji with Emojicon.fromChar((char) 0x263a) method works fine.
Please help me Sir. What changes should I do to get those emoji.
when I rename emoji file name with working emoji file name (.png file name) then that emoji work fine..
those starting with 0x1f__ are not working..
(not working) 4 byte
07-09 15:14:08.365: I/PARAMS(6801): username=xyz&password=xyz&to=abc&message=%F0%9F%98%8A&action=sendMessage&
(working) 3 byte
07-09 15:13:58.878: I/PARAMS(6801): username=xyz&password=xyz&to=abc&message=%E2%98%BA&action=sendMessage&
plz sir
Works as expected on lower api levels but from API level 21 the toggle fails. The popup shows on top of the edittext fields and the toggle button is obscured. Secondly there are intermittent times when the gridview of emojis disappears and leaves behind the header
hi.
when set status bar translucent the size of popup is wrong .how can i fix this issue?
Hi everyone. I'm using this awesome library, but i have a problem. I use this library in a custom softkeyboard and not in a dedicated application and it works but i have problem when the tablet (Lollipop version) is in landscape mode. In fact the popup occupies the whole screen and not the area of the keyboard.
i try this solution https://github.com/takenet/emojicon/blob/master/emojicon/src/main/java/github/ankushsachdeva/emojicon/EmojiconsPopup.java but it doesn't work for me.
Can you help me?
Hello Ankush,
Thanks for the code. I got crash for the OS 4.3. I'm not sure why it's happening!! Is there anything I'm missing. Please find the crash log below:
02-05 23:46:42.187: E/AndroidRuntime(20681): FATAL EXCEPTION: main
02-05 23:46:42.187: E/AndroidRuntime(20681): java.lang.NullPointerException
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.text.style.DynamicDrawableSpan.getSize(DynamicDrawableSpan.java:81)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.text.MeasuredText.addStyleRun(MeasuredText.java:207)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.text.StaticLayout.generate(StaticLayout.java:288)
02-05 23:46:42.187: E/AndroidRuntime(20681): at miui.dexspy.DexspyInstaller.invokeOriginalMethodNative(Native Method)
02-05 23:46:42.187: E/AndroidRuntime(20681): at miui.dexspy.DexspyInstaller.invokeOriginalMethod(DexspyInstaller.java:491)
02-05 23:46:42.187: E/AndroidRuntime(20681): at miui.dexspy.DexspyInstaller.handleHookedMethod(DexspyInstaller.java:405)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.text.StaticLayout.generate(Native Method)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.text.StaticLayout.(StaticLayout.java:147)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.text.StaticLayout.(StaticLayout.java:87)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.text.StaticLayout.(StaticLayout.java:66)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.widget.TextView.makeSingleLayout(TextView.java:6136)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.widget.TextView.makeNewLayout(TextView.java:5976)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.widget.TextView.onMeasure(TextView.java:6333)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.View.measure(View.java:15891)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:5035)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.widget.FrameLayout.onMeasure(FrameLayout.java:310)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.View.measure(View.java:15891)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.widget.GridView.setupChild(GridView.java:1417)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.widget.GridView.makeAndAddView(GridView.java:1344)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.widget.GridView.makeRow(GridView.java:341)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.widget.GridView.fillDown(GridView.java:283)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.widget.GridView.fillFromTop(GridView.java:417)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.widget.GridView.layoutChildren(GridView.java:1229)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.widget.AbsListView.onLayout(AbsListView.java:2042)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.View.layout(View.java:14329)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.ViewGroup.layout(ViewGroup.java:4585)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.support.v4.view.ViewPager.onLayout(ViewPager.java:1589)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.View.layout(View.java:14329)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.ViewGroup.layout(ViewGroup.java:4585)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.widget.RelativeLayout.onLayout(RelativeLayout.java:1076)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.View.layout(View.java:14329)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.ViewGroup.layout(ViewGroup.java:4585)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.widget.FrameLayout.onLayout(FrameLayout.java:448)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.View.layout(View.java:14329)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.ViewGroup.layout(ViewGroup.java:4585)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.ViewRootImpl.performLayout(ViewRootImpl.java:2028)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1782)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1056)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:5542)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.Choreographer$CallbackRecord.run(Choreographer.java:749)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.Choreographer.doCallbacks(Choreographer.java:562)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.Choreographer.doFrame(Choreographer.java:532)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:735)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.os.Handler.handleCallback(Handler.java:730)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.os.Handler.dispatchMessage(Handler.java:92)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.os.Looper.loop(Looper.java:137)
02-05 23:46:42.187: E/AndroidRuntime(20681): at android.app.ActivityThread.main(ActivityThread.java:5162)
02-05 23:46:42.187: E/AndroidRuntime(20681): at java.lang.reflect.Method.invokeNative(Native Method)
02-05 23:46:42.187: E/AndroidRuntime(20681): at java.lang.reflect.Method.invoke(Method.java:525)
02-05 23:46:42.187: E/AndroidRuntime(20681): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:756)
02-05 23:46:42.187: E/AndroidRuntime(20681): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:572)
02-05 23:46:42.187: E/AndroidRuntime(20681): at miui.dexspy.DexspyInstaller.main(DexspyInstaller.java:171)
02-05 23:46:42.187: E/AndroidRuntime(20681): at dalvik.system.NativeStart.main(Native Method)
02-05 23:46:42.217: I/Process(20681): Sending signal. PID: 20681 SIG: 9
Hi your library works fine when lazy swipe is not enabled. once install and enable lazy swipe emoji keyboard doesn't show.
Hi Ankush,
Thanks for the great project.
The emoji grid item click is not working on 2.3 and and 4.2.2 devices. However with lollipop the clicks work fine...can you suggest?
Thanks,
Ashish
when popup appears at large screen it sometimes fails to detect its width and use default width which is not match_parent.
plz do something for that...nice code written
Is there any gradle support for this project:
I mean to say any compile statement to integrate this project with an application.
For Integrating your project in my Android Studio Project i used the jar file generated in the bin
folder of your library, the library gets integrated and the app runs but where i have used the
EmojiconEditText and EmojiconTextView we get the following error.
01-07 10:27:45.161: E/AndroidRuntime(27777): android.view.InflateException: Binary XML file line #47: Error inflating class com.mypurpleslate.purpleslate.EditTextBackEvent
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.view.LayoutInflater.createView(LayoutInflater.java:620)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:696)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.view.LayoutInflater.rInflate(LayoutInflater.java:755)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.view.LayoutInflater.rInflate(LayoutInflater.java:758)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.view.LayoutInflater.inflate(LayoutInflater.java:492)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.view.LayoutInflater.inflate(LayoutInflater.java:397)
01-07 10:27:45.161: E/AndroidRuntime(27777): at com.mypurpleslate.purpleslate.ChatDetailsFragment.onCreateView(ChatDetailsFragment.java:223)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.support.v4.app.Fragment.performCreateView(Fragment.java:1786)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:947)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1126)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.support.v4.app.BackStackRecord.run(BackStackRecord.java:739)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.support.v4.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1489)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.support.v4.app.FragmentManagerImpl$1.run(FragmentManager.java:454)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.os.Handler.handleCallback(Handler.java:733)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.os.Handler.dispatchMessage(Handler.java:95)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.os.Looper.loop(Looper.java:157)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.app.ActivityThread.main(ActivityThread.java:5633)
01-07 10:27:45.161: E/AndroidRuntime(27777): at java.lang.reflect.Method.invokeNative(Native Method)
01-07 10:27:45.161: E/AndroidRuntime(27777): at java.lang.reflect.Method.invoke(Method.java:515)
01-07 10:27:45.161: E/AndroidRuntime(27777): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:896)
01-07 10:27:45.161: E/AndroidRuntime(27777): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:712)
01-07 10:27:45.161: E/AndroidRuntime(27777): at dalvik.system.NativeStart.main(Native Method)
01-07 10:27:45.161: E/AndroidRuntime(27777): Caused by: java.lang.reflect.InvocationTargetException
01-07 10:27:45.161: E/AndroidRuntime(27777): at java.lang.reflect.Constructor.constructNative(Native Method)
01-07 10:27:45.161: E/AndroidRuntime(27777): at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.view.LayoutInflater.createView(LayoutInflater.java:594)
01-07 10:27:45.161: E/AndroidRuntime(27777): ... 21 more
01-07 10:27:45.161: E/AndroidRuntime(27777): Caused by: java.lang.NoClassDefFoundError: github.ankushsachdeva.emojicon.R$drawable
01-07 10:27:45.161: E/AndroidRuntime(27777): at github.ankushsachdeva.emojicon.EmojiconHandler.(EmojiconHandler.java:36)
01-07 10:27:45.161: E/AndroidRuntime(27777): at github.ankushsachdeva.emojicon.EmojiconEditText.onTextChanged(EmojiconEditText.java:57)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.widget.TextView.setText(TextView.java:4015)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.widget.TextView.setText(TextView.java:3869)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.widget.EditText.setText(EditText.java:85)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.widget.TextView.(TextView.java:1372)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.widget.EditText.(EditText.java:60)
01-07 10:27:45.161: E/AndroidRuntime(27777): at android.widget.EditText.(EditText.java:56)
01-07 10:27:45.161: E/AndroidRuntime(27777): at github.ankushsachdeva.emojicon.EmojiconEditText.(EmojiconEditText.java:39)
01-07 10:27:45.161: E/AndroidRuntime(27777): at com.mypurpleslate.purpleslate.EditTextBackEvent.(EditTextBackEvent.java:22)
01-07 10:27:45.161: E/AndroidRuntime(27777): ... 24 more
01-07 10:27:45.171: E/ActivityManager(934): App crashed! Process: com.mypurpleslate.purpleslate
HI I am write "android" in edittext and add smiley then it add in last of "android+smiley_icon" now i move cursor to between "android" like "an" and "droid" then after i add smiley and its alwasy add in last of text in edittext like "android+smiley_icon" but in practical it add between "an+smiley_icon+droid" .
So how to fix this issue?
Thanks for good library
Is there a gradle version of this repo?
My app is crashing if i add this line:
EmojiPopup = new EmojiconsPopup(ChatRootView, getApplicationContext());
I think the problem is by get the root view.
I don't see logs.
View ChatRootView = findViewById(R.id.ChatRootView);
Hello,
I have a problem on my Xperia C4 phone when i open emojicon the icon of the keyboard disappear and my application blocked and i can't even click on the emojicon
Thanks for helping
It seems that for Lollipop, in EmojiconsPopup::setSizeForSoftKeyboard, we have to substract the size of "navigation_bar_height" as well as "status_bar_height" in case there's a navigation bar being displayed otherwise the emoji popup will take more space than the soft keyboard.
Does anyone knows how to integrate this project into the actual softkeyboard? I mean not the stock keyboard (AOSP), but the custom softkeyboard sample provided in the legacy android sdk.
Emoji's appear perfectly on edittext and textview. But when we do getText() on edittext, it returns empty strings, instead of unique codes for each emojis added.
Is there a gradle version of this repository?
these do not work in your textview
but in simple text view working perfectly.
please help.
The emoji images seem to be over saturated and so the yellow color appears more as a golden shade
Hi, First of all thanks for such a great piece of code. I am using your code in one of my project.
I have a Fragment A, here I click on a button and go to Fragment B. In Fragment B, I have EmojiView button to show and hide PopupWindow.
When I was in Fragment A, 13MB of memory was being utilised. After I moved to Fragment B and clicked on EmojiView button to show EmojiView, the memory graph goes upto 20 MB. Now when I come back from Fragment B to Fragment A then the memory graph still shows 20 MB after GC. The memory is not getting released.
Please help me out. Is there any View that might not be released?
Emojicon sort of works with Android Lollipop. However I encountered two problems:
if(Build.VERSION.SDK_INT >= 5.0) {
WindowManager wm = (WindowManager) mContext.getSystemService(Context.WINDOW_SERVICE);
Display display = wm.getDefaultDisplay();
Point size = new Point();
display.getSize(size);
int screenHeight;
screenHeight = size.y;
} else
screenHeight = rootView.getRootView()
popup.setBackgroundDrawable(new BitmapDrawable());
I don't know if these problems only affect my project or generally Lollipop devices. Wanted to let you know, just in case :)
As the title says. Here's the fix:
private void calculateSizeForSoftKeyboard() {
...
if (resourceId > 0 && getTopStatusBarHeight() > 0) {
heightDifference -= mContext.getResources()
.getDimensionPixelSize(resourceId);
}
...
}
private int getTopStatusBarHeight() {
Rect rect = new Rect();
((Activity) mContext).getWindow().getDecorView().getWindowVisibleDisplayFrame(rect);
return rect.top;
}
Hi, and thanks for an awesome library!
The library declares @drawable/ic_launcher
as the application:icon
inside the Manifest, so it's necessary to add tools:replace="android:icon"
to satisfy the merger. It's safe to remove the icon since it's not needed. I can submit a pull request later on, will you be able to review it?
How to set this emojicon keyboard in default option.
Hello Ankush,
Could you please look at the issue mentioned at basecamp. I am also getting the same issue.
http://stackoverflow.com/questions/28202788/android-get-emoji-from-emojiconedittext
Is there a method to clear history from cache or prevent history at some point. I use emoji option as password in parts of my app.
Seems like setSize arguments need to be switched in EmojiconsPopup constructor
minSdkVersion 15
targetSdkVersion 23
<github.ankushsachdeva.emojicon.EmojiconTextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Item Text"
android:id="@+id/itemPost"
android:fontFamily="sans-serif-light"
android:linksClickable="true"
android:autoLink="web"
android:textColorLink="#5BCFF2"
android:textColor="@color/black"
android:textSize="16dp"
emojicon:emojiconSize="24dp"
android:layout_marginLeft="16dp"
android:layout_marginRight="16dp"
android:layout_marginBottom="10dp" />
ERROR:
FATAL EXCEPTION: main
android.view.InflateException: Binary XML file line #205: Error inflating class github.ankushsachdeva.emojicon.EmojiconTextView
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:698)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:746)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:749)
at android.view.LayoutInflater.inflate(LayoutInflater.java:489)
at android.view.LayoutInflater.inflate(LayoutInflater.java:396)
at android.view.LayoutInflater.inflate(LayoutInflater.java:352)
at com.kiongo.indiana.adapter.StreamListAdapter.getView(StreamListAdapter.java:131)
at android.widget.AbsListView.obtainView(AbsListView.java:2271)
at android.widget.ListView.makeAndAddView(ListView.java:1769)
at android.widget.ListView.fillDown(ListView.java:672)
at android.widget.ListView.fillFromTop(ListView.java:733)
at android.widget.ListView.layoutChildren(ListView.java:1608)
at android.widget.AbsListView.onLayout(AbsListView.java:2106)
at android.view.View.layout(View.java:13905)
at android.view.ViewGroup.layout(ViewGroup.java:4498)
at android.support.v4.widget.SwipeRefreshLayout.onLayout(SwipeRefreshLayout.java:596)
at android.view.View.layout(View.java:13905)
at android.view.ViewGroup.layout(ViewGroup.java:4498)
at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1688)
at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1546)
at android.widget.LinearLayout.onLayout(LinearLayout.java:1451)
at android.view.View.layout(View.java:13905)
at android.view.ViewGroup.layout(ViewGroup.java:4498)
at android.widget.RelativeLayout.onLayout(RelativeLayout.java:953)
at android.view.View.layout(View.java:13905)
at android.view.ViewGroup.layout(ViewGroup.java:4498)
at android.widget.FrameLayout.onLayout(FrameLayout.java:461)
at android.view.View.layout(View.java:13905)
at android.view.ViewGroup.layout(ViewGroup.java:4498)
at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1688)
at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1546)
at android.widget.LinearLayout.onLayout(LinearLayout.java:1451)
at android.view.View.layout(View.java:13905)
at android.view.ViewGroup.layout(ViewGroup.java:4498)
at android.support.v4.widget.DrawerLayout.onLayout(DrawerLayout.java:1183)
at android.view.View.layout(View.java:13905)
at android.view.ViewGroup.layout(ViewGroup.java:4498)
at android.widget.FrameLayout.onLayout(FrameLayout.java:461)
at android.view.View.layout(View.java:13905)
at android.view.ViewGroup.layout(ViewGroup.java:4498)
at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1688)
at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1546)
at android.widget.LinearLayout.onLayout(LinearLayout.java:1451)
at android.view.View.layout(View.java:13905)
at android.view.ViewGroup.layout(ViewGroup.java:4498)
at android.widget.FrameLayout.onLayout(FrameLayout.java:461)
at android.view.View.layout(View.java:13905)
at android.view.ViewGroup.layout(ViewGroup.java:4498)
at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1688)
at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1546)
at android.widget.LinearLayout.onLayout(LinearLayout.java:1451)
at android.view.View.layout(View.java:13905)
at android.view.ViewGroup.layout(ViewGroup.java:4498)
at android.widget.FrameLayout.onLayout(FrameLayout.java:461)
at android.view.View.layout(View.java:13905)
at android.view.ViewGroup.layout(ViewGroup.java:4498)
at android.view.ViewRootImpl.performLayout(ViewRootImpl.java:1869)
at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1690)
at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:999)
at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:4217)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:725)
at android.view.Choreographer.doCallbacks(Choreographer.java:555)
at android.view.Choreographer.doFrame(Choreographer.java:525)
at android.view.Choreographer$FrameDisplayEventRecei
@ankushsachdeva : Thanks for the wonderful library. I have used this library in android application and it is working like a charm in my application. The Emoji keyboard is very helpful to show and post Emoticons from the app.
Now in my application I want to convert text Smiley also in Emoticons.
For Ex: If I type a string like Hello World :) :D then I want to convert it in Hello World Emoticons.
I have checked the files of your library and found a file People.java in which you have executed the below functions
Emojicon.fromCodePoint(0x1f604) Emojicon.fromChar((char) 0x263a)
So, I need to
How can I do these above 2 tasks, I am not able to find any solution for this. I want to do this dynamically, so that each text smiley can be converted to it's emoticon.
Please help me if you have any idea here, Thanks a lot in advanced.
Hi! I would like to use unicode characters instead of drawable in TextView of Popup . How can I solve this problem?Thank you
Hi. thanks for great library.
I am using your library and I want to pull up root layout after opening keyboard.
How can I do that?
I have been using this library to implement emoji on Android SoftKeyboard with this code
if (primaryCode == 32) {
LayoutInflater layoutInflater = (LayoutInflater) getBaseContext().getSystemService(LAYOUT_INFLATER_SERVICE);
View popupView = layoutInflater.inflate(R.layout.popup, null);
popupWindow = new EmojiconsPopup(popupView, this);
// final PopupWindow popupWindow = new PopupWindow();
popupWindow.setSizeForSoftKeyboard();
popupWindow.setSize(LayoutParams.MATCH_PARENT, LayoutParams.WRAP_CONTENT);
popupWindow.showAtLocation(mInputView.getRootView(), Gravity.BOTTOM, 0, 0);
// Bring soft keyboard up : NOT WORKING
final InputMethodManager mInputMethodManager = (InputMethodManager) getBaseContext()
.getSystemService(Context.INPUT_METHOD_SERVICE);
mInputMethodManager.showSoftInput(popupView, 0);
// If the text keyboard closes, also dismiss the emoji popup
popupWindow.setOnSoftKeyboardOpenCloseListener(new OnSoftKeyboardOpenCloseListener() {
@Override
public void onKeyboardOpen(int keyBoardHeight) {
}
@Override
public void onKeyboardClose() {
if (popupWindow.isShowing())
popupWindow.dismiss();
}
});
popupWindow.setOnEmojiconClickedListener(new OnEmojiconClickedListener() {
@Override
public void onEmojiconClicked(Emojicon emojicon) {
mComposing.append(emojicon.getEmoji());
commitTyped(getCurrentInputConnection());
customToast("" + emojicon.getEmoji());
}
});
popupWindow.setOnEmojiconBackspaceClickedListener(new OnEmojiconBackspaceClickedListener() {
@Override
public void onEmojiconBackspaceClicked(View v) {
KeyEvent event = new KeyEvent(0, 0, 0, KeyEvent.KEYCODE_DEL, 0, 0, 0, 0, KeyEvent.KEYCODE_ENDCALL);
customToast(" " + event);
handleBackspace();
}
});
The library works fine, but when I use emoji in TextMessage Application, they appear like android style and not like they are in the library. How to solve it? This is the screenshot:
I am trying to use the emoji pop up in a chat app but when testing the emulator and the real nexus 5 displays the pop up over the Edit text also it doesn't respond to the back button press event.
When testing on an Asus zenfone 2(That has the same android version and the same screen resolution ) or Samsung Galaxy tab S 10.5 (which has higher resolution) it preforms greatly
see the title,
it calculates wrong offset for positioning if Activity extends from AppCompatActivity
When phone rotate in landscape mode emoji keyboard not working.Please give me a solution.Thanks in adv.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.