Community
Participate
Working Groups
Created attachment 276930 [details] Video showing mouse navigation I've worked on a little enhancement for StyledText widgets. It mimics the behaviour of Firefox or Chrome when you click on the wheel button: a circle with arrows appears and you can navigate through the whole document by moving you mouse. (please see encloding video) Maybe this proposal may be integrated in standard with StyledText ? I'll send a patch once the code will be cleaned.
(In reply to Laurent CARON from comment #0) > I'll send a patch once the code will be cleaned. Please provide the work in a Gerrit change.
Sure. Is it necessary to use Gerrit or can I make a PR on https://github.com/eclipse/eclipse.platform.swt ?
(In reply to Laurent CARON from comment #2) > Sure. Is it necessary to use Gerrit or can I make a PR on > https://github.com/eclipse/eclipse.platform.swt ? We currently use Gerrit. If you have questions / issues with Gerrit, please feel free to ask (Lars.Vogel@vogella.com).
Thank you Lars, I'll use gerrit.
Question: we agree that this behaviour will not be activated by default. To activate this, I have 2 solutions : a) create a method to activate/deactivate, for example setMouseNavigationEnabled(boolean) b) Use a SWT bit flag in constructor. In this case, which one ? What's your opinion ?
(In reply to Laurent CARON from comment #5) > Question: we agree that this behaviour will not be activated by default. > > To activate this, I have 2 solutions : > > a) create a method to activate/deactivate, for example > setMouseNavigationEnabled(boolean) > > b) Use a SWT bit flag in constructor. In this case, which one ? > > What's your opinion ? Definitely a) because that allows to change the behavior for already opened/created StyledText which is not possible via style constant.
New Gerrit change created: https://git.eclipse.org/r/134437
Gerrit change https://git.eclipse.org/r/134437 was merged to [master]. Commit: http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/?id=2315f3403bf77d0f911eac74a4851fbc19cde824
New Gerrit change created: https://git.eclipse.org/r/136956
Gerrit change https://git.eclipse.org/r/136956 was merged to [master]. Commit: http://git.eclipse.org/c/www.eclipse.org/eclipse/news.git/commit/?id=df14ba1beee6c6537b1171bc103b29c234ab657c
(In reply to Eclipse Genie from comment #8) > Gerrit change https://git.eclipse.org/r/134437 was merged to [master]. > Commit: > http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/ > ?id=2315f3403bf77d0f911eac74a4851fbc19cde824 In master now, thanks for the patch and contribution Laurent! (In reply to Eclipse Genie from comment #10) > Gerrit change https://git.eclipse.org/r/136956 was merged to [master]. > Commit: > http://git.eclipse.org/c/www.eclipse.org/eclipse/news.git/commit/ > ?id=df14ba1beee6c6537b1171bc103b29c234ab657c Merged the N&N entry for 4.11.
New Gerrit change created: https://git.eclipse.org/r/137016
Gerrit change https://git.eclipse.org/r/137016 was merged to [master]. Commit: http://git.eclipse.org/c/www.eclipse.org/eclipse/news.git/commit/?id=89b17a7cdd89c4077ef360e0932ce024146ead62
Verified in I20190219-0600.
This is definitely good enhancement. In my testing using TextEditor example from swt examples package, I noticed some issues 1. In 4 way navigation, the circle of arrows is jumping to different locations when the mouse moved. This does not happen in 2 way mode. Specifically when I try to move in diagonal 2. When we move the mouse away from the navigation circle the widget scrolls as long as mouse moves. but stops once we leave mouse. this is different from chrome or firefox behavior. In the browsers the browser pane keeps moving till the end and the scroll speed is proportional to the distance from navigation circle. But this can be considered as another enhancement. This is not required for 4.11 I my opinion the first problem also doesn't warrant removal from 4.11. But that will stop us from enabling this feature by default. Test environment OS: Ubuntu 18.04 Gnome on X11 Eclipse SDK Version: 2019-03 (4.11) Build id: I20190218-1800 OS: Linux, v.4.15.0-45-generic, x86_64 / gtk 3.22.30 Java version: 11.0.2
(In reply to Sravan Kumar Lakkimsetti from comment #15) > This is definitely good enhancement. In my testing using TextEditor example > from swt examples package, I noticed some issues > > 1. In 4 way navigation, the circle of arrows is jumping to different > locations when the mouse moved. This does not happen in 2 way mode. > Specifically when I try to move in diagonal I don't see this problem on Windows7. > 2. When we move the mouse away from the navigation circle the widget scrolls > as long as mouse moves. but stops once we leave mouse. this is different > from chrome or firefox behavior. In the browsers the browser pane keeps > moving till the end and the scroll speed is proportional to the distance > from navigation circle. But this can be considered as another enhancement. > This is not required for 4.11 Can notice the same on Windows too, but agree that i can be improved later on.
Raised bug 544616 to provide a new preference option to enable/disable Mouse navigation from Eclipse UI.
(In reply to Niraj Modi from comment #16) > (In reply to Sravan Kumar Lakkimsetti from comment #15) > > This is definitely good enhancement. In my testing using TextEditor example > > from swt examples package, I noticed some issues > > > > 1. In 4 way navigation, the circle of arrows is jumping to different > > locations when the mouse moved. This does not happen in 2 way mode. > > Specifically when I try to move in diagonal > I don't see this problem on Windows7. I don't see this problem on Mac either.
New Gerrit change created: https://git.eclipse.org/r/137264
(In reply to Eclipse Genie from comment #19) > New Gerrit change created: https://git.eclipse.org/r/137264 With above gerrit, updated CustomControlExample's StyledText tab for the Mouse Navigator option.
(In reply to Sravan Kumar Lakkimsetti from comment #15) > This is definitely good enhancement. In my testing using TextEditor example > from swt examples package, I noticed some issues > > 1. In 4 way navigation, the circle of arrows is jumping to different > locations when the mouse moved. This does not happen in 2 way mode. > Specifically when I try to move in diagonal > @Eric, do you see this problem?
(In reply to Lakshmi Shanmugam from comment #21) > (In reply to Sravan Kumar Lakkimsetti from comment #15) > > This is definitely good enhancement. In my testing using TextEditor example > > from swt examples package, I noticed some issues > > > > 1. In 4 way navigation, the circle of arrows is jumping to different > > locations when the mouse moved. This does not happen in 2 way mode. > > Specifically when I try to move in diagonal > > > @Eric, do you see this problem? Nope, I just tried Snippet375 and I don't see it at all. No jumping regardless of which direction I move in (for 4-way mode).
(In reply to Eric Williams from comment #22) > (In reply to Lakshmi Shanmugam from comment #21) > > (In reply to Sravan Kumar Lakkimsetti from comment #15) > > > This is definitely good enhancement. In my testing using TextEditor example > > > from swt examples package, I noticed some issues > > > > > > 1. In 4 way navigation, the circle of arrows is jumping to different > > > locations when the mouse moved. This does not happen in 2 way mode. > > > Specifically when I try to move in diagonal > > > > > @Eric, do you see this problem? > > Nope, I just tried Snippet375 and I don't see it at all. No jumping > regardless of which direction I move in (for 4-way mode). I see this problem even on snippet375 but it is quite difficult to reproduce (you don't have much space to move diagonally). I can see this problem even on Fedora 29 Eclipse SDK Version: 2019-03 (4.11) Build id: I20190220-1800 OS: Linux, v.4.20.7-200.fc29.x86_64, x86_64 / gtk 3.24.1, WebKit 2.22.5 Java version: 1.8.0_201 The snippet I am using is https://git.eclipse.org/c/platform/eclipse.platform.swt.git/tree/examples/org.eclipse.swt.examples/src/org/eclipse/swt/examples/texteditor with the styledText.setMouseNavigatorEnabled(true); added to TextEditor.open() method.
Created attachment 277639 [details] Video showing the problem noticed on Linux
Thank you for the detailled bug report. I'm gonna install a VM with Ubuntu/GTK/Java 8 and I'll come back to you. Laurent
Moving to RC1.
(In reply to Sravan Kumar Lakkimsetti from comment #23) > (In reply to Eric Williams from comment #22) > > (In reply to Lakshmi Shanmugam from comment #21) > > > (In reply to Sravan Kumar Lakkimsetti from comment #15) > > > > This is definitely good enhancement. In my testing using TextEditor example > > > > from swt examples package, I noticed some issues > > > > > > > > 1. In 4 way navigation, the circle of arrows is jumping to different > > > > locations when the mouse moved. This does not happen in 2 way mode. > > > > Specifically when I try to move in diagonal > > > > > > > @Eric, do you see this problem? > > > > Nope, I just tried Snippet375 and I don't see it at all. No jumping > > regardless of which direction I move in (for 4-way mode). > > I see this problem even on snippet375 but it is quite difficult to reproduce > (you don't have much space to move diagonally). > > I can see this problem even on Fedora 29 > Eclipse SDK > Version: 2019-03 (4.11) > Build id: I20190220-1800 > OS: Linux, v.4.20.7-200.fc29.x86_64, x86_64 / gtk 3.24.1, WebKit 2.22.5 > Java version: 1.8.0_201 > > The snippet I am using is > https://git.eclipse.org/c/platform/eclipse.platform.swt.git/tree/examples/ > org.eclipse.swt.examples/src/org/eclipse/swt/examples/texteditor with the > styledText.setMouseNavigatorEnabled(true); added to TextEditor.open() method. X11 or Wayland? I tried as you have described and still don't see it, but this is Wayland.
(In reply to Eric Williams from comment #27) > (In reply to Sravan Kumar Lakkimsetti from comment #23) > > (In reply to Eric Williams from comment #22) > > > (In reply to Lakshmi Shanmugam from comment #21) > > > > (In reply to Sravan Kumar Lakkimsetti from comment #15) > > > > > This is definitely good enhancement. In my testing using TextEditor example > > > > > from swt examples package, I noticed some issues > > > > > > > > > > 1. In 4 way navigation, the circle of arrows is jumping to different > > > > > locations when the mouse moved. This does not happen in 2 way mode. > > > > > Specifically when I try to move in diagonal > > > > > > > > > @Eric, do you see this problem? > > > > > > Nope, I just tried Snippet375 and I don't see it at all. No jumping > > > regardless of which direction I move in (for 4-way mode). > > > > I see this problem even on snippet375 but it is quite difficult to reproduce > > (you don't have much space to move diagonally). > > > > I can see this problem even on Fedora 29 > > Eclipse SDK > > Version: 2019-03 (4.11) > > Build id: I20190220-1800 > > OS: Linux, v.4.20.7-200.fc29.x86_64, x86_64 / gtk 3.24.1, WebKit 2.22.5 > > Java version: 1.8.0_201 > > > > The snippet I am using is > > https://git.eclipse.org/c/platform/eclipse.platform.swt.git/tree/examples/ > > org.eclipse.swt.examples/src/org/eclipse/swt/examples/texteditor with the > > styledText.setMouseNavigatorEnabled(true); added to TextEditor.open() method. > > X11 or Wayland? I tried as you have described and still don't see it, but > this is Wayland. Okay it happens only on X11, Wayland seems unaffected.
(In reply to Laurent CARON from comment #25) > Thank you for the detailled bug report. > I'm gonna install a VM with Ubuntu/GTK/Java 8 and I'll come back to you. > > Laurent @Laurent, Were you able to take a look at the problem?
Hi Lakshmi, I've just installed my VM, I'll have a look tomorrow (thursday) Laurent
New Gerrit change created: https://git.eclipse.org/r/137922
New Gerrit change created: https://git.eclipse.org/r/137923
I finally found the problem on GTK/X11. The methods that check if the scrollbars are present where very slow. I've fixed it and checked on Windows 10 and Ubuntu/Gnome (X11 and Wayland) Have a look at https://git.eclipse.org/r/c/137923/
(In reply to Eclipse Genie from comment #31) > New Gerrit change created: https://git.eclipse.org/r/137922 Mad mishandling, sorry
(In reply to Laurent CARON from comment #33) > I finally found the problem on GTK/X11. The methods that check if the > scrollbars are present where very slow. > > I've fixed it and checked on Windows 10 and Ubuntu/Gnome (X11 and Wayland) > > Have a look at https://git.eclipse.org/r/c/137923/ @Laurent, thanks for the fix! I think we can consider it for RC2 as it would fix a bug in the new API and also the changes are only in the newly added MouseNavigator class. @Eric, @Sravan, I don't have a mouse to verify this now, can you please review & verify the patch for RC2?
Created attachment 277742 [details] Video showing the problem The patch is huge improvement. But there is still some issue. It is quite difficult to reproduce now. My recommendation would be we should consider this problem as resolved now and target the remaining issues to the future releases
(In reply to Sravan Kumar Lakkimsetti from comment #36) > Created attachment 277742 [details] > Video showing the problem > > The patch is huge improvement. But there is still some issue. It is quite > difficult to reproduce now. > > My recommendation would be we should consider this problem as resolved now > and target the remaining issues to the future releases I +2'd the patch on Gerrit, it looks fine on my end. However I do notice that the pasting issue is back. The patch to fix the icon hopping hasn't introduced it, but it is still there. To see what I am talking about, look at Sravan's video. Notice how when the middle click button is first pressed, there is text pasted from the clipboard. This was fixed when I reviewed the initial patch with the API contribution, but somehow it's managed to sneak back in somewhere. My proposal: since this issue only affects Linux I am fine with merging this for RC2, provided that we address the pasting issue early in 4.12.
Gerrit change https://git.eclipse.org/r/137923 was merged to [master]. Commit: http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/?id=475e9b71d92003d28684f62e8842ef006ccf85b9
@Eric, @Sravan, Thanks for the reviews, I've merged the patch. Please open bugs for the respective issues you have found, so that we can close this bug.
(In reply to Lakshmi Shanmugam from comment #39) > @Eric, @Sravan, > Thanks for the reviews, I've merged the patch. > Please open bugs for the respective issues you have found, so that we can > close this bug. I've opened bug 545073 for the clipboard pasting issue and Sravan has opened bug 545041 for the icon hopping.