Trouble with uc.disable_auto_display_refresh() #170
-
|
Hi, I encounter trouble with the uc.disable_auto_display_refresh() function on several occasions. After creating for example beams with disabled auto display and deleting them, there are points from those elements that can't be clicked or removed. To remove them, one needs to restart Cadwork. Is this a known issue? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
|
@roehligas |
Beta Was this translation helpful? Give feedback.
-
|
If u make use of the uc.disable_auto_display_refresh()
element_map_by_type = defaultdict(list)
move_distance_in_x_direction = 0.0
for i in range(100):
beam_element_id = ec.create_square_beam_vectors(200, 1500, cadwork.point_3d(move_distance_in_x_direction, 0, 0),
cadwork.point_3d(0, 0, 1),
cadwork.point_3d(0, 1, 0))
panel_element_id = ec.create_rectangular_panel_vectors(200, 15, 1500, cadwork.point_3d(move_distance_in_x_direction, -107.5, 0),
cadwork.point_3d(0, 0, 1),
cadwork.point_3d(0, 1, 0))
element_map_by_type['beam'].append(beam_element_id)
element_map_by_type['panel'].append(panel_element_id)
print(f"Created beam element with id: {beam_element_id}")
print(f"Created panel element with id: {panel_element_id}")
move_distance_in_x_direction += 250.0
ec.move_element(element_map_by_type['beam'], cadwork.point_3d(1200.0, 0, 300))
uc.enable_auto_display_refresh()
# Comment out this line to regenerate the elements
# ec.recreate_elements(element_map_by_type['beam'] + element_map_by_type['panel'])I you make use of the |
Beta Was this translation helpful? Give feedback.


If u make use of the
...auto_display_refresh, you are responsible for element regeneration.