kspread

krs_doc.h
1/*
2 * Copyright (c) 2005 Cyrille Berger <cberger@cberger.net>
3 * Copyright (c) 2006 Isaac Clerencia <isaac@warp.es>
4 *
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU Library General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (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 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 program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18 */
19
20#ifndef KSPREAD_KROSS_KRS_DOC_H_
21#define KSPREAD_KROSS_KRS_DOC_H_
22
23#include <kspread_doc.h>
24
25#include <api/class.h>
26
27#include <tqstring.h>
28#include <tqstringlist.h>
29#include <tqdom.h>
30
31namespace Kross { namespace KSpreadCore {
32
33class Sheet;
34
43class Doc : public Kross::Api::Class<Doc>
44{
45 public:
46 explicit Doc(KSpread::Doc* doc);
47 virtual ~Doc();
48 virtual const TQString getClassName() const;
49 private:
50
61 Sheet* currentSheet();
62
72 Sheet* sheetByName(const TQString& name);
73
84 TQStringList sheetNames();
85
89 bool addSheet(const TQString& sheetname);
90
94 bool removeSheet(const TQString& sheetname);
95
99 bool loadNativeXML(const TQString& xml);
103 TQString saveNativeXML();
104
105#if 0
106 bool loadOpenDocXML(const TQString& xml);
107 TQString saveOpenDocXML();
108#endif
109
110 bool openUrl(const TQString& url);
111 bool saveUrl(const TQString& url);
112 bool import(const TQString& url);
113 bool exp0rt(const TQString& url);
114
115 private:
116 KSpread::Doc* m_doc;
117};
118}
119}
120
121
122#endif
This class holds the data that makes up a spreadsheet.
Definition kspread_doc.h:98
A sheet in a document.
Definition krs_sheet.h:51