Bug 537877 - Drawing problems in JDT Editor Breadcrums toolbar
Summary: Drawing problems in JDT Editor Breadcrums toolbar
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.9   Edit
Hardware: PC All
: P3 normal (vote)
Target Milestone: 4.9 RC1   Edit
Assignee: Gayan Perera CLA
QA Contact:
URL:
Whiteboard:
Keywords: needinfo
Depends on:
Blocks:
 
Reported: 2018-08-12 12:38 EDT by Gayan Perera CLA
Modified: 2018-08-30 01:13 EDT (History)
4 users (show)

See Also:
sarika.sinha: review+
Lars.Vogel: review+


Attachments
Breadcrumbs in Linux GTK3 (114.88 KB, image/png)
2018-08-12 12:38 EDT, Gayan Perera CLA
no flags Details
Breadcrumb windows (40.16 KB, image/png)
2018-08-12 12:41 EDT, Gayan Perera CLA
no flags Details
Screenshot under Ubuntu 18.04 (31.89 KB, image/png)
2018-08-17 07:11 EDT, Lars Vogel CLA
no flags Details
BreadcrumIssue.java (148 bytes, text/x-java)
2018-08-18 03:32 EDT, Gayan Perera CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gayan Perera CLA 2018-08-12 12:38:04 EDT
Created attachment 275357 [details]
Breadcrumbs in Linux GTK3

When selecting methods in inner classes the breadcrumb toolbar seems to have problem in drawing the inner class element with proper background and height.
Please see the screenshot for more details. This happens on both windows and linux.
Comment 1 Gayan Perera CLA 2018-08-12 12:41:53 EDT
Created attachment 275358 [details]
Breadcrumb windows
Comment 2 Dani Megert CLA 2018-08-13 04:28:06 EDT
Which build are you using?
Comment 3 Gayan Perera CLA 2018-08-13 11:08:06 EDT
Version : 2018-09 M2 (4.9.0M2)
Build ID: 20180809-1157
Comment 4 Dani Megert CLA 2018-08-13 11:14:07 EDT
Does it work when you use 4.8: http://download.eclipse.org/eclipse/downloads/drops4/R-4.8-201806110500/
Comment 5 Lars Vogel CLA 2018-08-17 07:11:49 EDT
Created attachment 275440 [details]
Screenshot under Ubuntu 18.04

Looks fine to me under Ubuntu 18.04. See screenshot.
Comment 6 Gayan Perera CLA 2018-08-17 13:00:13 EDT
(In reply to Lars Vogel from comment #5)
> Created attachment 275440 [details]
> Screenshot under Ubuntu 18.04
> 
> Looks fine to me under Ubuntu 18.04. See screenshot.

Try with a inner class method line in my screenshot. For me also a normal class scenario works. Even in the inner class when this happens open a dialog like launch configurations and close it, the breadcrumbs will be drawn correctly until you move to a different inner class method. Sorry i couldn't add this level of details in the original description.
Comment 7 Dani Megert CLA 2018-08-17 13:01:54 EDT
We need a detailed test case or steps to reproduce this.
Comment 8 Gayan Perera CLA 2018-08-18 03:32:37 EDT
Created attachment 275447 [details]
BreadcrumIssue.java
Comment 9 Gayan Perera CLA 2018-08-18 03:36:05 EDT
Steps to reproduce

1. Open eclipse workbench with a java project.
2. Make sure the "Toggle Breadcrumb" is off.
3. Open BreadcrumIssue.java in the java project
4. Now move the cursor to inside the method "eclipse.BreadcrumbIssue.CrumbListener.onChange()"
5. Now toggle the "Toggle Breadcrumb".
6. Now you should see something similar to "Breadcrumbs in Linux GTK3" attachment.
Comment 10 Gayan Perera CLA 2018-08-18 03:38:59 EDT
Another way to reprocude

1. Move the cursor to "eclipse.BreadcrumbIssue.foo()" in the "BreadcrumIssue.java" file.
2. Now toggle on the "Toggle Breadcrumb".
3. Now move the cursor to "eclipse.BreadcrumbIssue.CrumbListener.onChange()"
4. Now you should see something similar to "Breadcrumbs in Linux GTK3" attachment.
Comment 11 Matthias Becker CLA 2018-08-20 09:26:25 EDT
I had a look at the issue. I cannot find the cause of this. I assume that this issue existed before but was hidden by the gradient image that was drawn as background of the widgets in https://git.eclipse.org/r/#/c/46712/11/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/javaeditor/breadcrumb/BreadcrumbViewer.java

Can someone help here?
Comment 12 Gayan Perera CLA 2018-08-26 02:12:59 EDT
Can this be a CSS Styling issue ? I had seen this kind if behavior when certain elements are not styled properly when i was developing my own dark theme for eclipse.
Comment 13 Eclipse Genie CLA 2018-08-26 13:06:46 EDT
New Gerrit change created: https://git.eclipse.org/r/128087
Comment 14 Eclipse Genie CLA 2018-08-27 02:50:32 EDT
New Gerrit change created: https://git.eclipse.org/r/128104
Comment 15 Eclipse Genie CLA 2018-08-27 02:51:15 EDT
New Gerrit change created: https://git.eclipse.org/r/128105
Comment 16 Matthias Becker CLA 2018-08-27 02:57:31 EDT
(In reply to Eclipse Genie from comment #13)
> New Gerrit change created: https://git.eclipse.org/r/128087

Thank you Gayan. This is a good catch. I moved your changed into JDT's CSS file. As I am not a comitter of JDT i could not amend to your change - sorry.
Comment 17 Matthias Becker CLA 2018-08-27 02:58:13 EDT
(In reply to Eclipse Genie from comment #15)
> New Gerrit change created: https://git.eclipse.org/r/128105

I also made a corresponding change to the adapted copy of the breadcrumb in platform.debug.
Comment 18 Matthias Becker CLA 2018-08-27 03:13:23 EDT
can we pls. get these two fixes (JDT and Platform) into RC1?
Comment 20 Lars Vogel CLA 2018-08-27 03:20:27 EDT
Thanks, Gayan and Matthias. As I'm also not a JDT committer, I asked Sarika to review the JDT patch.
Comment 22 Sarika Sinha CLA 2018-08-27 06:26:33 EDT
Thanks Gayan and Matthias!!

+1 for RC1.
Comment 23 Lars Vogel CLA 2018-08-27 07:38:14 EDT
Approved for RC1
Comment 24 Sarika Sinha CLA 2018-08-30 01:13:09 EDT
Verified using
Eclipse SDK

Version: 2018-09 (4.9)
Build id: I20180829-2000