Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 3 additions & 12 deletions vpython/vpython.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ def Exit():
# attrs are X in {'a': '23X....'}
__attrs = {'pos':'a', 'up':'b', 'color':'c', 'trail_color':'d', # don't use single and double quotes; available: comma, but maybe that would cause trouble
'ambient':'e', 'axis':'f', 'size':'g', 'origin':'h',
'direction':'j', 'linecolor':'k', 'bumpaxis':'l', 'dot_color':'m',
'direction':'j', 'linecolor':'k', 'bumpaxis':'l',
'foreground':'n', 'background':'o', 'ray':'p', 'center':'E', 'forward':'#', 'resizable':'+',

# scalar attributes
Expand Down Expand Up @@ -120,7 +120,7 @@ def Exit():
'delete':'M', 'capture':'N'}

__vecattrs = ['pos', 'up', 'color', 'trail_color', 'axis', 'size', 'origin',
'direction', 'linecolor', 'bumpaxis', 'dot_color', 'ambient', 'add_to_trail',
'direction', 'linecolor', 'bumpaxis', 'ambient', 'add_to_trail',
'foreground', 'background', 'ray', 'ambient', 'center', 'forward', 'normal',
'marker_color', 'offset']

Expand Down Expand Up @@ -2101,7 +2101,6 @@ def setup(self, args):
super(gobj, self).__init__()
## default values of shared attributes
self._color = vector(0,0,0)
self._dot_color = vector(0,0,0)
self._marker_color = vector(0,0,0)
self._dot = False
self._delta = 1
Expand Down Expand Up @@ -2133,7 +2132,7 @@ def setup(self, args):
del args['pos']

## override default vector attributes
vectorAttributes = ['color', 'dot_color', 'marker_color']
vectorAttributes = ['color', 'marker_color']
for a in vectorAttributes:
if a in args:
argsToSend.append(a)
Expand Down Expand Up @@ -2341,14 +2340,6 @@ def dot(self,val):
self._dot = val
self.addattr('dot')

@property
def dot_color(self): return self._dot_color
@dot_color.setter
def dot_color(self,val):
if not isinstance(val, vector): raise TypeError('dot_color must be a vector')
self._dot_color = vector(val)
self.addattr('dot_color')

@property
def dot_radius(self): return self._dot_radius
@dot_radius.setter
Expand Down
2 changes: 1 addition & 1 deletion vpython/vpython_libraries/glow.min.js

Large diffs are not rendered by default.

5 changes: 4 additions & 1 deletion vpython/vpython_libraries/glowcomm.html
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,10 @@
window.close();
}

console.log('START OF GLOWCOMM')



console.log('START OF GLOWCOMM HTML')

function fontloading() {
"use strict";
Expand Down
2 changes: 1 addition & 1 deletion vpython/vpython_libraries/glowcomm.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ var isopen = false

window.Plotly = Plotly

console.log('START OF GLOWCOMM')
console.log('START OF GLOWCOMM JS')

IPython.notebook.kernel.comm_manager.register_target('glow',
function(commChannel, msg) {
Expand Down