from ocp_vscode import show, show_object, reset_show, set_port, set_defaults, get_defaults, Camera
set_port(3939)
set_defaults(reset_camera=Camera.KEEP)
import build123d as bd
part = bd.Box(10,20,30)
#show(part) # Resets the view even though defaults are set
show(part, reset_camera=Camera.KEEP) # Respects the camera setting
The second show command does not reset the view between runs of this code. The first one does however. I would expect them both to respect the settings of the camera, even between full runs of the file.
As was discussed on cadquery-discord, this is meant to be used in jupyter-mode. I think it would be of value if this is respected no matter what "mode" you use. This tripped me up, and I would think I'm not alone in that. This is the first editor that I use that resets the view on every re-render.
So - I would like it if possible to have the camera-setting be respected when set with set_defaults even when not using jupyter-mode.
Small example
The second
show
command does not reset the view between runs of this code. The first one does however. I would expect them both to respect the settings of the camera, even between full runs of the file.As was discussed on cadquery-discord, this is meant to be used in jupyter-mode. I think it would be of value if this is respected no matter what "mode" you use. This tripped me up, and I would think I'm not alone in that. This is the first editor that I use that resets the view on every re-render.
So - I would like it if possible to have the camera-setting be respected when set with
set_defaults
even when not using jupyter-mode.