示例#1
0
文件: Panel.java 项目: rideg/jtext
 @Override
 public void setArea(Rectangle area) {
   super.setArea(padding.include(border).apply(area));
 }
示例#2
0
文件: Panel.java 项目: rideg/jtext
 @Override
 public void draw(Graphics graphics) {
   background.ifPresent(graphics::fillBackground);
   graphics.drawBorder(border);
   super.draw(graphics.restrict(padding.include(border).apply(graphics.getArea().getDimension())));
 }