py3Dmol 2.4.2__tar.gz → 2.5.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: py3Dmol
3
- Version: 2.4.2
3
+ Version: 2.5.0
4
4
  Summary: An IPython interface for embedding 3Dmol.js views in Jupyter notebooks
5
5
  Home-page: https://3dmol.org
6
6
  Author: David Koes
@@ -16,8 +16,19 @@ Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
16
16
  Classifier: License :: OSI Approved :: MIT License
17
17
  Classifier: Programming Language :: Python :: 2
18
18
  Classifier: Programming Language :: Python :: 3
19
- Provides-Extra: ipython
20
19
  License-File: LICENSE.txt
20
+ Provides-Extra: ipython
21
+ Requires-Dist: IPython; extra == "ipython"
22
+ Dynamic: author
23
+ Dynamic: author-email
24
+ Dynamic: classifier
25
+ Dynamic: description
26
+ Dynamic: home-page
27
+ Dynamic: keywords
28
+ Dynamic: license
29
+ Dynamic: license-file
30
+ Dynamic: provides-extra
31
+ Dynamic: summary
21
32
 
22
33
  py3Dmol
23
34
  =======
@@ -54,7 +54,7 @@ class view(object):
54
54
  the exception that the functions all return None.
55
55
  http://3dmol.org/doc/GLViewer.html
56
56
  '''
57
- def __init__(self,query='',width=640,height=480,viewergrid=None,data=None,style=None,linked=True,options=dict(),format=None,js='https://cdnjs.cloudflare.com/ajax/libs/3Dmol/2.4.2/3Dmol-min.js'):
57
+ def __init__(self,query='',width=640,height=480,viewergrid=None,data=None,style=None,linked=True,options=dict(),format=None,js='https://cdn.jsdelivr.net/npm/3dmol@2.5.0/build/3Dmol-min.js'):
58
58
  '''Create a 3Dmol.js view.
59
59
  width -- width in pixels of container
60
60
  height -- height in pixels of container
@@ -63,7 +63,7 @@ class view(object):
63
63
  data -- molecular data to provide to addModel, with viewer grid can be indexed (r,c)
64
64
  format -- format of provided data
65
65
  style -- style to apply, with viewer grid can be indexed (r,c)
66
- options -- optional options to provide to $3Dmol.download
66
+ options -- optional options to provide to $3Dmol.download or addModel
67
67
  js -- url for 3Dmol.js'''
68
68
  divid = "3dmolviewer_UNIQUEID"
69
69
  warnid = "3dmolwarning_UNIQUEID"
@@ -159,7 +159,7 @@ if(warn) {
159
159
  f = format[r][c]
160
160
  except:
161
161
  f = format
162
- self.startjs += f"viewergrid_UNIQUEID[{r}][{c}].addModel({json.dumps(d)}{','+json.dumps(f) if f else ''});\n"
162
+ self.startjs += f"viewergrid_UNIQUEID[{r}][{c}].addModel({json.dumps(d)},{json.dumps(f) if f else 'undefined'},{json.dumps(options) if options else 'undefined'});\n"
163
163
  if style:
164
164
  try:
165
165
  s = style[r][c]
@@ -171,7 +171,7 @@ if(warn) {
171
171
  else:
172
172
  cmds = ''
173
173
  if data:
174
- cmds = f"viewer_UNIQUEID.addModel({json.dumps(data)}{','+json.dumps(format) if format else ''});\n"
174
+ cmds = f"viewer_UNIQUEID.addModel({json.dumps(data)},{json.dumps(format) if format else 'undefined'},{json.dumps(options) if options else 'undefined'});\n"
175
175
  if style:
176
176
  cmds += "viewer_UNIQUEID.setStyle(%s);\n"%json.dumps(style)
177
177
  self.startjs += cmds + "viewer_UNIQUEID.zoomTo();\n"
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: py3Dmol
3
- Version: 2.4.2
3
+ Version: 2.5.0
4
4
  Summary: An IPython interface for embedding 3Dmol.js views in Jupyter notebooks
5
5
  Home-page: https://3dmol.org
6
6
  Author: David Koes
@@ -16,8 +16,19 @@ Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
16
16
  Classifier: License :: OSI Approved :: MIT License
17
17
  Classifier: Programming Language :: Python :: 2
18
18
  Classifier: Programming Language :: Python :: 3
19
- Provides-Extra: ipython
20
19
  License-File: LICENSE.txt
20
+ Provides-Extra: ipython
21
+ Requires-Dist: IPython; extra == "ipython"
22
+ Dynamic: author
23
+ Dynamic: author-email
24
+ Dynamic: classifier
25
+ Dynamic: description
26
+ Dynamic: home-page
27
+ Dynamic: keywords
28
+ Dynamic: license
29
+ Dynamic: license-file
30
+ Dynamic: provides-extra
31
+ Dynamic: summary
21
32
 
22
33
  py3Dmol
23
34
  =======
@@ -24,7 +24,7 @@ setup(
24
24
  # the version across setup.py and the project code, see
25
25
  # https://packaging.python.org/en/latest/single_source_version.html
26
26
  # Keep version in synce with 3Dmol.js version. Use "postX" suffix if needed
27
- version='2.4.2',
27
+ version='2.5.0',
28
28
 
29
29
  description='An IPython interface for embedding 3Dmol.js views in Jupyter notebooks',
30
30
  long_description=long_description,
File without changes
File without changes
File without changes
File without changes