Keyboard icon indicating copy to clipboard operation
Keyboard copied to clipboard

Keyboard don't respect nav bar

Open AFT-syd opened this issue 1 year ago • 8 comments

Checklist

  • [X] I can reproduce the bug with the latest version given here.
  • [X] I made sure that there are no existing issues - open or closed - to which I could contribute my information.
  • [X] I made sure that there are no existing discussions - open or closed - to which I could contribute my information.
  • [X] I have read the FAQs inside the app (Menu -> About -> FAQs) and my problem isn't listed.
  • [X] I have taken the time to fill in all the required details. I understand that the bug report will be dismissed otherwise.
  • [X] This issue contains only one bug.
  • [X] I have read and understood the contribution guidelines.

Affected app version

1.1.1

Affected Android/Custom ROM version

Emui 12

Affected device model

Huawei p30

How did you install the app?

Google Play Store

Steps to reproduce the bug

Any time the keyboard is visible, it sits underneath the nav bar, but only when im using the danish layout

Expected behavior

Whole keyboard visible

Actual behavior

Nav bar hides buttom of keyboard

Screenshots/Screen recordings

Screenshot_20241217_105050

Additional information

No response

AFT-syd avatar Dec 17 '24 10:12 AFT-syd

Please show what have you set in Keyboard section in Fossify Keyboard's Settings.

Aga-C avatar Dec 17 '24 10:12 Aga-C

Screenshot_20241217_133458 Apparantly not only in danish layout. The issue is back, now with english

AFT-syd avatar Dec 17 '24 12:12 AFT-syd

Please show what have you set in Keyboard section in Fossify Keyboard's Settings.

Uploading Screenshot_20241217_133739.jpg… Screenshot_20241217_133732_org fossify keyboard

AFT-syd avatar Dec 17 '24 12:12 AFT-syd

The screenshot of settings doesn't work. Please upload it again.

Aga-C avatar Dec 17 '24 13:12 Aga-C

  1. I didn't mean Keyboard language. I meant Keyboard section (Tastatur in your language). But at least, please write what do you have set in Keyboard height.
  2. If you lower the keyboard height, do you still have this problem?
  3. Do you encounter this problem now every time when showing keyboard in any language?

Aga-C avatar Dec 17 '24 15:12 Aga-C

My mistake. Yes the issue is not changing when i increase or lower the height. The issue does not seem related to language as first suggested, but it still works periodicly in both languages. I have not changed other settings in the app or phone, just used different apps in the meantime. Screenshot_20241217_195815_org fossify keyboard

AFT-syd avatar Dec 17 '24 19:12 AFT-syd

Same issue here, regardless of the language. The app version is 1.1.1, device model Huawei Nova 8i, Android version 10 (or EMUI 11.0.1 for Huawei).

One thing I have spotted: it happens when I start typing, after previosly watching videos on fullscreen on a mobile browser. It also happens when I rotate the screen from horizontal to vertical mode while the keyboard is still activated. In order to fix it, I need either to rotate again, or to switch to the system keyboard and then switch back to Fossify Keyboard.

Screenshot_20241229_160112_org mozilla firefox_beta

Balkanec avatar Dec 29 '24 14:12 Balkanec

Same issue here with an fr map. Changing keyboard height does not fix anything.

Wanou38 avatar Jan 05 '25 19:01 Wanou38

Also running into the issue. (Also on Android 10). I can also confirm I can trigger the issue by watching a Youtube video on fullscreen mode using Firefox. But it also happens with other fullscreen apps, like e.g. OpenTyrian.

Rotating the screen again afterwards fixes the issue.

Other than this, I'm really enjoying this keyboard.

ignoreImageMinify

adnub avatar Oct 25 '25 18:10 adnub

I think I found what's going on. On Android 10 and lower an issue exists that padding doesn't work correctly after exiting a fullscreen application (https://issuetracker.google.com/issues/266331465).

I've messed around a bit, and added a workaround in the file /app/src/main/kotlin/org/fossify/keyboard/services/SimpleKeyboardIME.kt

I've changed the function setupNavigationBarPadding as such:

    private fun setupNavigationBarPadding() {
        window.window?.apply {
            WindowCompat.setDecorFitsSystemWindows(this, false)
            ViewCompat.setOnApplyWindowInsetsListener(binding.keyboardHolder) { view, insets ->
                val bottomPadding = insets.getInsets(WindowInsetsCompat.Type.systemBars()).bottom
                binding.keyboardHolder.updatePadding(bottom = bottomPadding)
                ViewCompat.onApplyWindowInsets(view, insets)
            }
                   
            // Fallback for Android 10 and below if insets are unreliable
            if (Build.VERSION.SDK_INT <= Build.VERSION_CODES.Q) {
                val navBarHeight = getNavigationBarHeight()
                binding.keyboardHolder.setPadding(0, 0, 0, navBarHeight)
            }
        }
    }

And I added the following function

    private fun getNavigationBarHeight(): Int {
        val resId = resources.getIdentifier("navigation_bar_height", "dimen", "android")
        return if (resId > 0) resources.getDimensionPixelSize(resId) else 0
    }

I've built a debug version and tested this on my Android 10 device and it seems to working fine here.

If this looks good to you guys I'd be willing to try and generate a PR for it, but I'm a complete noob when it comes to this. But I would try to follow the contributing guidelines as best as I can.

adnub avatar Oct 25 '25 20:10 adnub

I have just removed those hardcoded system bar height helpers from all Fossify apps. I'll be working on this, thanks.

naveensingh avatar Oct 25 '25 20:10 naveensingh

It should be fixed in https://github.com/FossifyOrg/Keyboard/releases/tag/1.6.0

naveensingh avatar Oct 29 '25 19:10 naveensingh