Fix whitespace and indentation errors.

This commit is contained in:
John Preston 2020-01-02 14:25:11 +03:00
parent 765e525458
commit d30d361609

View file

@ -117,19 +117,19 @@ bool ComputeCheckTilde(const style::TextStyle &st) {
bool chIsBad(QChar ch) {
return (ch == 0)
|| (ch >= 8232 && ch < 8237)
|| (ch >= 65024 && ch < 65040 && ch != 65039)
|| (ch >= 127 && ch < 160 && ch != 156)
|| (ch >= 8232 && ch < 8237)
|| (ch >= 65024 && ch < 65040 && ch != 65039)
|| (ch >= 127 && ch < 160 && ch != 156)
// qt harfbuzz crash see https://github.com/telegramdesktop/tdesktop/issues/4551
|| (Platform::IsMac() && ch == 6158)
// qt harfbuzz crash see https://github.com/telegramdesktop/tdesktop/issues/4551
|| (Platform::IsMac() && ch == 6158)
// tmp hack see https://bugreports.qt.io/browse/QTBUG-48910
// tmp hack see https://bugreports.qt.io/browse/QTBUG-48910
|| (Platform::IsMac10_11OrGreater()
&& !Platform::IsMac10_12OrGreater()
&& ch >= 0x0B00
&& ch <= 0x0B7F
&& chIsDiac(ch));
&& ch <= 0x0B7F
&& chIsDiac(ch));
}
QString textcmdSkipBlock(ushort w, ushort h) {
@ -1518,7 +1518,7 @@ private:
eShapeLine(line);
int firstItem = engine.findItem(line.from), lastItem = engine.findItem(line.from + line.length - 1);
int nItems = (firstItem >= 0 && lastItem >= firstItem) ? (lastItem - firstItem + 1) : 0;
int nItems = (firstItem >= 0 && lastItem >= firstItem) ? (lastItem - firstItem + 1) : 0;
if (!nItems) {
return true;
}
@ -1545,7 +1545,7 @@ private:
}
}
}
QTextEngine::bidiReorder(nItems, levels.data(), visualOrder.data());
QTextEngine::bidiReorder(nItems, levels.data(), visualOrder.data());
if (style::RightToLeft() && skipIndex == nItems - 1) {
for (int32 i = nItems; i > 1;) {
--i;
@ -1870,7 +1870,7 @@ private:
_wLeft = _w - elideWidth - _elideRemoveFromEnd;
int firstItem = engine.findItem(line.from), lastItem = engine.findItem(line.from + line.length - 1);
int nItems = (firstItem >= 0 && lastItem >= firstItem) ? (lastItem - firstItem + 1) : 0, i;
int nItems = (firstItem >= 0 && lastItem >= firstItem) ? (lastItem - firstItem + 1) : 0, i;
for (i = 0; i < nItems; ++i) {
QScriptItem &si(engine.layoutData->items[firstItem + i]);