@@ -423,10 +423,10 @@ public final ScrollBar getVerticalScrollBar() {
423423 double minWidth = vsbWidth + snappedLeftInset () + snappedRightInset ();
424424
425425 if (sp .getPrefViewportWidth () > 0 ) {
426- return (sp .getPrefViewportWidth () + minWidth );
426+ return snapSpaceX (sp .getPrefViewportWidth () + minWidth );
427427 }
428428 else if (sp .getContent () != null ) {
429- return (sp .getContent ().prefWidth (height ) + minWidth );
429+ return snapSpaceX (sp .getContent ().prefWidth (height ) + minWidth );
430430 }
431431 else {
432432 return Math .max (minWidth , DEFAULT_PREF_SIZE );
@@ -441,10 +441,10 @@ else if (sp.getContent() != null) {
441441 double minHeight = hsbHeight + snappedTopInset () + snappedBottomInset ();
442442
443443 if (sp .getPrefViewportHeight () > 0 ) {
444- return (sp .getPrefViewportHeight () + minHeight );
444+ return snapSpaceY (sp .getPrefViewportHeight () + minHeight );
445445 }
446446 else if (sp .getContent () != null ) {
447- return (sp .getContent ().prefHeight (width ) + minHeight );
447+ return snapSpaceY (sp .getContent ().prefHeight (width ) + minHeight );
448448 }
449449 else {
450450 return Math .max (minHeight , DEFAULT_PREF_SIZE );
@@ -459,7 +459,7 @@ else if (sp.getContent() != null) {
459459 double minWidth = vsbWidth + snappedLeftInset () + snappedRightInset ();
460460
461461 if (sp .getMinViewportWidth () > 0 ) {
462- return (sp .getMinViewportWidth () + minWidth );
462+ return snapSpaceX (sp .getMinViewportWidth () + minWidth );
463463 } else {
464464 double w = corner .minWidth (-1 );
465465 return (w > 0 ) ? (3 * w ) : (DEFAULT_MIN_SIZE );
@@ -475,7 +475,7 @@ else if (sp.getContent() != null) {
475475 double minHeight = hsbHeight + snappedTopInset () + snappedBottomInset ();
476476
477477 if (sp .getMinViewportHeight () > 0 ) {
478- return (sp .getMinViewportHeight () + minHeight );
478+ return snapSpaceY (sp .getMinViewportHeight () + minHeight );
479479 } else {
480480 double h = corner .minHeight (-1 );
481481 return (h > 0 ) ? (3 * h ) : (DEFAULT_MIN_SIZE );
0 commit comments