本文整理匯總了Java中com.intellij.ide.ui.laf.darcula.DarculaInstaller.uninstall方法的典型用法代碼示例。如果您正苦於以下問題:Java DarculaInstaller.uninstall方法的具體用法?Java DarculaInstaller.uninstall怎麽用?Java DarculaInstaller.uninstall使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.intellij.ide.ui.laf.darcula.DarculaInstaller
的用法示例。
在下文中一共展示了DarculaInstaller.uninstall方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: removeTheme
import com.intellij.ide.ui.laf.darcula.DarculaInstaller; //導入方法依賴的package包/類
/**
* Completely remove theme
*
* @param mtTheme
*/
private void removeTheme(final MTThemes mtTheme) {
try {
resetContrast();
if (UIUtil.isUnderDarcula()) {
UIManager.setLookAndFeel(new DarculaLaf());
} else {
UIManager.setLookAndFeel(new IntelliJLaf());
}
JBColor.setDark(mtTheme.isDark());
IconLoader.setUseDarkIcons(mtTheme.isDark());
PropertiesComponent.getInstance().unsetValue(getSettingsPrefix() + ".theme");
// We need this to update parts of the UI that do not change
if (UIUtil.isUnderDarcula()) {
DarculaInstaller.uninstall();
DarculaInstaller.install();
} else {
DarculaInstaller.uninstall();
}
} catch (final UnsupportedLookAndFeelException e) {
e.printStackTrace();
}
}
示例2: initComponent
import com.intellij.ide.ui.laf.darcula.DarculaInstaller; //導入方法依賴的package包/類
@Override
public void initComponent() {
if (myCurrentLaf != null) {
final UIManager.LookAndFeelInfo laf = findLaf(myCurrentLaf.getClassName());
if (laf != null) {
boolean needUninstall = UIUtil.isUnderDarcula();
setCurrentLookAndFeel(laf); // setup default LAF or one specified by readExternal.
if (WelcomeWizardUtil.getWizardLAF() != null) {
if (UIUtil.isUnderDarcula()) {
DarculaInstaller.install();
}
else if (needUninstall) {
DarculaInstaller.uninstall();
}
}
}
}
updateUI();
if (SystemInfo.isXWindow) {
myThemeChangeListener = new PropertyChangeListener() {
@Override
public void propertyChange(final PropertyChangeEvent evt) {
//noinspection SSBasedInspection
SwingUtilities.invokeLater(new Runnable() {
@Override
public void run() {
fixGtkPopupStyle();
patchGtkDefaults(UIManager.getLookAndFeelDefaults());
}
});
}
};
Toolkit.getDefaultToolkit().addPropertyChangeListener(GNOME_THEME_PROPERTY_NAME, myThemeChangeListener);
}
}
示例3: commitStep
import com.intellij.ide.ui.laf.darcula.DarculaInstaller; //導入方法依賴的package包/類
@Override
public boolean commitStep() {
// This code is duplicated from LafManager.initComponent(). But our Welcome Wizard is started
// AFTER that call so we repeat it here.
if (UIUtil.isUnderDarcula()) {
DarculaInstaller.install();
}
else {
DarculaInstaller.uninstall();
}
return super.commitStep();
}
示例4: reloadUI
import com.intellij.ide.ui.laf.darcula.DarculaInstaller; //導入方法依賴的package包/類
/**
* Trigger a reloadUI event
*
* @param mtTheme
*/
private void reloadUI(final MTTheme mtTheme) {
try {
UIManager.setLookAndFeel(new MTLaf(MTConfig.getInstance().getSelectedTheme().getTheme()));
applyFonts();
DarculaInstaller.uninstall();
if (UIUtil.isUnderDarcula()) {
DarculaInstaller.install();
}
} catch (final UnsupportedLookAndFeelException e) {
e.printStackTrace();
}
}
示例5: activate
import com.intellij.ide.ui.laf.darcula.DarculaInstaller; //導入方法依賴的package包/類
/**
* Activate theme
*
* @param mtTheme
*/
public void activate(final MTThemes mtTheme, final boolean switchColorScheme) {
MTThemes newTheme = mtTheme;
if (newTheme == null) {
newTheme = MTThemes.OCEANIC;
}
MTConfig.getInstance().setSelectedTheme(newTheme);
newTheme.getTheme().activate();
switchScheme(newTheme, switchColorScheme);
// Because the DarculaInstaller overrides this
final EditorColorsScheme currentScheme = EditorColorsManager.getInstance().getGlobalScheme();
PropertiesComponent.getInstance().setValue(getSettingsPrefix() + ".theme", newTheme.getId());
applyContrast(false);
applyCompactSidebar(false);
applyCustomTreeIndent();
applyAccents(false);
setBoldTabs();
// We need this to update parts of the UI that do not change
if (UIUtil.isUnderDarcula()) {
DarculaInstaller.uninstall();
DarculaInstaller.install();
} else {
DarculaInstaller.uninstall();
}
LafManager.getInstance().updateUI();
// Because the DarculaInstaller overrides this
EditorColorsManager.getInstance().setGlobalScheme(currentScheme);
applyFonts();
// Documentation styles
patchStyledEditorKit();
UIReplacer.patchUI();
}