CLIM mail archive

[Prev][Next][Index][Thread]

Re: hitting return for "OK"/exit in AVV



   would like to have the return key
   be equivalent to clicking on the "OK" button

I would appreciate this, too.

   or do I have to write my own frame and tell it
   to use read-command-using-keystrokes and create commands with
   keystrokes that appear to correspond to various clicks.

I haven't been able to get Motif text-Fields in Accept Values Panes
to return from accept if the return key is pressed.

:additional-activation-gestures have no effect.

"Activating on return behavior" is expected by many users who are
familiar with Macintosh or Motif.

I guess that it can't be too difficult to implement this, as there's
already a gen. function being called at the right time.

(trace handle-event)

 0: (HANDLE-EVENT #<TK-SILICA:MOTIF-TEXT-FIELD @ #x1241d22>
                  #<CLIM-SILICA:ACTIVATE-GADGET-EVENT @ #x1269c7a>)
 0: returned NIL

So, what do I have to do?
Something like ...

  (defmethod handle-event ((tf tk-silica:motif-text-field)
			   (event clim-silica:activate-gadget-event))
   (throw-highlighted-presentation
     (make-instance 'standard-presentation
	...

... as in custom-gadget.lisp ????


If so, wouldn't it be easier to say  :activation-gestures '(:return) ?


Frank Buhr.





References:

Main Index | Thread Index