You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the normal course of operations I would like to be able to make a selection in the datagrid, and then have some action be taken as a result through an event handler (such as go query/load/compute data based on the selection, and then reflect that in some form of output). However, sometimes, I as the user might overshoot my intended selection, and drag my mouse back to my intended selection area. Or, I may simply click and drag from one cell to another.
When the DataGrid is registered to an ipywidgets event handler using DataGrid.observe(myFunct,names='selections'), this will trigger multiple times as the mouse is dragged throughout the grid, as the selection is changing each time. That therefore triggers the event handler multiple times, which depending on the action that needs to be taken, could be costly.
What would be ideal would be the addition of support for the continuous_update keyword that many other ipywidgets accept, whereby if the keyword is False (default is True), an event will only be triggered when the user has indicated that input is completed, such as by hitting Enter, moving the focus away from the widget, or lifting the mouse button (which would be the ideal criterion for this scenario).
In the meantime the workaround is to not register any event handlers to the datagrid itself, and instead create a button that the user must click to have their selection recognized. This however is clunky, and adds an additional step to the user's UI experience.
The text was updated successfully, but these errors were encountered:
In the normal course of operations I would like to be able to make a selection in the datagrid, and then have some action be taken as a result through an event handler (such as go query/load/compute data based on the selection, and then reflect that in some form of output). However, sometimes, I as the user might overshoot my intended selection, and drag my mouse back to my intended selection area. Or, I may simply click and drag from one cell to another.
When the DataGrid is registered to an ipywidgets event handler using
DataGrid.observe(myFunct,names='selections')
, this will trigger multiple times as the mouse is dragged throughout the grid, as the selection is changing each time. That therefore triggers the event handler multiple times, which depending on the action that needs to be taken, could be costly.What would be ideal would be the addition of support for the
continuous_update
keyword that many other ipywidgets accept, whereby if the keyword is False (default is True), an event will only be triggered when the user has indicated that input is completed, such as by hitting Enter, moving the focus away from the widget, or lifting the mouse button (which would be the ideal criterion for this scenario).In the meantime the workaround is to not register any event handlers to the datagrid itself, and instead create a button that the user must click to have their selection recognized. This however is clunky, and adds an additional step to the user's UI experience.
The text was updated successfully, but these errors were encountered: