diff options
author | Nils Jeisecke <nils.jeisecke@saltation.com> | 2019-07-22 19:06:34 +0200 |
---|---|---|
committer | Shawn Rutledge <shawn.rutledge@qt.io> | 2019-08-09 07:21:25 +0000 |
commit | 9c891bead8c14af0aa2fd10f74275e35af87b16c (patch) | |
tree | 394aacc49ff6443ed48f68074eb82aa58ff0d12e /tests/manual/qtexttableborders/widget.h | |
parent | c595878aa34c5861b00f0c59bc4b0b6c02a54543 (diff) |
QTextDocument: add manual test for table border logic
This adds a manual test for the QTextTable border logic.
Two HTML files are bundled as resources:
table-border-test.html: Contains various test cases for the border
logic.
table-border-test-header.html: Contains a test case for printing a table
with a repeated header.
The test application allows:
- editing
- previewing
- printing
- opening the HTML in the system browser (via temp. file)
It is possible to edit the HTML with "live preview" so new test cases
can easily be implemented.
Change-Id: Ic88488bc8b7dd74d5c03c3363f55840423462325
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Diffstat (limited to 'tests/manual/qtexttableborders/widget.h')
-rw-r--r-- | tests/manual/qtexttableborders/widget.h | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/tests/manual/qtexttableborders/widget.h b/tests/manual/qtexttableborders/widget.h new file mode 100644 index 0000000000..9cf459e1cd --- /dev/null +++ b/tests/manual/qtexttableborders/widget.h @@ -0,0 +1,56 @@ +/**************************************************************************** +** +** Copyright (C) 2019 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of the test suite of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:GPL-EXCEPT$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 as published by the Free Software +** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#ifndef WIDGET_H +#define WIDGET_H + +#include <QWidget> + +namespace Ui { +class Widget; +} + +class Widget : public QWidget +{ + Q_OBJECT + +public: + explicit Widget(QWidget *parent = nullptr); + ~Widget(); + +private slots: + void onDocumentSelected(); + void onPrint(); + void onPreview(); + void onOpenBrowser(); + +private: + Ui::Widget *ui; +}; + +#endif // WIDGET_H |