r/androiddev • • Sep 16 '18

Why does Android development feel like hell?

[deleted] — view deleted post

205 Upvotes

174 comments sorted by

View all comments

Show parent comment

0

u/[deleted] Sep 16 '18

[deleted] — view deleted comment

53

u/squeeish Sep 16 '18

Jesus christ the keyboard. This stackoverflow post sums it up well, I chuckle everytime I read it.

https://stackoverflow.com/questions/1109022/close-hide-the-android-soft-keyboard

I want to hide the keyboard. I expect to provide Android with the following statement: Keyboard.hide(). The end. Thank you very much.

0

u/[deleted] Sep 16 '18

[deleted] — view deleted comment

18

u/Zhuinden Sep 16 '18

Is the keyboard a software keyboard, or an external one? Does the keyboard cover the screen. Does it cover my UI, or maybe it doesn't overlap.

The real question is why can't I know if the keyboard covers the screen, and if yes, how many pixels does it take up?

And yet they give you bounding rects for the notch "safe area".

2

u/N1ghtshade3 Sep 17 '18

Ridiculous how such a stupid "feature" gets priority when Android manufacturers have yet to even produce a notched phone.

As far as I'm concerned I'm going to develop for a rectangular screen and if anyone has trouble seeing something at the top then they can get a new phone.

4

u/fearlesscat10 Sep 16 '18

I thought things would get better since we're just now migrating to Kotlin, but fuck man it's just the same shit. https://stackoverflow.com/questions/41790357/close-hide-the-android-soft-keyboard-with-kotlin

Maybe it's time to change industry.

16

u/[deleted] Sep 16 '18

[removed] — view removed comment

-1

u/fearlesscat10 Sep 16 '18 edited Sep 19 '18

I meant that maybe the experience would feel less hellish.

0

u/Gur814 Sep 17 '18

Kotlin is very useful for smoothing some of the rough edges of the Android framework. Extension functions are your new best friend. It doesn't change the underlying jank, but it can help hide some of it.

2

u/pjmlp Sep 17 '18

Until you need one of those APIs that are NDK only.

3

u/Zhuinden Sep 16 '18

Well you can reduce it to fun View.showKeyboard() and fun View.hideKeyboard()... but obviously you still won't know when it's open or not.

0

u/drabred Sep 17 '18

Cake recepie reference is spot on.