IDEA-91339 Darcula: "No files are open" looks weird

This commit is contained in:
Konstantin Bulenkov
2012-09-11 17:36:03 +04:00
parent 57c79a2ed9
commit 750100414d
2 changed files with 7 additions and 5 deletions
@@ -151,11 +151,11 @@ public class EditorsSplitters extends JPanel {
if (showEmptyText()) {
UIUtil.applyRenderingHints(g);
g.setColor(Gray._100);
g.setColor(UIUtil.isUnderDarcula() ? Gray._200: Gray._100);
g.setFont(UIUtil.getLabelFont().deriveFont(18f));
final UIUtil.TextPainter painter = new UIUtil.TextPainter().withShadow(true).withLineSpacing(1.4f);
painter.appendLine("No files are open").underlined(Gray._150);
painter.appendLine("No files are open").underlined(UIUtil.isUnderDarcula() ? Gray._220 : Gray._150);
if (!isProjectViewVisible()) {
painter.appendLine("Open Project View with " + KeymapUtil.getShortcutText(new KeyboardShortcut(
@@ -2160,7 +2160,7 @@ public class UIUtil {
public TextPainter() {
myDrawShadow = isUnderAquaLookAndFeel();
myShadowColor = Gray._220;
myShadowColor = isUnderDarcula() ? Gray._0 : Gray._220;
myLineSpacing = 1.0f;
}
@@ -2287,14 +2287,16 @@ public class UIUtil {
}
if (myDrawShadow) {
int xOff = isUnderDarcula() ? 1 : 0;
int yOff = 1;
final Color oldColor = g.getColor();
g.setColor(myShadowColor);
if (info.withBullet) {
g.drawString(info.bulletChar + " ", x - fm.stringWidth(" " + info.bulletChar), yOffset[0] + 1);
g.drawString(info.bulletChar + " ", x - fm.stringWidth(" " + info.bulletChar) + xOff, yOffset[0] + yOff);
}
g.drawString(pair.getFirst(), xOffset, yOffset[0] + 1);
g.drawString(pair.getFirst(), xOffset + xOff, yOffset[0] + yOff);
g.setColor(oldColor);
}