Community
Participate
Working Groups
Using I20050803-0800, sometimes the icon disappears when I select a problem in the problem view. If it is unselected, it works fine. See attached screenshot.
Created attachment 25682 [details] Screenshot
This happens because/when the table column is not wide enough for both the icon and the indentation (trim). Increasing the value of COLUMN_TRIM in the JFace TableLayout class to 4px for the Win32 platform should fix the problem. That's not to say the SWT people won't find a way to prevent clipped images from disappearing entirely when selected.
It's a well known, long standing bug in Windows. Looking for the dup ...
Can't find it. Sorry, WONTFIX (CANTFIX).
How about moving this bug to Platform/UI so they can consider fixing the problem at the JFace level (see comment #2)?
Go ahead.
This worked in the past. I got it regularly with recent builds.
You sure about that? It's been a Windows problem for a while. Could be a recent change in either SWT or JFace.
No idea, but I don't remember getting it regularly with older builds.
(In reply to comment #8) > Could be a recent change in either SWT or JFace. After some testing, I'd say it's not. I've modified one of the table snippets to test this issue and was able to reproduce the problem with SWT versions as old as v2136 (didn't check any earlier ones). Moreover, the way the JFace TableLayout class calculates the column width did indeed change (see bug 90712) but the actual width of the icon column did not. I have, however, found that the icon will only disappear if you have the javaw.exe manifest file installed. Olivier, did you recently change your JVM installation from one without manifest to one with a manifest? If so, this would explain why you suddenly see this bug. The root problem still is that the icon is clipped. This shouldn't happen in the first place. The icon itself is 16px wide and Windows adds another 4px of indentation (apparently only 2px when running without the manifest). This adds up to 20px but the column is only 19px wide, hence the clipping. The fix, as mentioned earlier, would be to increase the value of TableLayout.COLUMN_TRIM to 4px for the Win32 platform, or to provide a way to directly query the correct value from SWT (if that's possible).
Created attachment 26611 [details] Screenshot (comparison) Without manifest, column width=19 vs. with manifest, column width=19 vs. with manifest, column width=20 (A border has been added to the icon to make its bounds clearer.)
(In reply to comment #10) > I have, however, found that the icon will only disappear if you have the > javaw.exe manifest file installed. Olivier, did you recently change your > JVM installation from one without manifest to one with a manifest? > If so, this would explain why you suddenly see this bug. Yes, before I didn't use a manifest, but I had to install it for the screenshots for the 3.1 release. Would this problem go away if I get rid of the manifest?
(In reply to comment #12) > Would this problem go away if I get rid of the manifest? Yes.
Created attachment 26689 [details] Patch (This patch assumes that the current trim values for the non-Win32 platforms are indeed correct.)
I confirm that this patch is fixing the problem on Windows XP with the manifest.
It also looks good when no manifest is used.
*** Bug 144451 has been marked as a duplicate of this bug. ***
Is this still a problem in 3.3?
No, this is fine in latest build. I don't remember exactly when this was fixed.
Closing.
The underlying problem has never been fixed. TableLayout still uses a trim value that's too small. The icons in the Problems view no longer disappear because the view has been changed to use the tree widget.
Thanks, Florian. Sorry for not taking the patch earlier.
Moving to M3.
Thanks for the patch!
Fix released to HEAD.
Hm, you fixed the old layout but leave the new layouts (AbstractColumnLayout) who also suffer from this very problem :-) Should I log a new bug?
yes, please :-)
Filed as bug 208014
Verified using I20071030-0010 (by code inspection).