Add linked charts guard-flag for use in display loop

multichartz
Tyler Goodlet 2023-01-24 12:32:42 -05:00
parent 96d485b6ed
commit 0711b469b4
1 changed files with 8 additions and 3 deletions

View File

@ -803,7 +803,7 @@ class ChartView(ViewBox):
''' '''
name = self.name name = self.name
# print(f'YRANGE ON {name}') # print(f'YRANGE ON {name} -> yrange{yrange}')
profiler = Profiler( profiler = Profiler(
msg=f'`ChartView._set_yrange()`: `{name}`', msg=f'`ChartView._set_yrange()`: `{name}`',
disabled=not pg_profile_enabled(), disabled=not pg_profile_enabled(),
@ -950,9 +950,11 @@ class ChartView(ViewBox):
def interact_graphics_cycle( def interact_graphics_cycle(
self, self,
*args, *args, # capture signal-handler related shit
debug_print: bool = False, debug_print: bool = False,
do_overlay_scaling: bool = True, do_overlay_scaling: bool = True,
do_linked_charts: bool = True,
): ):
profiler = Profiler( profiler = Profiler(
msg=f'ChartView.interact_graphics_cycle() for {self.name}', msg=f'ChartView.interact_graphics_cycle() for {self.name}',
@ -974,7 +976,10 @@ class ChartView(ViewBox):
plots = {chart.name: chart} plots = {chart.name: chart}
linked = self.linked linked = self.linked
if linked: if (
do_linked_charts
and linked
):
plots |= linked.subplots plots |= linked.subplots
for chart_name, chart in plots.items(): for chart_name, chart in plots.items():