nkh / P5-App-Asciio

Plain ASCII diagram
https://nkh.github.io/P5-App-Asciio/
51 stars 4 forks source link

The shape of the mouse is weird after the clone mode ends #164

Closed qindapao closed 7 months ago

qindapao commented 7 months ago

mouse_error

I tested this phenomenon on cygwin and wsl linux.The mouse pointer becomes tilted after the clone mode ends.

nkh commented 7 months ago

@qindapao what branch are you in?

qindapao commented 7 months ago

@nkh My computer is off, I can't remember which branch it is in. I'll confirm it tomorrow night.

qindapao commented 7 months ago

@nkh I am running on the latest main branch

nkh commented 7 months ago

The cursors is hidden in clone mode; it's shown again when exiting clone mode.

I reset the cursor to "arrow" and it looks the same on my box. it seems that "arrow" is not the same as the default arrow in your environment.

I have no idea why right now.

https://github.com/nkh/P5-App-Asciio/blob/a2f3335c0345243d64af630fa496e26094543fcd/lib/App/Asciio/GTK/Asciio.pm#L34-L57

qindapao commented 7 months ago

@nkh It's not a big problem, it doesn't affect other functions, it's just visual. Might be a problem with my local settings.Do we need to track this?

nkh commented 7 months ago

@qindapao Yes we do.

It may work on my machine because I have setup my cursor theme but it should work for everybody.

Here's the list of GTK cursors:

https://docs.gtk.org/gdk3/enum.CursorType.html

as you can see 'arrow' is the cursor you are getting, it may need to be changed to "left_ptr" or "top_left_ptr#, can you please test that?

qindapao commented 7 months ago

@nkh I can, but this priority is lowered, I am doing zbuffer integration.

qindapao commented 7 months ago

@nkh

https://github.com/qindapao/P5-App-Asciio/tree/fix_mouse_shape

I cached the mouse pointer type, and then used the cached pointer type when restoring. The current test is OK in my environment. Please check if your environment can work normally.

fix_cursor

nkh commented 7 months ago

@qindapao works fine for me, I've merged it here 74b1c1f

Did you try to change "arrow" to "left_ptr"? please try it, without caching, as I can't try in my environment (it works here because I have a mouse theme I think)

qindapao commented 7 months ago

@qindapao works fine for me, I've merged it here 74b1c1f

Did you try to change "arrow" to "left_ptr"? please try it, without caching, as I can't try in my environment (it works here because I have a mouse theme I think)

@nkh I did the test as you said and it works fine.This time my mouse pointer showed no abnormalities.

image

nkh commented 7 months ago

@nkh I removed the cached cursor and use 'left_ptr' instead.