I need to implement a (soft)keyboard for an Android application.
Is GridLayout the correct View widget to contain all the keys?
Or is there other widget more suited for this specific requirement?
I think you just need a KeyboardView, it's very easy, you don't need to make all the keys or use specific layouts.
here a tutorial: http://www.fampennings.nl/maarten/android/09keyboard/index.htm
And here you will see a implementation that I made:
Soft keyboard's POPUP layout
Related
I need to create a custom keyboard for android with specific design and behavior of keys on it (design: https://i.stack.imgur.com/Bkv8k.jpg). I think this is possible only with creating a custom interface of keys but I didnt found any paths to set custom views for them.
Can I set (and how I can do it if it possible) custom layout for keys on my keyboard?
The problem has solved. Answer is simple - just make your own Keyboard and KeyboardView classes in project then rewrite onDraw method in KeyboardView. After this, you can change default keyboards classes to yours in your keyboard service.
I have successfully made a very basic custom keyboard for Android based off of this tutorial. The problem is, this keyboard looks very odd and outdated for Android lollipop:
Image of the current keyboard:
I have been looking at other keyboards such as the default OS keyboard and this one:
And they look much better for Android.
How can I modify the color scheme and style of my keyboard to look better?
It is also worth noting I am making a keyboard that is very similar to the second example (it will just have a few extra buttons).
If you want a lot of control and be able to do things dynamically, I suggest you ditch the xml layout and KeyboardView class and make your own custom keyboard view
I am in a situation like i have to generate UI Controls like Button,Switcher,Progress Bar, Label text etc based on my list Items .
I am looking for a way to generate the controls in a View and add Views with generated controls in a Layout .
Can anyone give me a proper way to do that?
Why not to use Fragments?
Google docs about this here
and little tutorial here
You may want to take a look at the Metawidget source code. The Android version of Metawidget makes extensive use of generating Views and Layouts at runtime (e.g. see org.metawidget.android.widget.widgetbuilder.AndroidWidgetBuilder). You may even find Metawidget itself will suit your needs (it's designed to be embedded into projects for use-cases such as this).
I'm building an App for Android that already exists for iOS. On iOS, we really like to use the listview grouped style to show details and forms. It is really useful to show details of objects that we don't know how much properties they have before loading it.
I know that Android doesn't have a similar tableview style. And I don't want to use a custom library to recreate it, because I don't want to force an iOS like interface to my Android's users.
But how would you create a consistent Android interface that show similar information? Do you have example for me?
First of all, your instinct to not force iOS style UI onto Android users is correct and I respect you for it.
Android's ListView is roughly the equivalent of iOS's UITableView. There are important differences. For instance, you should never use a ListView inside another scrollable container. If a ListView is in a particular layout, it should (usually) be the only scrollable component. If you want multiple ListViews in a layout, you probably don't want ListViews at all. You should instead use (vertical) LinearLayouts and add the items in order.
Cyril Mottier writes excellent posts on implementing custom behavior for Android's ListView.
If you want to display data in a list then you can use the ListView. Here is a great article about how to use it.
I want to create a custom Android keyboard that is in a arc like shape, but I don't know if it is at all possible or how to do it. So I'd appreciate being pointed in the right direction
Yes, its possible to create a non-rectangular keyboard. Check the android softkeyboard implementation and change the layouts to what you want. AFAIK, its using a custom view which handles the buttons addition/removal, you need to change this to achieve this.