From aa70434cb5e7675134aaeffb15b5fd964f08713b Mon Sep 17 00:00:00 2001 From: AndresOrtegaGuerrero Date: Mon, 2 Dec 2024 15:40:57 +0000 Subject: [PATCH] phonon tab results --- src/aiidalab_qe_vibroscopy/app/result/result.py | 1 + src/aiidalab_qe_vibroscopy/app/widgets/phononwidget.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/aiidalab_qe_vibroscopy/app/result/result.py b/src/aiidalab_qe_vibroscopy/app/result/result.py index 8baa363..c3cc01b 100644 --- a/src/aiidalab_qe_vibroscopy/app/result/result.py +++ b/src/aiidalab_qe_vibroscopy/app/result/result.py @@ -79,6 +79,7 @@ def render(self): self.children = [self.tabs] self.rendered = True + self.tabs.selected_index = 0 def _on_tab_change(self, change): if (tab_index := change["new"]) is None: diff --git a/src/aiidalab_qe_vibroscopy/app/widgets/phononwidget.py b/src/aiidalab_qe_vibroscopy/app/widgets/phononwidget.py index a951dd8..c5df792 100644 --- a/src/aiidalab_qe_vibroscopy/app/widgets/phononwidget.py +++ b/src/aiidalab_qe_vibroscopy/app/widgets/phononwidget.py @@ -68,7 +68,7 @@ def _init_view(self): self.bands_pdos.update_layout( xaxis=dict(title="q-points"), yaxis=dict(title="Phonon Bands (THz)", range=[y_min - 0.1, y_max + 0.1]), - yaxis2=dict(range=[0, x_max + 0.1]), + xaxis2=dict(range=[0, x_max + 0.1]), ) self.children = (self.bands_pdos, *self.children) self._model.update_thermo_plot(self.thermal_plot)