Пример #1
0
 @Override
 public void setArea(Rectangle area) {
   super.setArea(padding.include(border).apply(area));
 }
Пример #2
0
 @Override
 public void draw(Graphics graphics) {
   background.ifPresent(graphics::fillBackground);
   graphics.drawBorder(border);
   super.draw(graphics.restrict(padding.include(border).apply(graphics.getArea().getDimension())));
 }