Android Keybaord


#21

That gives error probably because it initializes too early. Probably if you initialize it later like that, you will have no error:

in ofApp.h:
ofxAndroidExtendedEditText* eet;

in ofApp.cpp:
eet = new ofxAndroidExtendedEditText ();
eet-> add (“Test EditText”);


#22

Yes, that was it. Amazing, this is really useful (also gives me a clue on how to extend it a bit.

Thanks so much for all your help!

Fred


#23

I added an initialize() method to fix the problem.
You can define now in the stack as well.


#24

Hi Racs
First of all your edit text addon in a neat one… i appreciate it.

I am having some issues though, the function getText() doesn’t seem to return the text from the edit text box

i did two Double taps

everything else works fine

Please help.

Thank you very much


#25

How do you invoke the touchDoubleTap method when the full screen keyboard is shown?


#26

Ouh, the “Done” button worked out just fine. Though had to add the line:

eet.setImeOptions(EditorInfo.IME_ACTION_DONE);

to the OFXAndroidExtendedEditText.java file.

Thank you!


#27

Hi @Rancs i’m using the add on. There is a way to set the position of the field? also when i press enter the field move down is there a function to block this? i guess is the java side.


#28

how can i get only the keyboard?


#29

I wrote this addon 2 years ago. I really don’t remember the workflow of the Android’s keyboard. Maybe you can try something like:

    InputMethodManager inputMethodManager = (InputMethodManager) view.getContext().getSystemService(Context.INPUT_METHOD_SERVICE);
    inputMethodManager.showSoftInput(mGLView, 0);

The best implementation style I could find for general usage was the usage of an Extended EditText view.


#30

okay, will try it i was using this lines but was crashing.


final InputMethodManager imm = (InputMethodManager) activity.getSystemService(Context.INPUT_METHOD_SERVICE);
				imm.showSoftInput(eet, InputMethodManager.SHOW_FORCED);

#31

also your addons will work the same in android studio? i mean talking about the setup.


#32

Yes, you need to put Java files into /java/cc/openframeworks and C++ files into /jni.

If you use CMake, you do also need to add cpp files into CMakeLists.txt (we use CMake)


#33

okay, also i try to only use the keyboard but every time is crashing ,also try some methods to make trasnparent the text edit UI but only get kinds of grey it possible to get it working stable only the keyboard?