Changeset 1498
- Timestamp:
- 02/05/09 13:55:33 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/alma/python/interactivemask.py
r1460 r1498 82 82 marg = 0.05*(xmax-xmin) 83 83 panel['axes'].set_xlim(xmin-marg, xmax+marg) 84 self._p.show() 84 85 self._plot_mask() 85 86 … … 204 205 self._polygons=[] 205 206 # Plot new polygons 206 if len(msks) < 1: return 207 208 209 210 i = iloop % len(msks)211 if i == 0 : j += 1212 if len(ifs) > 1:213 for k in xrange(len(ifs)-1):214 self._polygons.append(self._p.subplots[j]['axes'].axvspan(projs[k][i][0],projs[k][i][1],facecolor='#aaaaaa'))215 self._polygons.append(self._p.subplots[j]['axes'].axvspan(msks[i][0],msks[i][1],facecolor='yellow'))216 self._p. show()207 if len(msks) > 0: 208 npanel=len(self._p.subplots) 209 j=-1 210 for iloop in range(len(msks)*npanel): 211 i = iloop % len(msks) 212 if i == 0 : j += 1 213 if len(ifs) > 1: 214 for k in xrange(len(ifs)-1): 215 self._polygons.append(self._p.subplots[j]['axes'].axvspan(projs[k][i][0],projs[k][i][1],facecolor='#aaaaaa')) 216 self._polygons.append(self._p.subplots[j]['axes'].axvspan(msks[i][0],msks[i][1],facecolor='yellow')) 217 self._p.canvas.draw() 217 218 218 219 def get_mask(self):
Note:
See TracChangeset
for help on using the changeset viewer.