Skip to content

Commit c6ee8f1

Browse files
authored
Merge pull request #810 from csmith/master
Fix height paragraph box height calculation
2 parents 94a7ee7 + 75577f9 commit c6ee8f1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

richtextfx/src/main/java/org/fxmisc/richtext/ParagraphBox.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -228,7 +228,7 @@ protected double computePrefWidth(double ignoredHeight) {
228228
@Override
229229
protected double computePrefHeight(double width) {
230230
Insets insets = getInsets();
231-
double overhead = getGraphicPrefWidth() - insets.getLeft() - insets.getRight();
231+
double overhead = getGraphicPrefWidth() + insets.getLeft() + insets.getRight();
232232
return text.prefHeight(width - overhead) + insets.getTop() + insets.getBottom();
233233
}
234234

0 commit comments

Comments
 (0)