Help with WIDGET_TEXT (non-) events [message #5758] |
Thu, 15 February 1996 00:00  |
zawodny
Messages: 121 Registered: August 1992
|
Senior Member |
|
|
Hello,
I have an application where I am currently using a non-editable
text widget to display a variable length list. The text widget has a
YSIZE of 1 and SCROLL set. This way only one item (the "current" item)
is displayed and the user can change the "current" item using the
vertical scroll bar. My problem is this: the non-editable text widget
generates no events. Setting the TRACKING keyword to WIDGET_TEXT
generates WIDGET_TRACKING events only when the cursor enters actual
text field (ie. manipulating the contents of the viewport using the
scroll bar does not generate a WIDGET_TRACKING event). In short, I
cannot tell when the user has changed the "current" item. In theory I
could use some combination of:
WIDGET_INFO,/TEXT_TOP_LINE
WIDGET_CONTROL,/SET_TEXT_TOP_LINE or
WIDGET_CONTROL,SET_TEXT_SELECT=
as part of the event processing for some of my other widgets that care
about the "current" item but, this would be an incredible pain to
implement in my case.
Have any ideas on how to get around this? I guess I could resort to
a WIDGET_TIMER but, a lot can happen in one second and I could easily
lose content or user input. I cannot, nor should I, expect the user
to intuitively use the scroll bar and then click on the text viewport
to make that list element current.
What I would love to have is a WIDGET_TEXT event (type = 4 ?) that tells
me that the user had moved the text field using the scroll bar(s).
(Hint, hint, hint RSI how about doing this for IDL V 5.0?) Although
my need for this is immediate.
TIA for your ideas.
--
Dr. Joseph M. Zawodny KO4LW NASA Langley Research Center
E-mail: J.M.Zawodny@LaRC.NASA.gov MS-475, Hampton VA, 23681-0001
|
|
|