[IPython-dev] Resetting widget application view/state

Adam Hughes hughesadam87 at gmail.com
Thu Oct 2 15:07:02 EDT 2014

Just to clarigy, the "Units" and "Sampling" widgets are the ones that ought
to reset their defaults based on the new dataset, which contains attributes
for its units and sampling is determined by the range of the index values.

On Thu, Oct 2, 2014 at 3:05 PM, Adam Hughes <hughesadam87 at gmail.com> wrote:

> Hi,
> Following the helpful discussion on widgets last month, we've made good
> progress with our spectroscopy widgets and are very happy!
> One issue we're having is that we want the user to be able to change which
> datateset he/she is piping is working with.  Different datasets have
> different default values, for example spectral units, start and end ranges
> etc...
> Right now, our application's view and model are completely separate;
> however, when the user chooses to work with a new dataset, we'd like the
> view to reset itself based on the new ranges for some of these attributes.
> We were hoping there was a smart way to do this!  Even if it's a total
> hack, that's fine.
> Here is the notebook:
> http://nbviewer.ipython.org/urls/raw.github.com/hugadams/pyuvvis/master/pyuvvis/interact/ipynbs/prototypes/widgets_slicing.ipynb
> I've attached a ss of the ouput
> The _filename_changed trait is where this new functionality should go.
> Thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20141002/95ea196a/attachment.html>

More information about the IPython-dev mailing list