In my (limited) experience, you could catch the mouse events... e.g.
@table.connect( SEL_LEFTBUTTONPRESS, method( :onDown ) )
@table.connect( SEL_LEFTBUTTONRELEASE, method( :onUp ) )
and then create the methods onDown and onUp. Capture the x/y location
on each method,
def onDown( sender, sel, event )
x = event.win_x
y = event.win_y
# What row and column was clicked.
row = @table.rowAtY( y )
col = @table.colAtX( x )
...
end
There is probably a better way to do it, but I'm just a beginner with
FXRuby I'm afraid...
On Wed, 26 May 2004 13:43:55 +0200, Fredrik Jagenheim <fr...@po...> wrote:
>
> Hi,
>
> I'm currently using anchor[Row|Column] and current[Row|Column] to see
> which cells are selected in a FXTable, but that only works when the
> cells are selected using 'Shift+cursor' selection. When selecting
> using the mouse I get that the anchor == current.
>
> Am I missing something obvious, or doing it the wrong way?
>
> Thanks,
> //F
>
> -------------------------------------------------------
> This SF.Net email is sponsored by: Oracle 10g
> Get certified on the hottest thing ever to hit the market... Oracle 10g.
> Take an Oracle 10g class now, and we'll give you the exam FREE.
> http://ads.osdn.com/?ad_id=3149&alloc_id=8166&op=click
> _______________________________________________
> Fxruby-users mailing list
> Fxr...@li...
> https://lists.sourceforge.net/lists/listinfo/fxruby-users
>
|