diff options
author | Aleksei German <aleksei.german@qt.io> | 2020-08-27 16:42:22 +0200 |
---|---|---|
committer | Aleksei German <aleksei.german@qt.io> | 2020-08-28 06:48:02 +0000 |
commit | 61b21b0a2fa91d8146c1b68a267608159727e2b6 (patch) | |
tree | 25472d1385af119302f7e085e5b16a6782763c9a /src/plugins | |
parent | 3fd911023370879a89f6ca9e493cce5e0db294ac (diff) |
QmlDesigner: Fix for RichTextEditor Qt Version
Original task: QDS-2634
Change-Id: I7edc580aec36090e037c4520ad364a62427df9f0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Diffstat (limited to 'src/plugins')
-rw-r--r-- | src/plugins/qmldesigner/components/richtexteditor/richtexteditor.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/plugins/qmldesigner/components/richtexteditor/richtexteditor.cpp b/src/plugins/qmldesigner/components/richtexteditor/richtexteditor.cpp index f0cafc892d..eda25ec9b8 100644 --- a/src/plugins/qmldesigner/components/richtexteditor/richtexteditor.cpp +++ b/src/plugins/qmldesigner/components/richtexteditor/richtexteditor.cpp @@ -530,11 +530,14 @@ void RichTextEditor::setupTableActions() cursorEditBlock(cursor, [&] () { //format table cells to look a bit better: QTextTableFormat tableFormat; - tableFormat.setBorderCollapse(true); tableFormat.setCellSpacing(2.0); tableFormat.setCellPadding(2.0); tableFormat.setBorder(1.0); +#if (QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)) + tableFormat.setBorderCollapse(true); +#endif + cursor.insertTable(1, 1, tableFormat); //move cursor into the first cell of the table: |