forked from qt-creator/qt-creator
Re-introduction of the feature to adjust the line spacing
This already has been implemented in changedc64f3207b, but was reverted with changef220cb0e23) because this does not work with text wrapping rendering, due to internal limitations of Qt. Since this is a highly requested feature (e.g. QTCREATORBUG-13727), but an internal change within Qt is not in sight, the approach taken here is to offer the text wrapping feature in the settings only when the line spacing is set to 100%. Additionally, a change has been made to the layout of the display settings page to reflect this. Fixes: QTCREATORBUG-13727 Change-Id: Ib233cf90a5f336bc591fa1bf860e162fa774dfe3 Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
@@ -306,7 +306,7 @@ private:
|
||||
{
|
||||
QTextCursor tc = m_editor->textCursor();
|
||||
m_currentPos = tc.position();
|
||||
m_lineSpacing = m_editor->cursorRect(tc).height();
|
||||
m_lineSpacing = m_editor->document()->documentLayout()->blockBoundingRect(tc.block()).height();
|
||||
setFont(m_editor->extraArea()->font());
|
||||
|
||||
// Follow geometry of normal line numbers if visible,
|
||||
|
||||
Reference in New Issue
Block a user