py4cytoscape.tools.cybrowser_dialog
-
cybrowser_dialog
(id=None, text=None, title=None, url=None, base_url='http://127.0.0.1:1234/v1')[source] Launch Cytoscape’s internal web browser in a separate window
Provide an id for the window if you want subsequent control of the window e.g., via cybrowser hide.
- Parameters
id (str) – The identifier for the new browser window
text (str) – HTML text to initially load into the browser
title (str) – Text to be shown in the title bar of the browser window
url (str) – The URL the browser should load
base_url (str) – Ignore unless you need to specify a custom domain, port or version to connect to the CyREST API. Default is http://127.0.0.1:1234 and the latest version of the CyREST API supported by this version of py4cytoscape.
- Returns
{‘id’: id} where
id
is the one provided as a parameter to this function- Return type
dict
- Raises
requests.exceptions.RequestException – if can’t connect to Cytoscape or Cytoscape returns an error
Examples
>>> cybrowser_dialog(id='Test Window', title='Hello Africa', text='<HTML><HEAD><TITLE>Hello</TITLE></HEAD><BODY>Hello, world!</BODY></HTML>') {'id': 'Test Window'} >>> cybrowser_dialog(id='CytoWindow', title='Cytoscape Home Page', url='http://www.cytoscape.org') {'id': 'CytoWindow'}
See also