sosauce / CuteCalc

CuteCalc is a simple,lightweight and open-source calculator app for Android.
GNU General Public License v3.0
98 stars 8 forks source link

UI Bug: Backspace button is off-center in portrait mode, and too big in landscape #31

Closed realeatham closed 6 months ago

realeatham commented 7 months ago

Describe the bug See images

Screenshots Screenshot_20240128_222105 Screenshot_20240128_222059

Smartphone (please complete the following information):

Additional context Add any other context about the problem here.

sosauce commented 7 months ago

Okay will work on it, also note that OneUI is not an OS, just a skin, Android 14 is an OS 😉

realeatham commented 7 months ago

Ok thanks , Also I said the skin version on purpose as I wasn't sure which one you wanted.

sosauce commented 7 months ago

Oh okay, yeah it's always good to give me the skin version, I got some bugs on realme UI that I didn't get on HyperOS (basically MIUI)

realeatham commented 6 months ago

Screenshot_20240218_102744 It got worse

sosauce commented 6 months ago

oof, I don't get this so it's hard for me to know if its fixed

realeatham commented 6 months ago

Ok. Could be related to the screen, font and zoom sizes maybe? I'll try different combinations.

realeatham commented 6 months ago

I can confirm it still happens with default and minimum settings let's you.(I use an app to lower it more)

sosauce commented 6 months ago

Maybe because its actually an image, I converted it back to text maybe it should solve the issue

If you wanna test on your device change to this :

                Button(
                    onClick = {
                        viewModel.handleAction(CalcAction.RemoveLast)
                        if (buttonVibrationEnabledState.value) {
                            vibration()
                        }
                    },
                    colors = ButtonDefaults.buttonColors(MaterialTheme.colorScheme.tertiaryContainer),
                    modifier = Modifier
                        .weight(0.15f)
                ) {
                    Text(
                        text = "⌫",
                        color = MaterialTheme.colorScheme.onBackground,
                        fontSize = 35.sp,
                        fontFamily = GlobalFont,
                        modifier = Modifier.align(Alignment.CenterVertically)
                    )
                }
realeatham commented 6 months ago

Screenshot_20240218_222503

It did not work at all

realeatham commented 6 months ago

The font does not support it

realeatham commented 6 months ago

I just checked Google fonts

realeatham commented 6 months ago

A separate font which supports this icon will have to be used for it only.

realeatham commented 6 months ago

Maybe the system font could be used?

realeatham commented 6 months ago

Segoe UI Symbol has a nice icon for it

sosauce commented 6 months ago

dang I was searching a font with a nice icon for it, others were ugly, thanks

sosauce commented 6 months ago

You have a S21 with a 6"1 1080 x 2400 screen right ? I'm gonna create an emulator with ur screen size to get a more accurate representation

sosauce commented 6 months ago

Screenshot_20240218_222503

It did not work at all

Also, the code snippet was for landscape layout ;) mb for not saying

realeatham commented 6 months ago

You have a S21 with a 6"1 1080 x 2400 screen right ? I'm gonna create an emulator with ur screen size to get a more accurate representation

Probably, that's what Google said.

Keep in mind that I have screen zoom set to minimum and font size set to 0.6 using https://github.com/zacharee/Tweaker

sosauce commented 6 months ago

Ohhhh okay I see, that prolly influences some things. I'll keep in mind

realeatham commented 6 months ago

I did try it with default but it still happened, just less bad.

sosauce commented 6 months ago

I've changed it to a Text anyways, so it should scale like other buttons since they also use text

realeatham commented 6 months ago

Can you commit that?I will test in a bit

sosauce commented 6 months ago

Sorry was out, yes sure

realeatham commented 6 months ago

its fixed as of the latest github commits

sosauce commented 6 months ago

Okay, re open if needed