Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improving the text scale control? #249

Open
Mrnofish opened this issue Nov 28, 2024 · 10 comments
Open

Improving the text scale control? #249

Mrnofish opened this issue Nov 28, 2024 · 10 comments
Assignees
Labels
bug Something isn't working

Comments

@Mrnofish
Copy link

The ability to change the text scale is great, however I'm encountering two issues:

  • the slider being on the bottom edge of the screen constitutes a problem when Android is set to Gesture control: trying to interact with the slider, the system takes over fairly frequently and interprets the interaction as a gesture, instead of passing the movement to the slider itself.
  • The steps are a bit too large. For instance, at 0.9 some smaller texts are hard to read (this also depends on certain colors not being very readable when using the Black Theme), but setting 1.0 results in characters that are a bit too large.
@farfromrefug
Copy link
Collaborator

farfromrefug commented Nov 29, 2024

@Mrnofish thanks a lot, will look into it
EDIT: i fixed it. Now about the step being too large, actually you can get as precise as you want if you slide slowly. It was only a display thing to show 0.1 instead of 0.15. Now it shows 2 digits

@0-5-0
Copy link
Contributor

0-5-0 commented Dec 5, 2024

In my case I guess, since it's a large scale, it's wanting it to be a round number.. so pulling my finger off the screen 80% of the time nudges it to 0.91 or 0.89 :). I'm not sure who would use the app at 0.50 or 2 so maybe it's just the steps as you scroll over the bar could be "wider", if that makes sense.

If it jumps to the next number every |..|..|..|..| increment then maybe having it jump to the next number every |.....|.....|.....|.....| increments instead, sort of..

@farfromrefug
Copy link
Collaborator

@0-5-0 i will make it so you can enter a custom value with the keyboard

@farfromrefug farfromrefug self-assigned this Dec 5, 2024
@farfromrefug farfromrefug added the bug Something isn't working label Dec 5, 2024
@0-5-0
Copy link
Contributor

0-5-0 commented Dec 6, 2024

Works well with the custom value/keyboard, not sure if there would need to be sanity checks to prevent entering 999.0 :), though you have the reset button and relaunching the app fixed any weird artifacts after I entered 999 to test :D

@farfromrefug
Copy link
Collaborator

@0-5-0 good point Will add a check

@0-5-0
Copy link
Contributor

0-5-0 commented Dec 10, 2024

The checks work but are a bit fast, if I try to type 0.90 it sends it to 0.50 if I don't type the 0.90 fast enough. Still workable (I'm able to type 0.90 fast enough) but it might be difficult for others.

I'm still not sure if just having a set of defined smallest, small, medium, large, extra large criterias might be "better". If some users truly would need more granularity to select 0.50 vs 0.51 vs 0.52, if those minor differences in the interface would even be realistically perceived on a device.

It might also help with testing that stuff doesn't overlap if it's defined sizes, unless you're testing each interface change with 0.50 up to 2.00.

@Mrnofish
Copy link
Author

There seem to be a few bugs in 145:

  1. Under certain conditions, the preview for the lower pane, the one containing the forecasts, stops getting updated, and only the upper one reacts to the controls. One such condition is when an out-of-bounds value gets entered (by mistake) in the text field, but also the following bullet point (which might also be related to an out-of-bound value being set in some weird way)
  2. Interacting with the slider resets the scale factor to its minimum even though the finger is still on the slider cursor.
  3. Playing around with the controls will result in CTDs after a while.

@farfromrefug
Copy link
Collaborator

@Mrnofish CTDs?

@Mrnofish
Copy link
Author

Crash to desktop is what I meant. Sorry!

@Mrnofish
Copy link
Author

There you go:

FATAL EXCEPTION: main
Process: com.akylas.weather, PID: 13719
com.tns.NativeScriptException: Calling js method onBindViewHolder failed
Error: java.lang.IllegalStateException: Cannot call this method while RecyclerView is computing a layout or scrolling com.nativescript.collectionview.RecyclerView{cd6d7e8 VFEDHV... ......ID 3,3-1381,2669}, adapter:com.nativescript.collectionview.Adapter@5d6f532, layout:com.nativescript.collectionview.PreCachingGridLayoutManager@dc12ee7, context:com.akylas.weather.MainActivity@78051c3
	at com.tns.Runtime.callJSMethodNative(Native Method)
	at com.tns.Runtime.dispatchCallJSMethodNative(SourceFile:1)
	at com.tns.Runtime.callJSMethodImpl(Unknown Source:100)
	at com.tns.Runtime.callJSMethod(SourceFile:1)
	at com.tns.Runtime.callJSMethod(SourceFile:2)
	at com.tns.Runtime.callJSMethod(SourceFile:3)
	at com.tns.gen.com.nativescript.collectionview.AdapterInterface.onBindViewHolder(Unknown Source:12)
	at com.nativescript.collectionview.Adapter.onBindViewHolder(SourceFile:2)
	at com.nativescript.collectionview.Adapter.onBindViewHolder(SourceFile:1)
	at androidx.recyclerview.widget.RecyclerView$Adapter.bindViewHolder(SourceFile:166)
	at androidx.recyclerview.widget.RecyclerView$Recycler.u(SourceFile:70)
	at androidx.recyclerview.widget.RecyclerView$Recycler.v(SourceFile:85)
	at androidx.recyclerview.widget.RecyclerView$Recycler.i(SourceFile:6)
	at androidx.recyclerview.widget.GridLayoutManager.J(SourceFile:106)
	at androidx.recyclerview.widget.LinearLayoutManager.z(SourceFile:61)
	at androidx.recyclerview.widget.LinearLayoutManager.onLayoutChildren(Unknown Source:341)
	at androidx.recyclerview.widget.GridLayoutManager.onLayoutChildren(Unknown Source:9)
	at androidx.recyclerview.widget.RecyclerView.z(SourceFile:1)
	at androidx.recyclerview.widget.RecyclerView.x(SourceFile:70)
	at androidx.recyclerview.widget.RecyclerView.s(SourceFile:1)
	at e.t.run(SourceFile:293)
	at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1231)
	at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1239)
	at android.view.Choreographer.doCallbacks(Choreographer.java:899)
	at android.view.Choreographer.doFrame(Choreographer.java:827)
	at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:1214)
	at android.os.Handler.handleCallback(Handler.java:942)
	at android.os.Handler.dispatchMessage(Handler.java:99)
	at android.os.Looper.loopOnce(Looper.java:201)
	at android.os.Looper.loop(Looper.java:288)
	at android.app.ActivityThread.main(ActivityThread.java:7924)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:936)
Caused by: java.lang.IllegalStateException: Cannot call this method while RecyclerView is computing a layout or scrolling com.nativescript.collectionview.RecyclerView{cd6d7e8 VFEDHV... ......ID 3,3-1381,2669}, adapter:com.nativescript.collectionview.Adapter@5d6f532, layout:com.nativescript.collectionview.PreCachingGridLayoutManager@dc12ee7, context:com.akylas.weather.MainActivity@78051c3
	at androidx.recyclerview.widget.RecyclerView.j(SourceFile:22)
	at androidx.recyclerview.widget.h0.onChanged(SourceFile:4)
	at androidx.recyclerview.widget.a0.b(SourceFile:1)
	at androidx.recyclerview.widget.RecyclerView$Adapter.notifyDataSetChanged(Unknown Source:2)
	... 34 more

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants