Merge branch 'subtree'
[fanfix.git] / src / jexer / TScrollableWindow.java
index c5f122bb024977f9a2017cca62c903041dbf5b9f..1e260b3f86e00c7a7cc07409e28e0e1aa646fe03 100644 (file)
@@ -3,7 +3,7 @@
  *
  * The MIT License (MIT)
  *
- * Copyright (C) 2017 Kevin Lamonte
+ * Copyright (C) 2019 Kevin Lamonte
  *
  * Permission is hereby granted, free of charge, to any person obtaining a
  * copy of this software and associated documentation files (the "Software"),
@@ -166,6 +166,7 @@ public class TScrollableWindow extends TWindow implements Scrollable {
      */
     protected void placeScrollbars() {
         if (hScroller != null) {
+            hScroller.setX(Math.min(Math.max(0, getWidth() - 17), 17));
             hScroller.setY(getHeight() - 2);
             hScroller.setWidth(getWidth() - hScroller.getX() - 3);
             hScroller.setBigChange(getWidth() - hScroller.getX() - 3);