void (@NotNull Graphics g, int x, int width, int height, boolean active, boolean toolWindow, boolean drawTopLine, boolean drawBottomLine) { GraphicsConfig config = GraphicsUtil.disableAAPainting(g); try { g.setColor(JBUI.CurrentTheme.ToolWindow.headerBackground(active)); g.fillRect(x, 0, width, height); g.setColor(JBUI.CurrentTheme.ToolWindow.headerBorderBackground()); if (drawTopLine) LinePainter2D.paint((Graphics2D)g, x, 0, width, 0); if (drawBottomLine) LinePainter2D.paint((Graphics2D)g, x, height - 1, width, height - 1); } finally { config.restore(); } }