def __init__(self, parent=None, **kw): BasePopup.__init__(self, parent, title="Scatter Plot", settings_key=["cs_scatter_settings"]) self.cs_scatter_cols_page = LabelledSpinBox(self, "Columns Per Page", minimum=1, step=1) self.cs_scatter_rows_page = LabelledSpinBox(self, "Rows Per Page", minimum=1, step=1) self.cs_scatter_x_label = LabelledLineEdit(self, "X Label") self.cs_scatter_y_label = LabelledLineEdit(self, "Y Label") self.cs_scatter_mksize = LabelledSpinBox(self, "Mark Size", minimum=0, step=1) self.cs_scatter_scale = LabelledDoubleSpinBox(self, "Scale", minimum=0, step=0.01) self.cs_scatter_mk_type = LabelledCombobox(self, text="Mark Type", items=['color', 'shape']) self.cs_scatter_mk_start_color = ColourBox(self, text="Mark Start Colour") self.cs_scatter_mk_end_color = ColourBox(self, text="Mark End Colour") self.cs_scatter_markers = LabelledLineEdit(self, "Sequential Markers") self.cs_scatter_mk_color = LabelledLineEdit(self, text="Mark Colours") self.cs_scatter_mk_missing_color = ColourBox(self, "Missing Mark Colour") self.cs_scatter_mk_edgecolors = LabelledLineEdit( self, "Marker Edge Colours") self.cs_scatter_hide_missing = LabelledCheckbox( self, "Hide Missing Data Points") # layout self.layout().addWidget(self.cs_scatter_cols_page, 0, 0) self.layout().addWidget(self.cs_scatter_rows_page, 1, 0) self.layout().addWidget(self.cs_scatter_x_label, 2, 0) self.layout().addWidget(self.cs_scatter_y_label, 3, 0) self.layout().addWidget(self.cs_scatter_mksize, 4, 0) self.layout().addWidget(self.cs_scatter_scale, 5, 0) self.layout().addWidget(self.cs_scatter_mk_type, 6, 0) self.layout().addWidget(self.cs_scatter_mk_start_color, 0, 1) self.layout().addWidget(self.cs_scatter_mk_end_color, 1, 1) self.layout().addWidget(self.cs_scatter_markers, 2, 1) self.layout().addWidget(self.cs_scatter_mk_color, 3, 1) self.layout().addWidget(self.cs_scatter_mk_edgecolors, 4, 1) self.layout().addWidget(self.cs_scatter_mk_missing_color, 5, 1) self.layout().addWidget(self.cs_scatter_hide_missing, 6, 1) self.buttonBox = QDialogButtonBox(QDialogButtonBox.Ok | QDialogButtonBox.Cancel | QDialogButtonBox.RestoreDefaults) self.buttonBox.accepted.connect(self.set_values) self.buttonBox.rejected.connect(self.reject) self.buttonBox.button( QDialogButtonBox.RestoreDefaults).clicked.connect( self.get_defaults) self.layout().addWidget(self.buttonBox, 7, 0, 1, 2) self.get_values()