diff --git a/py2cytoscape/cyrest/cyrest.py b/py2cytoscape/cyrest/cyrest.py index 3e1fc6d..b8a4427 100644 --- a/py2cytoscape/cyrest/cyrest.py +++ b/py2cytoscape/cyrest/cyrest.py @@ -125,7 +125,7 @@ def MAKETMP(): response=api("view","fit content",host=host,port=port, version=version, verbose=verbose) sleep(2) - response=api("view", "export" , {"options":filetype,"OutputFile":outfile}, host=host,port=port,version=version,verbose=verbose) + response=api("view", "export" , {"options":filetype,"outputFile":outfile, "view":"current"}, host=host,port=port,version=version,verbose=verbose) if host!='localhost': import paramiko print("Looking to ssh keys for remote access.") diff --git a/py2cytoscape/cyrest/view.py b/py2cytoscape/cyrest/view.py index 502e53a..b4c36b7 100644 --- a/py2cytoscape/cyrest/view.py +++ b/py2cytoscape/cyrest/view.py @@ -43,7 +43,7 @@ def destroy(self, verbose=False): response=api(url=self.__url+"/destroy", PARAMS=PARAMS, method="POST", verbose=verbose) return response - def export(self, options=None, OutputFile=None, Resolution=None,\ + def export(self, options=None, outputFile=None, Resolution=None,\ Units=None, Width=None, Zoom=None, view="current", verbose=False): """ Exports the current view to a graphics file and returns the path to the @@ -78,9 +78,9 @@ def export(self, options=None, OutputFile=None, Resolution=None,\ :returns: path to the saved file """ - PARAMS=set_param(["Height","options","OutputFile","Resolution",\ + PARAMS=set_param(["Height","options","outputFile","Resolution",\ "Units","Width","Zoom","view"],\ - [Height,options,OutputFile,Resolution,Units,Width,Zoom,view ]) + [Height,options,outputFile,Resolution,Units,Width,Zoom,view ]) response=api(url=self.__url+"/export", PARAMS=PARAMS, method="POST", verbose=verbose) return response