]> git.lyx.org Git - lyx.git/blobdiff - src/TextMetrics.cpp
Nullptr warnings
[lyx.git] / src / TextMetrics.cpp
index 65a1aa7945eaebac5eebc0ffb0615a3dcc64f3fd..796e1bd25ec949f3c50a229f8ae33b93d5f75c8a 100644 (file)
@@ -1933,9 +1933,9 @@ void TextMetrics::drawParagraph(PainterInfo & pi, pit_type const pit, int const
                        // the begining/end of row. However, it will not work if
                        // the caret has a ridiculous width like 6. (see ticket
                        // #10797)
-                       pi.pain.fillRectangle(max(row_x, 0) - Inset::TEXT_TO_INSET_OFFSET,
+                       pi.pain.fillRectangle(max(row_x, 0) - Inset::textOffset(pi.base.bv),
                                              y - row.ascent(),
-                                             width() + 2 * Inset::TEXT_TO_INSET_OFFSET,
+                                             width() + 2 * Inset::textOffset(pi.base.bv),
                                              row.height(), pi.background_color);
                }