77import pandas as pd
88
99from faslr .model import FModelWidget
10+ from faslr .utilities .style_parser import parse_styler
1011
1112from PyQt6 .QtGui import (
1213 QKeyEvent ,
3536
3637from PyQt6 .QtWidgets import (
3738 QApplication ,
39+ QCheckBox ,
3840 QHBoxLayout ,
3941 QPushButton ,
4042 QVBoxLayout ,
@@ -461,6 +463,8 @@ def __init__(
461463 ):
462464 super ().__init__ ()
463465 self .parent : FSelectionModelWidget = parent
466+
467+ self .check_heatmap = QCheckBox (text = 'Heatmap' )
464468 self .add_average_button = QPushButton ("Available Averages" )
465469 self .add_average_button .setFixedWidth (self .add_average_button .sizeHint ().width ())
466470
@@ -487,8 +491,10 @@ def __init__(
487491 data = averages
488492 )
489493
494+ self .layout .addWidget (self .check_heatmap )
490495 self .layout .addWidget (self .add_average_button )
491496
497+ # self.check_heatmap.stateChanged.connext(self.toggle_heatmap)
492498 self .add_average_button .clicked .connect (self .open_average_box ) # noqa
493499
494500 def open_average_box (self ) -> None :
@@ -497,6 +503,19 @@ def open_average_box(self) -> None:
497503 """
498504 self .average_box .show ()
499505
506+ # def toggle_heatmap(self):
507+ #
508+ # selection_model: FSelectionModel = self.parent.selection_model
509+ #
510+ # if self.check_heatmap.isChecked():
511+ # selection_model.heatmap_frame = parse_styler(
512+ # selection_model.df_ratio,
513+ # cmap="coolwarm"
514+ # )
515+ # selection_model.layoutChanged.emit() # noqa
516+ # else:
517+ # selection_model.layoutChanged.emit() # noqa
518+
500519class FModelView (FTableView ):
501520 """
502521 Model view for displaying the ratios and averages that the user uses to make a selection.
0 commit comments