import com.intellij.openapi.application.impl.ApplicationInfoImpl;
import com.intellij.openapi.util.IconLoader;
+import com.intellij.openapi.wm.impl.content.GraphicsConfig;
import com.intellij.util.ui.UIUtil;
import javax.swing.*;
public static boolean showLicenseeInfo(Graphics g, int x, int y, final int height, final Color textColor) {
if (ApplicationInfoImpl.getShadowInstance().showLicenseeInfo()) {
+ GraphicsConfig config = new GraphicsConfig(g);
+ config.setAntialiasing(true);
g.setFont(new Font(UIUtil.ARIAL_FONT_NAME, Font.BOLD, 11));
g.setColor(textColor);
LicenseeInfoProvider provider = LicenseeInfoProvider.getInstance();
g.drawString(licensedToMessage, x + 20, y + height - 52);
g.drawString(licenseRestrictionsMessage, x + 20, y + height - 32);
}
+ config.restore();
return true;
}
return false;
}
public void paintIcon(Component c, Graphics g, int x, int y) {
- yeild();
+ yield();
myOriginalIcon.paintIcon(c, g, x, y);
showLicenseeInfo(g, x, y, getIconHeight(), myTextColor);
}
- private static void yeild() {
+ private static void yield() {
try {
Thread.sleep(10);
}
- catch (InterruptedException e) {
+ catch (InterruptedException ignore) {
}
}