5#include <QtCore/qregularexpression.h>
23 startMark.prepend(
"$$$"_L1);
67 if (shouldSkipFirstParagraph)
76 skipFirstParagraphIfNeeded(
index);
122 const auto tailToRemove =
"More..."_L1;
123 const auto lastIndex =
result.lastIndexOf(tailToRemove);
125 result.remove(lastIndex, tailToRemove.length());
131 const auto headerToRemove =
"Detailed Description"_L1;
132 const auto firstIndex =
result.indexOf(headerToRemove);
133 if (firstIndex != -1)
134 result.remove(firstIndex, headerToRemove.length());
147 if (startIndex == -1) {
150 "<td class=\"tblQmlPropNode\"><p>\n<span class=\"name\">%1</span>")
152 startIndex = code.
indexOf(startMark);
153 if (startIndex == -1)
159 if (startIndex == -1)
174 if (startIndex != -1) {
175 startIndex = code.
indexOf(
"-->"_L1, startIndex + mark.
length());
176 if (startIndex == -1)
182 startIndex = code.
indexOf(mark);
183 if (startIndex != -1)
184 startIndex += mark.
length();
190 if (startIndex == -1)
206 case DomType::QmlObject:
207 m_extractor = std::make_unique<ExtractQmlType>();
209 case DomType::PropertyDefinition:
210 m_extractor = std::make_unique<ExtractQmlProperty>();
212 case DomType::MethodInfo:
213 m_extractor = std::make_unique<ExtractQmlMethodOrSignal>();
223 return m_extractor->extract(code, keyword,
mode);
\inmodule QtCore \reentrant
\macro QT_RESTRICTED_CAST_FROM_ASCII
qsizetype indexOf(QLatin1StringView s, qsizetype from=0, Qt::CaseSensitivity cs=Qt::CaseSensitive) const
qsizetype lastIndexOf(QChar c, Qt::CaseSensitivity cs=Qt::CaseSensitive) const noexcept
static QString fromLatin1(QByteArrayView ba)
This is an overloaded member function, provided for convenience. It differs from the above function o...
void truncate(qsizetype pos)
Truncates the string at the given position index.
QString mid(qsizetype position, qsizetype n=-1) const &
bool isEmpty() const noexcept
Returns true if the string has no characters; otherwise returns false.
void clear()
Clears the contents of the string and makes it null.
QString & append(QChar c)
QString & remove(qsizetype i, qsizetype len)
Removes n characters from the string, starting at the given position index, and returns a reference t...
QString & prepend(QChar c)
qsizetype length() const noexcept
Returns the number of characters in this string.
Combined button and popup list for selecting options.
static constexpr auto lengthOfSmallestOpeningTag
static constexpr auto lengthOfEndParagraphTag
static constexpr auto lengthOfStartParagraphTag
static constexpr auto lengthOfPeriod
static constexpr qsizetype firstIndexOfParagraphTag
static void processOutput(QString *html)
Process the string obtained from start mark to end mark. This is duplicated from QtC's Utils::HtmlExt...
static void stripAllHtml(QString *html)
static QString getContentsByMarks(const QString &html, QString startMark, QString endMark)
QLatin1StringView QLatin1String
\inmodule QtCore \reentrant