mirror of
https://gitee.com/vnotex/vnote.git
synced 2025-07-05 13:59:52 +08:00
TextDocumentLayout: add debug info to investigate the crash
This commit is contained in:
parent
f7ba98f3bb
commit
a12f01e617
@ -140,6 +140,12 @@ void VTextDocumentLayout::blockRangeFromRectBS(const QRectF &p_rect,
|
||||
p_last = document()->blockCount() - 1;
|
||||
while (block.isValid()) {
|
||||
const BlockLayoutInfo *tinfo = VTextBlockData::layoutInfo(block);
|
||||
if (!tinfo->hasOffset()) {
|
||||
qWarning() << "block without offset"
|
||||
<< block.blockNumber() << tinfo->m_offset
|
||||
<< tinfo->m_rect << tinfo->m_rect.isNull();
|
||||
}
|
||||
|
||||
V_ASSERT(tinfo->hasOffset());
|
||||
|
||||
if (tinfo->bottom() > y) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user