Community
Participate
Working Groups
Build Identifier: M20100211-1343 When the onPaint() method delegate the rendering of the cell to the cellRenderer of the current column, the column index is not propagated to the cell renderer. In my opinion the call "column.getCellRenderer().setColumn(indexOf(column))" is missing around line 5496 in Class org.eclipse.nebula.widgets.grid.Grid. I have implemented a GridCellRenderer, but with this bug I'm not able to get the right "column context" inside the paint(GC,Object) method. Reproducible: Always
If you attach a patch I can apply it ASAP
Created attachment 170809 [details] Proposed patch for org.eclipse.nebula.widgets.grid.Grid
Created attachment 170948 [details] Proposed patch with new fixes I found two more calls to getCellRenderer() where the column index was not propagated. Changes in: Grid.onPaint() -> old Grid.computeItemHeight() -> new GridColumn.pack() -> new
Looks good, one minor thing - I think we should store the content of indexOf(column) call in an local variable
Created attachment 170951 [details] Proposed patch with new fixes Ok, there was already a local variable with the index of the column. I replaced the method calls in the new patch.
Applied patch with attribution to CVS-HEAD