Coverage for python/lsst/afw/display/ds9.py : 64%
Hot-keys on this page
r m x p toggle line displays
j k next/prev highlighted chunk
0 (zero) top of page
1 (one) first highlighted chunk
|
# # LSST Data Management System # Copyright 2008, 2009, 2010, 2015 LSST Corporation. # # This product includes software developed by the # LSST Project (http://www.lsst.org/). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the LSST License Statement and # the GNU General Public License along with this program. If not, # see <http://www.lsstcorp.org/LegalNotices/>. #
# Backwards compatibility. Downstream code should be converted to use display.RED etc. getDisplay = _getDisplay # No usable version of display_ds9. # Let's define a version of getDisplay() which will throw an exception.
# Prior to DM-9433, we used a closure to implicitly capture the # exception being thrown for future reference. Following changes to # exception scope rules in Python 3 (see PEP 3110), it's now regarded # as clearer to make the capture explicit using the following class. # The exception being caught above may have a bulky context which we # don't want to capture in a closure for all time: see DM-9504 for a # full discussion. We therefore define a new exception of the same # type, which just encodes the error text.
else: loaded = True
# always use the real one return _getDisplay(None, create=True).Buffering()
# # Functions provided for backwards compatibility #
return getDisplay(frame, create=True).setMaskPlaneColor(name, color)
return getDisplay(frame, create=True).getMaskPlaneColor(name)
return getDisplay(frame, create=True).setMaskTransparency(name)
return getDisplay(frame, create=True).getMaskTransparency(name)
return getDisplay(frame, create=True).show()
return getDisplay(frame, create=True).erase()
return getDisplay(frame, create=True).dot(symb, c, r, size, ctype, origin, *args, **kwargs)
return getDisplay(frame, create=True).line(points, origin, symbs, ctype, size)
return getDisplay(frame, create=True).scale(algorithm, min, max)
disp = getDisplay(frame, create=True)
disp.pan(colc, rowc, origin)
disp = getDisplay(frame, create=True)
disp.zoom(zoomfac) disp.pan(colc, rowc, origin)
return getDisplay(frame, create=True).interact()
return getDisplay(frame, create=True).setCallback(k, noRaise=False)
return getDisplay(frame, create=True).getActiveCallbackKeys(onlyActive) |