ericmandel / pyds9

Python connection to SAOimage DS9 via XPA
76 stars 41 forks source link

passing parameters to the constructor #13

Closed mherkazandjian closed 9 years ago

mherkazandjian commented 9 years ago

Hi,

I was trying to launch an instance of DS9 using:

from pyds9 import DS9 d = DS9('-geometry 1920x1080')

This seems to cause some confusion. I think it would be useful to add a keyword to the constructor that passes the arguments that would otherwise be used to launch ds9 from the command line to Popen. I patched this locally. So now i can do the following:

d = DS9(parms='-geometry 1920x1080')

Thisway there is a clear distinction between the pyds9.DS9 keywords and the parameters passed in launching 'ds9' itself.

cheer, mher.

ericmandel commented 9 years ago

The 'start' parameter already does this:

d = pyds9.DS9(start="-cmap red -scale log -geometry 1920x1080")
mherkazandjian commented 9 years ago

cool. i missed that. tnx.