Home Download Buy Blog Forum Support

Mini-map clicks going to wrong location in file?

Re: Mini-map clicks going to wrong location in file?

Postby alexrussell on Sat Mar 17, 2012 12:11 am

adzenith wrote:There's a userecho feature request that I think would solve a lot of problems

Oh yeah, that's genius. Hadn't even thought of that! Fixes everything really. Still technically a broken UX when you first hover and the minimap jumps a little, but that's a tiny price to pay for the benefit of all other perfectly-working UX.

Definite upvote from me.
alexrussell
 
Posts: 74
Joined: Fri Jul 15, 2011 9:06 am

Re: Mini-map clicks going to wrong location in file?

Postby cviebrock on Thu Apr 05, 2012 3:35 pm

I'd love to see this feature as well. Second choice would be squishing the whole mini-map to fit vertically in the available area.
- Colin
cviebrock
 
Posts: 14
Joined: Wed Nov 02, 2011 5:47 pm

Re: Mini-map clicks going to wrong location in file?

Postby WarttHog on Mon Jul 09, 2012 10:39 pm

Correct me if I'm wrong, but isn't this the root problem: that when the user presses the mouse button down, you don't yet know if they're clicking or dragging? I don't know about other OS's but the Windows way of handling mouse messages is this for click events to be fired on mouse-up and drag-start events are fired when the mouse has moved n pixels from the original mouse-down pixel (where n==2 usually -- the area marked by this radius is called "the slop").

If you do this, a click could move the viewport to the code the user actually clicked on. Yes, the highlight may not be under the mouse anymore, but the user likely won't care. If they're dragging, you should scroll based on delta-y instead of abs(y) like you do currently if the user drags the highlight.

Here are a couple of other UX tweaks that might help:

1) Invert the drag operation so that instead of dragging the highlight, you instead drag the code beneath the highlight; i.e. moving the mouse towards the bottom of the screen moves the viewport towards the top of the code. Currently the user drags the highlight, so dragging outside of the highlight doesn't really make sense and that's part of the problem we're running into. If instead the user drags the code map then it's easier to reason about what the right thing to do is.

2) Animation would help. Instead of snapping to something, giving a 250ms, ease-out animation would make it much easier for the user to figure out what just happened.
WarttHog
 
Posts: 5
Joined: Mon Jul 09, 2012 9:35 pm

Re: Mini-map clicks going to wrong location in file?

Postby awolf on Thu Jul 26, 2012 8:31 pm

The current behavior in Sublime Text 2 is definitely broken. The point of the minimap is to find your place in longer files. If I look at the minimap and see where I want to go, clicking that place should take me there. Period.

I understand this means that after clicking my pointer would not be pointing at the text I clicked. That's actually preferable: clicking again would then jump me further in the file. I could use that mechanism to quickly scroll in large files.

Please fix this!
awolf
 
Posts: 1
Joined: Thu Jul 26, 2012 8:26 pm

Re: Mini-map clicks going to wrong location in file?

Postby bubersson on Mon Nov 12, 2012 10:32 pm

+1 for fixing this one. On mouse-up (and without any drag) it should jump directly at that line - this should be easy pixel / lines calculation, right?
bubersson
 
Posts: 1
Joined: Mon Oct 29, 2012 7:30 pm

Re: Mini-map clicks going to wrong location in file?

Postby bizoo on Tue Nov 13, 2012 7:56 am

bubersson wrote:+1 for fixing this one. On mouse-up (and without any drag) it should jump directly at that line - this should be easy pixel / lines calculation, right?

Build 2220
Improved minimap click behavior. The old behavior is available via the minimap_scroll_to_clicked_text setting

Upgrade to the last Dev Build.
bizoo
 
Posts: 859
Joined: Wed Dec 08, 2010 6:53 am
Location: Switzerland

Previous

Return to Technical Support

Who is online

Users browsing this forum: Yahoo [Bot] and 17 guests