Bug 229294 - [Progress] Layout problems for items in DetailedProgressViewer
Summary: [Progress] Layout problems for items in DetailedProgressViewer
Status: VERIFIED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.4   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.6   Edit
Assignee: Prakash Rangaraj CLA
QA Contact: Prakash Rangaraj CLA
URL:
Whiteboard: hasPatch
Keywords: helpwanted
Depends on:
Blocks:
 
Reported: 2008-04-29 09:15 EDT by Min Idzelis CLA
Modified: 2009-11-01 14:32 EST (History)
2 users (show)

See Also:


Attachments
UI capture (39.77 KB, image/jpeg)
2008-04-29 09:52 EDT, Min Idzelis CLA
no flags Details
patch (37.94 KB, patch)
2008-05-05 09:57 EDT, Min Idzelis CLA
no flags Details | Diff
Patch v01 (2.95 KB, patch)
2009-09-08 05:23 EDT, Prakash Rangaraj CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Min Idzelis CLA 2008-04-29 09:15:33 EDT
Build ID: Eclipse 3.4M6a

Steps To Reproduce:
The items inside of DetailedProgressViewer use "FormLayout" to do it's layout. Because of that, there are some UI issues. 

I believe that "GridLayout" would be more appropriate. 

1) When an item doesn't have a ProgressIndicator, the label text flows into the ToolItem and overlaps it. 
2) I think it would look better if items without images would have their label text vertically aligned with the text of items with images. 
3) I think having the same height for all the items (those with indicator and without) would look better. Layout would also be faster to calculate. 

See attachments...
Comment 1 Min Idzelis CLA 2008-04-29 09:52:54 EDT
Created attachment 97975 [details]
UI capture
Comment 2 Min Idzelis CLA 2008-05-05 09:57:15 EDT
Created attachment 98634 [details]
patch

Reworked DetailedProgressViewer and ProgressInfoItem to use GridLayout. Flicker was also removed by using setRedraw() on the controls when doing multiple updates at a time. A Resize listener was added that will re-layout the label text (and shorten it) when resize events occur.
Comment 3 Min Idzelis CLA 2008-11-17 10:26:28 EST
Any chance on accepting this patch for 3.5? 
Comment 4 Boris Bokowski CLA 2009-06-09 09:14:49 EDT
This bug has an attached patch.
Comment 5 Prakash Rangaraj CLA 2009-06-10 13:06:17 EDT
Sorry. Its too late for 3.5 I'll look into 3.6
Comment 6 Prakash Rangaraj CLA 2009-07-21 04:20:46 EDT
(In reply to comment #3)
> Any chance on accepting this patch for 3.5? 
> 

Min,
    The patch is little outdated. It would be great if you could respin the patch for the latest code.
Comment 7 Min Idzelis CLA 2009-07-21 09:31:37 EDT
Sure. I'll try to get to it when I can. BTW, I have plans for reworking the viewer even more extensively. Right now, when new jobs pop up that are sorted ahead of existing Jobs, the progress bar widget is disposed and recreated in the new spot. This leads to flickr, and loss of the progress position for "unknown" progress monitors. Better would be to have a model of each individual progress. Instead of destroying/recreating the status widgets, a widget could just "adapt" to the model that tracks the progress. 
Comment 8 Prakash Rangaraj CLA 2009-09-08 05:23:23 EDT
Created attachment 146644 [details]
Patch v01

(In reply to comment #0)
> The items inside of DetailedProgressViewer use "FormLayout" to do it's layout.
> Because of that, there are some UI issues. 
> 
> I believe that "GridLayout" would be more appropriate. 
> 
> 1) When an item doesn't have a ProgressIndicator, the label text flows into the
> ToolItem and overlaps it. 
> 2) I think it would look better if items without images would have their label
> text vertically aligned with the text of items with images. 
> 3) I think having the same height for all the items (those with indicator and
> without) would look better. Layout would also be faster to calculate. 

 I tried to look into this. It seems like FormLayout is more appropriate than GridLayout.

 1) The patch fixes it
 2) That would look nice if all the jobs have 16x16 icons. But there is no constraint on the image size and the user is allowed to have any sized icon. In this case, it would not look nice, if all the progress bars are aligned to the biggest icon in the view
 3) Height of the items cannot be same for the same reason above

The attached patch additionally center aligns the job image vertically
Comment 9 Prakash Rangaraj CLA 2009-09-10 04:53:41 EDT
Patch v01 released to HEAD
Comment 10 Markus Keller CLA 2009-09-11 13:20:42 EDT
(In reply to comment #0)
> 2) I think it would look better if items without images would have their label
> text vertically aligned with the text of items with images. 

I filed bug 289239 for another way to fix this.
Comment 11 Prakash Rangaraj CLA 2009-09-15 04:51:50 EDT
Verified in I20090914-1800
Comment 12 Min Idzelis CLA 2009-11-01 14:32:35 EST
There are still some issues. Instead of re-opening this bug, I've created bug 293877.