summaryrefslogtreecommitdiffstats
path: root/src/gui/text
Commit message (Collapse)AuthorAgeFilesLines
* Markdown: blockquotes, code blocks, and generalized nestingShawn Rutledge2019-05-086-42/+133
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Can now detect nested quotes and code blocks inside quotes, and can rewrite the markdown too. QTextHtmlParser sets hard-coded left and right margins, so we need to do the same to be able to read HTML and write markdown, or vice-versa, and to ensure that all views (QTextEdit, QTextBrowser, QML Text etc.) will render it with margins. But now we add a semantic memory too: BlockQuoteLevel is similar to HeadingLevel, which was added in 310daae53926628f80c08e4415b94b90ad525c8f to preserve H1..H6 heading levels, because detecting it via font size didn't make sense in QTextMarkdownWriter. Likewise detecting quote level by its margins didn't make sense; markdown supports nesting quotes; and indenting nested quotes via 40 pixels may be a bit too much, so we should consider it subject to change (and perhaps be able to change it via CSS later on). Since we're adding BlockQuoteLevel and depending on it in QTextMarkdownWriter, it's necessary to set it in QTextHtmlParser to enable HTML->markdown conversion. (But so far, nested blockquotes in HTML are not supported.) Quotes (and nested quotes) can contain indented code blocks, but it seems the reverse is not true (according to https://spec.commonmark.org/0.29/#example-201 ) Quotes can contain fenced code blocks. Quotes can contain lists. Nested lists can be interrupted with nested code blocks and nested quotes. So far the writer assumes all code blocks are the indented type. It will be necessary to add another attribute to remember whether the code block is indented or fenced (assuming that's necessary). Fenced code blocks would work better for writing inside block quotes and list items because the fence is less ambiguous than the indent. Postponing cursor->insertBlock() as long as possible helps with nesting. cursor->insertBlock() needs to be done "just in time" before inserting text that will go in the block. The block and char formats aren't necessarily known until that time. When a nested block (such as a nested quote) ends, the context reverts to the previous block format, which then needs to be re-determined and set before we insert text into the outer block; but if no text will be inserted, no new block is necessary. But we can't use QTextBlockFormat itself as storage, because for some reason bullets become very "sticky" and it becomes impossible to have plain continuation paragraphs inside list items: they all get bullets. Somehow QTextBlockFormat remembers, if we copy it. But we can create a new one each time and it's OK. Change-Id: Icd0529eb90d2b6a3cb57f0104bf78a7be81ede52 Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
* Change QTextMarkdownWriter to pass by const pointer and QAIMShawn Rutledge2019-05-084-17/+17
| | | | | | | | | - QObjects are always passed by pointer not by reference, by convention - writeTable() takes QAIM rather than QATM to make testing via QStandardItemModel possible in the future Change-Id: I5bc6b8cd9709da4fb5d57d98fa22e0cb34360944 Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
* Markdown: deal with horizontal rules (thematic breaks)Shawn Rutledge2019-05-082-1/+5
| | | | | Change-Id: I14d4bcfe1a6c3bd87d1328f0abb81b2138545e4e Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
* Markdown: fix several issues with lists and continuationsShawn Rutledge2019-05-084-27/+152
| | | | | | | | | | | | | | | | | | | | Importer fixes: - the first list item after a heading doesn't keep the heading font - the first text fragment after a bullet is the bullet text, not a separate paragraph - detect continuation lines and append to the list item text - detect continuation paragraphs and indent them properly - indent nested list items properly - add a test for QTextMarkdownImporter Writer fixes: - after bullet items, continuation lines and paragraphs are indented - indentation of continuations isn't affected by checkboxes - add extra newlines between list items in "loose" lists - avoid writing triple newlines - enhance the test for QTextMarkdownWriter Change-Id: Ib1dda514832f6dc0cdad177aa9a423a7038ac8c6 Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
* Remove 3rdparty include from QTextMarkdownImporter header fileShawn Rutledge2019-05-082-47/+47
| | | | | | | | It's a private header; but to be able to use it in a test, it has to be as clean as a public header. Change-Id: I868372406e62acc24051a6523fee89bb911a61f9 Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
* Deprecate conversion functions between QList and QSetLars Knoll2019-05-071-1/+1
| | | | | | | | | | Users should use range constructors instead to do the conversion. Keep conversion methods between QList and QVector as these will turn into a no-op in Qt 6, whereas forcing people to use range constructors would lead to deep copies of the data. Change-Id: Id9fc9e4d007044e019826da523e8418857c91283 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Merge remote-tracking branch 'origin/5.13' into devLiang Qi2019-05-073-3/+6
|\ | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/kernel/qobject.cpp src/corelib/kernel/qvariant.h src/corelib/tools/qlist.h Done-With: Milian Wolff <milian.wolff@kdab.com> Done-With: Allan Sandfeld Jensen <allan.jensen@qt.io> Change-Id: I6803f7239aa137a51a7467fab7cc7a01302a848d
| * Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-05-062-3/+5
| |\ | | | | | | | | | Change-Id: Iaad9509712c848ed42ada2c25065162a6fc5a930
| | * fix compilation with various -no-feature-* optionsNick Shaforostov2019-05-052-3/+5
| | | | | | | | | | | | | | | Change-Id: Ic1975db497613e3efe50be4246c167efe10d8e31 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
| * | Fix -Wdeprecated-copy warningsAllan Sandfeld Jensen2019-05-011-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implicit copy constructors or methods are considered deprecated for classes that has one of the two or a destructor. The warning is enabled with -Wextra in gcc 9 Change-Id: Ic9be654f2a142fb186a4d5a7d6b4f7d6f4e611d8 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Prefix QTextStream operators with Qt::Lars Knoll2019-05-031-3/+3
| | | | | | | | | | | | | | | Change-Id: I128769cb78abb8168f0bf29cef8c693073793ced Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | QTextMarkdownImporter: Fix deprecation warningFriedemann Kleint2019-05-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use QTextCharFormat::setAnchorNames(), fixing: text/qtextmarkdownimporter.cpp:322:36: warning: 'void QTextCharFormat::setAnchorName(const QString&)' is deprecated: Use setAnchorNames() instead [-Wdeprecated-declarations] Amends 65314b6ce88cdbb28a22be0cab9856ec9bc9604b. Task-number: QTBUG-72349 Change-Id: I7f909d1fcc5c4045c738b5a5c491b2ac1de6eac5 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | | Prefix textstream operators with Qt::Lars Knoll2019-05-023-8/+8
| | | | | | | | | | | | | | | | | | | | | As the non prefixed variants are deprecated Change-Id: I2ba09d71b9cea5203b54297a3f2332e6d44fedcf Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Add QTextMarkdownWriter::writeTable(QAbstractTableModel)Shawn Rutledge2019-05-022-0/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This provides the ability to write live data from a table to Markdown, which can be useful to load it into a text document or a wiki. But so far QTextMarkdownWriter is still a private class, intended to be used experimentally from QtQuick and perhaps later exposed in other ways. Change-Id: I0de4673987e4172178604e49b5a024a05d4486ba Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | | Render markdown task lists (checkboxes instead of bullets) in QTextEditShawn Rutledge2019-05-021-6/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | Checkboxes are right-aligned with any bullets that are in the same QTextList so that there is enough space to make them larger than bullets. But hopefully mixing bullets and checkboxes will be a rarely-used feature. Change-Id: I28e274d1f7883aa093df29eb4988e99641e87a71 Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
* | | Remove handling of missing Q_COMPILER_RVALUE_REFSAllan Sandfeld Jensen2019-05-016-14/+0
| | | | | | | | | | | | | | | | | | | | | | | | Remove remaining handling of missing support for rvalue refs. Change-Id: I78bab8bccfeeb9c76f464f345874364a37e4840a Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Add QTextMarkdownWriter, QTextEdit::markdown property etc.Shawn Rutledge2019-05-016-3/+506
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A QTextDocument can now be written out in Markdown format. - Add the QTextMarkdownWriter as a private class for now - Add QTextDocument::toMarkdown() - QTextDocumentWriter uses QTextMarkdownWriter if setFormat("markdown") is called or if the file suffix is .md or .mkd - Add QTextEdit::toMarkdown() and the markdown property [ChangeLog][QtGui][Text] Markdown (CommonMark or GitHub dialect) is now a supported format for reading into and writing from QTextDocument. Change-Id: I663a77017fac7ae1b3f9a400f5cd357bb40750af Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-04-291-1/+4
|\| | | | | | | | | | | Change-Id: Ic712e8a84b01b212bb1121d7a2c9b85e0d2da9da
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-281-1/+4
| |\| | | | | | | | | | Change-Id: Ibce9bfef928ce39070183c488ce86ae32e5ea705
| | * Fix page breaking with large imagesLars Knoll2019-04-261-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Don't go into an infinite loop breaking pages, when an image is about as large as the page. Correctly take top and bottom margins into account when calculating whether the image could fit on one page. Amends change 416b4cf685030114837bd375664fd12047895a62. Fixes: QTBUG-73730 Change-Id: Id311ddf05510be3b1d131702f4e17025a9861e58 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | QTextMarkdownImporter: insert list items into the correct listShawn Rutledge2019-04-271-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There was a bug when handling situations like 1. first 1) subfirst 2. second It was always inserting items into the list where the cursor already was, but it needs to insert the "second" list item into the list which is currently the top of m_listStack. Change-Id: Id0899032efafb2e2b9e7c45a6fb9f2c5221fc4df Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
* | | Fix -Wc++11-narrowing error in qtextmarkdownimporterMårten Nordheim2019-04-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | error: non-constant-expression cannot be narrowed from type 'qt::QFlags::Int' (aka 'int') to 'unsigned int' in initializer list [-Wc++11-narrowing] Change-Id: Ic634a98d29a108741d41955da1fbf2c986e4a943 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | | Add QTextMarkdownImporterShawn Rutledge2019-04-176-2/+629
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This provides the ability to read from a Markdown string or file into a QTextDocument, such that the formatting will be recognized and can be rendered. - Add QTextDocument::setMarkdown(QString) - Add QTextEdit::setMarkdown(QString) - Add TextFormat::MarkdownText - QWidgetTextControl::setContent() calls QTextDocument::setMarkdown() if that's the format Fixes: QTBUG-72349 Change-Id: Ief2ad71bf840666c64145d58e9ca71d05fad5659 Reviewed-by: Lisandro Damián Nicanor Pérez Meyer <perezmeyer@gmail.com> Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
* | | Revert "Fix font matching of typographic families on Windows"Eskil Abrahamsen Blomfeldt2019-04-093-20/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit bcd2fa484a4fe93e77743195d7f72cce9e580d43. There was a report that this caused infinite recursion on some systems, so we revert it for now and re-add it later when the issue has been resolved. Task-number: QTBUG-74983 Change-Id: I747e0437232d72d7a87eb602b10fa09c7130ce8f Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Replace Q_DECL_NOEXCEPT with noexcept in QtGuiAllan Sandfeld Jensen2019-04-0515-38/+38
| | | | | | | | | | | | | | | Change-Id: I43803b88fea8083782d73ce157c466b022208740 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Merge "Merge remote-tracking branch 'origin/5.13' into dev" into ↵Qt Forward Merge Bot2019-04-046-58/+75
|\ \ \ | | | | | | | | | | | | refs/staging/dev
| * | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-04-051-0/+23
| |\| | | | | | | | | | | | | | Change-Id: If4974bbf0a166de244dd57cb71b05fa28bcc34ce
| | * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-041-0/+23
| | |\| | | | | | | | | | | | | Change-Id: Ia7328524f2cd9d5995ac8705f0fe0bf570b2e831
| | | * Add a clarification about "characters" to QTextCursor docsEskil Abrahamsen Blomfeldt2019-04-021-0/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The function name QTextCursor::positionInBlock() may give users the idea that it can be displayed to the user as the visual position of the cursor in the current block. This becomes confusing with some writing systems, since e.g. a surrogate pair will count as two characters while only representing a single visual grapheme. Since it is an side effect of the encoding that will be unexpected to many, and since it also touches on some linguistic complexities, we add a note to the documentation to make users aware of the consideration needed. Task-number: QTBUG-74725 Change-Id: Iba28ba8a6ad07ee38dbb7e6a5a4b68c93d4da76a Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: René J.V. Bertin <rjvbertin@gmail.com> Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
| * | | Merge remote-tracking branch 'origin/5.13' into devLiang Qi2019-03-311-1/+1
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/configure.json Change-Id: I93ac67f3bf4844bc7c691183e94bceb922b7b919
| | * | Merge remote-tracking branch 'origin/5.12' into 5.13Friedemann Kleint2019-03-261-1/+1
| | |\| | | | | | | | | | | | | Change-Id: I71cc71881fb638e207d83a8733bad8f267701c0f
| | | * macOS: Don't scale advances to 0 when stretch is AnyStretchEskil Abrahamsen Blomfeldt2019-03-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the stretch is set to AnyStretch, then this is taken to mean we should accept the font as it is. But on mac, there is a special code path to scale the advances since the shaper doesn't do it for us, and this neglected to check the stretch, thus it would scale the advances by 0%. This happened when loading a file directly in QRawFont and using this in a QTextLayout, since no part of the code path will attempt to calculate the stretch in that case. Reproducible in q3dsviewer in Qt 3D Runtime 2.3. Task-number: QT3DS-3132 Change-Id: I8f934f3fac41bf7a93c01cca0416d44003119907 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * | | Use QScopedValueRollback more as a reentrancy guardAllan Sandfeld Jensen2019-03-263-12/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | It is documented for the use, but we were rarely using it. Change-Id: I812b9e6c8fbf204aba43ce2b79eca308ca75de88 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| * | | Merge remote-tracking branch 'origin/5.13' into devFriedemann Kleint2019-03-261-45/+36
| |\| | | | | | | | | | | | | | Change-Id: I38389a69411f4549fed432f1181dbe23398b34a2
| | * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-03-201-45/+36
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gui/kernel/qplatformintegration.cpp src/gui/kernel/qplatformintegration.h src/plugins/platforms/wasm/qwasmintegration.cpp src/plugins/platforms/xcb/qxcbconnection_screens.cpp Change-Id: I15063d42e9a1e226d9d2d2d372f75141b84c5c1b
| | | * Replace LDEBUG with categorized logging in QTextDocumentLayout(Private)Shawn Rutledge2019-03-181-45/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds four new logging categories: qt.text.drawing, qt.text.hittest, qt.text.layout and qt.text.layout.table Task-number: QTBUG-72457 Change-Id: Ifbfd6d16231c7f4ba664bc521699e44f98310f77 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | | Allow word break wrapping in Korean textEskil Abrahamsen Blomfeldt2019-04-041-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In Korean text, they typically can use both the "Western" style of word wrapping, i.e. breaking on spaces, as well as the East-Asian style of potentially breaking between all syllables. However, the Unicode Line Breaking Algorithm, TR14 defaults to breaks on syllables and specifies a possible tailoring where Hangul is mapped to the AL class instead: "When Korean uses SPACE for line breaking, the classes in rule LB26, as well as characters of class ID, are often tailored to AL" When using Qt, the user would expect the WordWrap wrap mode to break between words in Korean. If you want the syllable-based text layout, you would use WrapAnywhere, probably accompanied by line justification. To avoid breaking QTextBoundaryFinder and other potential clients of QUnicodeTools which depend on getting the precise Unicode data from the algorithm, we do this by passing a flag from QTextEngine when initializing the attributes. This way, it can also be made optional later on, if we decide there is a reason to add an additional wrap mode specifically to handle cases like this. [ChangeLog][Important Behavioral Change] WrapWord now correctly prefers line breaks between words in Korean text. WrapAnywhere can still be used to get breaks between syllables instead. Done-with: Alexey Turitsyn <alexey.turitsyn@lge.com> Task-number: QTBUG-47644 Change-Id: I37b45cea2995db7fc2b61e3a0cc681bbdc334678 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | | Fix font matching of typographic families on WindowsEskil Abrahamsen Blomfeldt2019-04-043-0/+20
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 9204b8c31ea1b5f0c05870c5b5d74c33b1a4f622 broke font matching on Windows. After this change, if you request a specific face of a family, such as "Arial Black", and Qt detects that its typographic/preferred name is "Arial", then it will be added as the single style of the Arial family, which will in turn be set as populated=true. So if you later request a regular font of "Arial" family, then it will see that the family has already been populated, skip this step, and then see that there is only one style available, i.e. "Arial Black". To work around this, we need to make sure the typographic family is properly populated the first time it is registered. [ChangeLog][Windows][Fonts] Fixed a bug where it would be impossible to request different faces of a font family after a specific type face has been in use. Task-number: QTBUG-74748 Change-Id: Ia0caace2b88a32e6114ff23ad10ee1ea8f5a3e03 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | More nullptr usage in headersKevin Funk2019-03-1415-44/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Diff generated by running clang-tidy's modernize-use-nullptr checker on the CMake-based Qt version. Skipping src/3rdparty, examples/, tests/ Change-Id: Ib182074e2e2fd52f63093f73b3e2e4c0cb7af188 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-03-091-1/+1
|\| | | | | | | | | | | Change-Id: I056b658ffe9390dfcbe2787e2bddc7f4e9b389dd
| * | Fix some qdoc warningsFriedemann Kleint2019-03-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | src/corelib/itemmodels/qtransposeproxymodel.cpp:166: (qdoc) warning: Unknown command '\details' src/corelib/itemmodels/qconcatenatetablesproxymodel.cpp:102: (qdoc) warning: '\brief' statement does not end with a full stop. src/corelib/itemmodels/qconcatenatetablesproxymodel.cpp:233: (qdoc) warning: Undocumented parameter 'index' in QConcatenateTablesProxyModel::flags() src/corelib/itemmodels/qconcatenatetablesproxymodel.cpp:165: (qdoc) warning: Undocumented parameter 'proxyIndex' in QConcatenateTablesProxyModel::mapToSource() src/corelib/io/qresource.cpp:275: (qdoc) warning: Can't link to 'isCopressed()' src/corelib/io/qresource.cpp:555: (qdoc) warning: Can't link to 'compressionType()' src/network/ssl/qocspresponse.cpp:47: (qdoc) warning: '\brief' statement does not end with a full stop. src/network/ssl/qocspresponse.cpp:47: (qdoc) warning: Can't link to 'QSslSocket::ocspResponse()' src/gui/image/qimage.cpp:2247: (qdoc) warning: Undocumented parameter 'f' in QImage::convertTo() src/gui/image/qimage.cpp:2247: (qdoc) warning: No such parameter 'format' in QImage::convertTo() src/gui/text/qtextformat.cpp:1420: (qdoc) warning: Undocumented parameter 'styleName' in QTextCharFormat::setFontStyleName() src/gui/text/qtextformat.cpp:1420: (qdoc) warning: No such parameter 'style' in QTextCharFormat::setFontStyleName() src/widgets/dialogs/qdialog.cpp:151: (qdoc) warning: Unknown command '\p' src/widgets/dialogs/qdialog.cpp:167: (qdoc) warning: Unknown command '\p' src/widgets/dialogs/qdialog.cpp:167: (qdoc) warning: Unknown command '\p' src/widgets/dialogs/qdialog.cpp:168: (qdoc) warning: Unknown command '\p' Change-Id: Ide52b70f8e72d53767d489ce1a413cf4c2dce7df Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-03-011-1/+1
|\| | | | | | | | | | | Change-Id: Icec0aa703d8a13efa9f1634a1a353eb9d63685c8
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-02-281-1/+1
| |\| | | | | | | | | | Change-Id: Icc9b061c56e969756f0351c936cdeb8063c86079
| | * QSyntaxHighlighter: Fix crash when parent is a nullptrDominik Haumann2019-02-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QSyntaxHighlighter has the follwoing constructor taking a QObject QSyntaxHighlighter::QSyntaxHighlighter(QObject *parent) : QObject(*new QSyntaxHighlighterPrivate, parent) { if (parent->inherits("QTextEdit")) { // ... } } Typically, a 'parent' refers to the parent/child hierarchy in Qt and is allowed to be a nullptr. However, in this case, passing a nullptr will lead to a crash, as reported in https://bugs.kde.org/show_bug.cgi?id=404820 This patch makes the QSyntaxHighlighter constructor nullptr safe by checking if parent is a valid pointer. Change-Id: Ia4e9b46b94fd37e6ceb2cd0538594353fdc1e349 Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io> Reviewed-by: Christoph Cullmann <cullmann@kde.org>
* | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-02-272-3/+3
|\| | | | | | | | | | | Change-Id: I14eaabe98845445a9ea5266872cc1797786cfe04
| * | Fix can not -> cannotRobert Loehning2019-02-252-3/+3
| | | | | | | | | | | | | | | Change-Id: Ie9992f67ca59aff662a4be046ace08640e7c2714 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-02-221-2/+2
|\| | | | | | | | | | | Change-Id: I4b56ce8c76729d9fc60995564299f8f27336fcde
| * | QtGui/Network/OpenGl/Widgets/Xml: use \nullptr in documentationChristian Ehrlicher2019-02-201-2/+2
| | | | | | | | | | | | | | | | | | | | | Replace null and '\c nullptr' with \nullptr in the documentation. Change-Id: I58934eea06943309ba895833f1991629870ab45b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-02-2013-53/+79
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: tests/auto/widgets/itemviews/qheaderview/tst_qheaderview.cpp Added tests/auto/testlib/selftests/expected_crashes_5.txt to work round the output of the crashes test (which exercises UB, see QTBUG-73903) being truncated on one test platform. Change-Id: I9cd3f2639b4e50c3c4513e14629a40bdca8f8273
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-02-151-1/+2
| |\| | | | | | | | | | Change-Id: I8cad26f17834dbc9f7151edc0f17786f9e32025d