From: Tech Id on
Yes, the code is copied from the snippets site.
The original code only makes a cell (at column 1) span 2 columns for
Table widget and it works well for Tree Widget too.

But I want cell at column 0 to span all the columns.
That's why the above code.

Above actually works but there is some tiny-miny bug that messes up
the string starting and ending :(
I was hoping to get help with that.
From: Tech Id on
No one could get the bug here?
From: Jeff Higgins on
On 7/9/2010 2:35 AM, Tech Id wrote:
> No one could get the bug here?
It looks like you are drawing the string twice, once in column0 and
again in column1. I don't have the time to investigate the API but you
might want to check Event.index() and how it relates to your
multi-column Tree widget. There is a group discussion focused on the SWT
API located at:
<http://www.eclipse.org/forums/eclipse.platform.swt>
From: Tech Id on
On Jul 9, 6:38 pm, Jeff Higgins <oohigg...(a)yahoo.com> wrote:
> On 7/9/2010 2:35 AM, Tech Id wrote:> No one could get the bug here?
>
> It looks like you are drawing the string twice, once in column0 and
> again in column1. I don't have the time to investigate the API but you
> might want to check Event.index() and how it relates to your
> multi-column Tree widget. There is a group discussion focused on the SWT
> API located at:
> <http://www.eclipse.org/forums/eclipse.platform.swt>

The drawing has to be done twice I guess.
This is so because a cell only draws that much amount as can be fit
inside it.
So for cell0, we draw from the beginning of text and the cell and it
displays till column width.
For cell1, we draw text from the beginning too but from cell.start-
column0.width. This makes sure we draw it right for both the cells.
And this is also the way it has been drawn in the original SWT example
but its done for Table widget and for 2nd and 3rd column. And it works
there :( but not here :( :(
First  |  Prev  | 
Pages: 1 2
Prev: Struts - Lazy Validator Form
Next: Java and awk (jawk)