File tree Expand file tree Collapse file tree 2 files changed +31
-1
lines changed Expand file tree Collapse file tree 2 files changed +31
-1
lines changed Original file line number Diff line number Diff line change 1
1
.pytest_cache
2
- dist
2
+ dist
3
+ env /
4
+ venv /
5
+ .vscode /
6
+ __pycache__ /
7
+ data /
Original file line number Diff line number Diff line change @@ -155,6 +155,31 @@ def reset(self):
155
155
renderWindow .GetRenderers ().GetFirstRenderer ().RemoveAllViewProps ()
156
156
print ("reset" )
157
157
158
+ @exportRpc ("toggle_edge_visibility" )
159
+ def setEdgeVisibility (self , params ):
160
+ print (f"{ params = } " , flush = True )
161
+ id = params ["id" ]
162
+ visibility = bool (params ["visibility" ])
163
+ actor = self .get_object (id )["actor" ]
164
+ actor .GetProperty ().SetEdgeVisibility (visibility )
165
+ self .render ()
166
+
167
+ @exportRpc ("toggle_point_visibility" )
168
+ def setPointVisibility (self , params ):
169
+ id = params ["id" ]
170
+ visibility = bool (params ["visibility" ])
171
+ actor = self .get_object (id )["actor" ]
172
+ actor .GetProperty ().SetVertexVisibility (visibility )
173
+ self .render ()
174
+
175
+ @exportRpc ("point_size" )
176
+ def setPointSize (self , params ):
177
+ id = params ["id" ]
178
+ size = float (params ["size" ])
179
+ actor = self .get_object (id )["actor" ]
180
+ actor .GetProperty ().SetPointSize (size )
181
+ self .render ()
182
+
158
183
def getProtocol (self , name ):
159
184
for p in self .coreServer .getLinkProtocols ():
160
185
if type (p ).__name__ == name :
You can’t perform that action at this time.
0 commit comments