当前位置: 首页>>代码示例>>Java>>正文


Java FontRegistry.getBold方法代码示例

本文整理汇总了Java中org.eclipse.jface.resource.FontRegistry.getBold方法的典型用法代码示例。如果您正苦于以下问题:Java FontRegistry.getBold方法的具体用法?Java FontRegistry.getBold怎么用?Java FontRegistry.getBold使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.eclipse.jface.resource.FontRegistry的用法示例。


在下文中一共展示了FontRegistry.getBold方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: populateTree

import org.eclipse.jface.resource.FontRegistry; //导入方法依赖的package包/类
protected void populateTree(Map<String, List<UpgradeConflict>> upgradeConflicts) {
    TreeSet<String> sortedComponentTypes = new TreeSet<>();
    sortedComponentTypes.addAll(upgradeConflicts.keySet());

    // loop thru sorted list creating upgrade component tree
    for (String componentType : sortedComponentTypes) {
        // create root component type node
        TreeItem componentTypeTreeItem = new TreeItem(getTreeComponentConflicts(), SWT.NONE);
        componentTypeTreeItem.setText(componentType);
        FontRegistry registry = new FontRegistry();
        Font boldFont = registry.getBold(Display.getCurrent().getSystemFont().getFontData()[0].getName());

        componentTypeTreeItem.setFont(boldFont);
        componentTypeTreeItem.setExpanded(true);

        // loop thru each component instance and create named node
        List<UpgradeConflict> upgradeComponents = upgradeConflicts.get(componentType);
        for (UpgradeConflict upgradeConflict : upgradeComponents) {
            TreeItem componentTreeItem = new TreeItem(componentTypeTreeItem, SWT.NONE);
            componentTreeItem.setText(upgradeConflict.getLocalComponent().getFileName());
            componentTreeItem.setForeground(Display.getCurrent().getSystemColor(SWT.COLOR_BLUE));
            componentTreeItem.setData("local", upgradeConflict.getLocalComponent());
            componentTreeItem.setData("remote", upgradeConflict.getRemoteComponent());
            componentTreeItem.setExpanded(true);
        }
    }
}
 
开发者ID:forcedotcom,项目名称:idecore,代码行数:28,代码来源:UpgradeComponentConflictsComposite.java

示例2: updateSummaryLabel

import org.eclipse.jface.resource.FontRegistry; //导入方法依赖的package包/类
public void updateSummaryLabel(int candidateCnt, String orgUserName) {
    if (lblSummary != null) {
        lblSummary.setText("Found " + candidateCnt + " deployment candidates");
        FontRegistry registry = new FontRegistry();
        Font boldFont = registry.getBold(Display.getCurrent().getSystemFont().getFontData()[0].getName());
        lblSummary.setFont(boldFont);
        lblSummary.update();
    }
}
 
开发者ID:forcedotcom,项目名称:idecore,代码行数:10,代码来源:DeploymentPlanComposite.java

示例3: initFonts

import org.eclipse.jface.resource.FontRegistry; //导入方法依赖的package包/类
private void initFonts()
{
	FontData[] fontData = Display.getCurrent().getSystemFont().getFontData();
	String fontName = fontData[0].getName();
	FontRegistry registry = JFaceResources.getFontRegistry();
	boldFont = registry.getBold(fontName);
}
 
开发者ID:opcoach,项目名称:E34MigrationTooling,代码行数:8,代码来源:PluginDataProvider.java

示例4: getBoldFont

import org.eclipse.jface.resource.FontRegistry; //导入方法依赖的package包/类
protected Font getBoldFont() {
    final FontRegistry reg = JFaceResources.getFontRegistry();
    return reg.getBold(JFaceResources.DEFAULT_FONT);
}
 
开发者ID:insweat,项目名称:hssd,代码行数:5,代码来源:LPHelper.java


注:本文中的org.eclipse.jface.resource.FontRegistry.getBold方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。