fix: can't show info tips if the first line contains errors
This commit is contained in:
parent
91b8695b6e
commit
d76ef859c5
|
@ -2030,6 +2030,7 @@ void Editor::onTooltipTimer()
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
// Get subject
|
||||
bool isIncludeLine = false;
|
||||
bool isIncludeNextLine = false;
|
||||
|
|
|
@ -588,8 +588,7 @@ bool QSynEdit::pointToLine(const QPoint &point, int &line)
|
|||
|| (point.y() > clientTop()+clientHeight())) {
|
||||
return false;
|
||||
}
|
||||
line = rowToLine(
|
||||
yposToRow(point.y() / mTextHeight));
|
||||
line = rowToLine(yposToRow(point.y()));
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -718,8 +717,7 @@ BufferCoord QSynEdit::displayToBufferPos(const DisplayCoord &p) const
|
|||
if (p.row<1)
|
||||
return result;
|
||||
// Account for code folding
|
||||
if (useCodeFolding())
|
||||
result.line = foldRowToLine(p.row);
|
||||
result.line = rowToLine(p.row);
|
||||
// Account for tabs
|
||||
if (result.line <= mDocument->count() ) {
|
||||
result.ch = xposToGlyphStartChar(result.line,p.x);
|
||||
|
|
Loading…
Reference in New Issue