コード例 #1
0
ファイル: page_charts.py プロジェクト: ssavva05/openmolar2
    def __init__(self, parent=None):
        super(ChartsPage, self).__init__(parent)

        self.patient = None

        #:
        self.static = ChartWidgetStatic(None, self)

        #: a pointer to the :doc:`ChartDataModel` of the static chart
        self.static_chart_model = self.static.chart_data_model

        self.tx_pl_model = SETTINGS.treatment_model.plan_tx_chartmodel
        #:
        self.treatment = ChartWidgetTreatment(self.tx_pl_model, self)

        tx_model = SETTINGS.treatment_model.cmp_tx_chartmodel
        #:
        self.completed = ChartWidgetCompleted(tx_model, self)

        self.tooth_data_editor = ToothDataEditor(self)

        right_widget = QtGui.QWidget(self)
        right_widget.setFixedWidth(150)
        layout = QtGui.QVBoxLayout(right_widget)
        layout.addWidget(self.tooth_data_editor)

        layout = QtGui.QGridLayout(self)
        layout.setMargin(3)
        layout.setSpacing(4)
        layout.addWidget(self.static, 0, 0)
        layout.addWidget(self.treatment, 1, 0)
        layout.addWidget(self.completed, 2, 0)
        layout.addWidget(right_widget, 0, 1, 3, 1)
        self.connect_signals()