File indexing completed on 2025-01-05 03:35:39
0001 /* 0002 File : DropValuesDialog.h 0003 Project : LabPlot 0004 Description : Dialog for droping and masking values in columns 0005 -------------------------------------------------------------------- 0006 SPDX-FileCopyrightText: 2015-2022 Alexander Semke <alexander.semke@web.de> 0007 SPDX-License-Identifier: GPL-2.0-or-later 0008 */ 0009 0010 #ifndef DROPVALUESDIALOG_H 0011 #define DROPVALUESDIALOG_H 0012 0013 #include "ui_dropvalueswidget.h" 0014 #include <QDialog> 0015 0016 class Column; 0017 class Spreadsheet; 0018 class QPushButton; 0019 0020 class DropValuesDialog : public QDialog { 0021 Q_OBJECT 0022 0023 public: 0024 explicit DropValuesDialog(Spreadsheet* s, bool mask = false, QWidget* parent = nullptr); 0025 ~DropValuesDialog() override; 0026 void setColumns(const QVector<Column*>&); 0027 0028 private: 0029 Ui::DropValuesWidget ui; 0030 QVector<Column*> m_columns; 0031 Spreadsheet* m_spreadsheet; 0032 QPushButton* m_okButton; 0033 bool m_mask{false}; 0034 bool m_hasNumeric{false}; 0035 bool m_hasText{false}; 0036 bool m_hasDateTime{false}; 0037 0038 void dropValues() const; 0039 void maskValues() const; 0040 0041 private Q_SLOTS: 0042 void operatorChanged(int) const; 0043 void operatorDateTimeChanged(int) const; 0044 void okClicked() const; 0045 }; 0046 0047 #endif