Add mergeCells() function

This commit is contained in:
Debao Zhang
2013-09-06 13:00:09 +08:00
parent 827003f8ee
commit 5f444294bd
10 changed files with 242 additions and 7 deletions
+28
View File
@@ -0,0 +1,28 @@
#include <QtGui>
#include "xlsxworkbook.h"
#include "xlsxworksheet.h"
#ifdef Q_OS_MAC
# define DATA_PATH "../../../"
#else
# define DATA_PATH "./"
#endif
int main(int argc, char** argv)
{
QGuiApplication(argc, argv);
QXlsx::Workbook workbook;
QXlsx::Worksheet *sheet = workbook.addWorksheet();
sheet->write("B1", "Merge Cells");
sheet->mergeCells("B1:B5");
sheet->write("E2", "Merge Cells 2");
sheet->mergeCells("E2:G4");
workbook.save(DATA_PATH"Test.xlsx");
return 0;
}
+6
View File
@@ -0,0 +1,6 @@
TARGET = mergecells
#include(../../../src/xlsx/qtxlsx.pri)
QT += xlsx
SOURCES += main.cpp