introduced idea.register.bundled.fonts registry to be able to switch off bundled fonts registration in order to avoid garbled text in editor (IDEA-93404) [r=Konstantin.Bulenkov]

This commit is contained in:
Maxim.Mossienko
2013-11-28 17:29:39 +01:00
parent f3e71c627c
commit e2cdb6df51
2 changed files with 8 additions and 3 deletions
@@ -25,6 +25,7 @@ import com.intellij.openapi.project.Project;
import com.intellij.openapi.ui.popup.Balloon;
import com.intellij.openapi.util.Condition;
import com.intellij.openapi.util.SystemInfo;
import com.intellij.openapi.util.registry.Registry;
import com.intellij.openapi.util.text.StringUtil;
import com.intellij.openapi.wm.ToolWindowManager;
import com.intellij.util.PlatformUtils;
@@ -123,9 +124,11 @@ public class AppUIUtil {
}
public static void registerBundledFonts() {
registerFont("/fonts/Inconsolata.ttf");
registerFont("/fonts/SourceCodePro-Regular.ttf");
registerFont("/fonts/SourceCodePro-Bold.ttf");
if (Registry.is("ide.register.bundled.fonts")) {
registerFont("/fonts/Inconsolata.ttf");
registerFont("/fonts/SourceCodePro-Regular.ttf");
registerFont("/fonts/SourceCodePro-Bold.ttf");
}
}
private static void registerFont(@NonNls String name) {
@@ -107,6 +107,8 @@ ide.tooltip.autoDismissDeadZone=300
ide.balloon.shadowEnabled=true
ide.balloon.shadow.size=15
ide.expansion.hints.enabled=true
ide.register.bundled.fonts=true
ide.register.bundled.fonts.description=Disables automatic registration of bundled fonts: SourceCodePro, Inconsolata
editor.balloonHints=true
editor.mouseSelectionStateResetTimeout=1000