Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #33795

Re: Update slider widget range

From Mark Lawrence <breamoreboy@yahoo.co.uk>
Subject Re: Update slider widget range
Date 2012-11-22 09:20 +0000
References <bebf3e35-8200-4501-b33b-842607eac576@googlegroups.com>
Newsgroups comp.lang.python
Message-ID <mailman.199.1353575895.29569.python-list@python.org> (permalink)

Show all headers | View raw


On 21/11/2012 13:59, moadeep wrote:
> I am trying to write a small bit of code that interactively deletes selected slices in an image series using matplotlib. I have created a button 'delete' which stores a number of indices to be deleted when the button 'update' is selected. However, I am currently unable to reset the range of my slider widget, i.e. removing the number of deleted slices from valmax. What is the pythonic solution to this problem?
>
>          self.nframes =  len(self.raw_dicom_stack)

If I've read your intentions correctly the line above should read

self.slider.valmax = len(self.raw_dicom_stack)

If I'm wrong then please ask on the matplotlib users mailing list or 
possibly stackoverflow.

-- 
Cheers.

Mark Lawrence.

Back to comp.lang.python | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

Update slider widget range moadeep <j.robinson.10@aberdeen.ac.uk> - 2012-11-21 05:59 -0800
  Re: Update slider widget range Mark Lawrence <breamoreboy@yahoo.co.uk> - 2012-11-22 09:20 +0000

csiph-web