Changeset View
Changeset View
Standalone View
Standalone View
libs/textlayout/KoTextLayoutNoteArea.cpp
Show First 20 Lines • Show All 132 Lines • ▼ Show 20 Line(s) | 84 | { | |||
---|---|---|---|---|---|
133 | } | 133 | } | ||
134 | d->labelIndent += pStyle.leftMargin(); | 134 | d->labelIndent += pStyle.leftMargin(); | ||
135 | d->labelWidth = line.naturalTextWidth(); | 135 | d->labelWidth = line.naturalTextWidth(); | ||
136 | d->labelHeight = line.naturalTextRect().bottom() - line.naturalTextRect().top(); | 136 | d->labelHeight = line.naturalTextRect().bottom() - line.naturalTextRect().top(); | ||
137 | d->labelYOffset = -line.ascent(); | 137 | d->labelYOffset = -line.ascent(); | ||
138 | 138 | | |||
139 | bool contNotNeeded = KoTextLayoutArea::layout(cursor); | 139 | bool contNotNeeded = KoTextLayoutArea::layout(cursor); | ||
140 | 140 | | |||
141 | d->labelYOffset += block.layout()->lineAt(0).ascent(); | 141 | QTextLine blockLayoutLine = block.layout()->lineAt(0); | ||
142 | | ||||
143 | if (blockLayoutLine.isValid()) { | ||||
boemann: I'm fine with this change | |||||
144 | d->labelYOffset += blockLayoutLine.ascent(); | ||||
145 | } | ||||
142 | 146 | | |||
143 | if (!contNotNeeded) { | 147 | if (!contNotNeeded) { | ||
144 | QString contNote = notesConfig->footnoteContinuationForward(); | 148 | QString contNote = notesConfig->footnoteContinuationForward(); | ||
145 | font.setBold(true); | 149 | font.setBold(true); | ||
146 | d->postLayout = new QTextLayout(contNote, font, pd); | 150 | d->postLayout = new QTextLayout(contNote, font, pd); | ||
147 | QList<QTextLayout::FormatRange> contTextLayouts; | 151 | QList<QTextLayout::FormatRange> contTextLayouts; | ||
148 | QTextLayout::FormatRange contTextRange; | 152 | QTextLayout::FormatRange contTextRange; | ||
149 | contTextRange.start = 0; | 153 | contTextRange.start = 0; | ||
▲ Show 20 Lines • Show All 47 Lines • Show Last 20 Lines |
I'm fine with this change