filters

csvexportdialog.h
1/* This file is part of the KDE project
2 Copyright (C) 1999 David Faure <faure@kde.org>
3 Copyright (C) 2004 Nicolas GOUTTE <goutte@kde.org>
4
5 This library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Library General Public
7 License as published by the Free Software Foundation; either
8 version 2 of the License, or (at your option) any later version.
9
10 This library 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 GNU
13 Library General Public License for more details.
14
15 You should have received a copy of the GNU Library General Public License
16 along with this library; see the file COPYING.LIB. If not, write to
17 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18 * Boston, MA 02110-1301, USA.
19*/
20
21#ifndef CSVEXPORTDIALOG_H
22#define CSVEXPORTDIALOG_H
23
24#include <kdialogbase.h>
25
26class ExportDialogUI;
27class TQValidator;
28
29namespace KSpread
30{
31class Map;
32}
33
34class CSVExportDialog : public KDialogBase
35{
36 TQ_OBJECT
37
38 public:
39 CSVExportDialog(TQWidget * parent);
40 ~CSVExportDialog();
41
42 TQChar getDelimiter() const;
43 TQChar getTextQuote() const;
44 bool exportSheet( TQString const & sheetName ) const;
45 bool printAlwaysSheetDelimiter() const;
46 TQString getSheetDelimiter() const;
47 bool exportSelectionOnly() const;
48
49 void fillSheet( KSpread::Map * map );
50 TQString getEndOfLine(void) const;
51 TQTextCodec* getCodec(void) const;
52
53 private:
54 void loadSettings();
55 void saveSettings();
56 ExportDialogUI * m_dialog;
57
58 TQValidator* m_delimiterValidator;
59 TQString m_delimiter;
60 TQChar m_textquote;
61
62 private slots:
63 void slotOk();
64 void slotCancel();
65
66 void returnPressed();
67 void delimiterClicked( int id );
68 void textChanged ( const TQString & );
69 void textquoteSelected( const TQString & mark );
70 void selectionOnlyChanged( bool );
71};
72
73#endif