Re: WIDGET_TABLE and /ALL_EVENTS [message #90516 is a reply to message #90510] |
Fri, 06 March 2015 01:56  |
lecacheux.alain
Messages: 325 Registered: January 2008
|
Senior Member |
|
|
On Thursday, March 5, 2015 at 7:42:37 PM UTC+1, wlandsman wrote:
> I am creating a table using WIDGET_TABLE(). All I want to know is which cell the user selected.
>
> WIDGET_TABLE() has several keywords specifying which events will be captured.
>
> /ALL_EVENTS
> /CONTEXT_EVENTS
> /KBRD_FOCUS_EVENTS
> /TRACKING_EVENTS
>
> The documentation for /ALL_EVENTS says "Set this keyword to cause the table widget to generate events whenever the user changes the contents of a table cell."
>
> Here are my quibbles:
>
> 1. The name of the /ALL_EVENTS keyword is misleading since it doesn't include all events -- i.e. it doesn't include context events or keyboard focus events or tracking events.
>
> 2. The documentation is misleading because I need to use /ALL_EVENTS just to learn which cell the user selected -- even though I don't want the user to be able to change the content of a table cell.
>
> So right now I use /ALL_EVENTS and ignore any event unless the TYPE keyword in the returned event structure has a value of 4 (indicating cell selection) and I ignore all eight other possible values of TYPE. This works but is there any way to specify that I don't want the user to be able to modify the cell contents? Thanks, --Wayne
Maybe by using the EDITABLE keyword ?
alx.
|
|
|