From 58ca60481d7ed46153a780638e6d096ccd2c8b7c Mon Sep 17 00:00:00 2001 From: Evgeny Zakrevsky Date: Wed, 17 Aug 2011 21:35:55 +0400 Subject: [PATCH] IdeBorderFactory. Insets around plain border made larger --- .../src/com/intellij/ui/IdeBorderFactory.java | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/platform/platform-api/src/com/intellij/ui/IdeBorderFactory.java b/platform/platform-api/src/com/intellij/ui/IdeBorderFactory.java index bdf362c0693e..96633c610ccf 100644 --- a/platform/platform-api/src/com/intellij/ui/IdeBorderFactory.java +++ b/platform/platform-api/src/com/intellij/ui/IdeBorderFactory.java @@ -60,10 +60,16 @@ public class IdeBorderFactory { public static IdeaTitledBorder createTitledBorder(String title, boolean hasBoldFont, boolean hasIndent, boolean hasSmallFont) { Font font = UIUtil.getBorderFont(hasSmallFont ? UIUtil.FontSize.SMALL : UIUtil.FontSize.NORMAL, hasBoldFont); int indent = hasIndent ? (hasBoldFont ? 18 : 15) : 0; - Insets insets = hasBoldFont ? new Insets(5, 0, 10, 0) : new Insets(3, 0, 6, 0); + Insets insets = new Insets(5, 0, 10, 0); return new IdeaTitledBorder(title, font, UIUtil.getBorderColor(), indent, 1, insets); } + public static IdeaTitledBorder createTitledBorder(String title, boolean hasBoldFont, boolean hasIndent, boolean hasSmallFont, Insets insets) { + Font font = UIUtil.getBorderFont(hasSmallFont ? UIUtil.FontSize.SMALL : UIUtil.FontSize.NORMAL, hasBoldFont); + int indent = hasIndent ? (hasBoldFont ? 18 : 15) : 0; + return new IdeaTitledBorder(title, font, UIUtil.getBorderColor(), indent, 1, insets); + } + @Deprecated // Don't remove, used in TeamCity plugin. public static TitledBorder createTitledHeaderBorder(String title) {