Search code examples
androidcustom-keyboard

Is it possible to set a custom layout for a key in keyboard?


I need to create a custom keyboard for android with specific design and behavior of keys on it (design: https://i.sstatic.net/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?


Solution

  • 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.