1 /* 2 * Copyright 2007-2011 Thomas Baumgart <tbaumgart@kde.org> 3 * Copyright 2017 Łukasz Wojniłowicz <lukasz.wojnilowicz@gmail.com> 4 * 5 * This program is free software; you can redistribute it and/or 6 * modify it under the terms of the GNU General Public License as 7 * published by the Free Software Foundation; either version 2 of 8 * the License, or (at your option) any later version. 9 * 10 * This program is distributed in the hope that it will be useful, 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 * GNU General Public License for more details. 14 * 15 * You should have received a copy of the GNU General Public License 16 * along with this program. If not, see <http://www.gnu.org/licenses/>. 17 */ 18 19 #ifndef KBALANCECHARTDLG_H 20 #define KBALANCECHARTDLG_H 21 22 // ---------------------------------------------------------------------------- 23 // QT Includes 24 25 #include <QDialog> 26 27 // ---------------------------------------------------------------------------- 28 // KDE Includes 29 30 // ---------------------------------------------------------------------------- 31 // Project Includes 32 namespace reports { 33 class KReportChartView; 34 } 35 class MyMoneyAccount; 36 37 /** 38 * @author Thomas Baumgart <ipwizard@users.sourceforge.net> 39 * This dialog displays a chart with the account balance for the last 90 days. 40 * It also draws the account limit if the account has any. 41 */ 42 class KBalanceChartDlg : public QDialog 43 { 44 Q_OBJECT 45 public: 46 explicit KBalanceChartDlg(const MyMoneyAccount& account, QWidget* parent = nullptr); 47 ~KBalanceChartDlg(); 48 49 protected: 50 /** 51 * Draw the chart and calculate and draw the account limits if any 52 */ 53 reports::KReportChartView* drawChart(const MyMoneyAccount& account); 54 55 }; 56 57 #endif 58