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


Java Gray._100属性代码示例

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


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

示例1: getBorderColor

private static Color getBorderColor(boolean enabled) {
  // in sync with ComboBox's border color
  if (UIUtil.isUnderDarcula()) {
    return enabled ? Gray._100 : Gray._83;
  }
  return Gray._150;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:7,代码来源:DarculaTextBorder.java

示例2: getBackground

@Override
public Color getBackground() {
  if (isFocusOwner()) {
    return UIUtil.getListSelectionBackground();
  }
  if (UIUtil.isUnderDarcula()) {
    return Gray._100;
  }
  return super.getBackground();
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:10,代码来源:PaletteGroupComponent.java

示例3: createScopePanel

private JPanel createScopePanel(final String[] modifiers, final Options options) {
  JPanel panel = new JPanel(new BorderLayout());
  panel.setBorder(BorderFactory.createCompoundBorder(IdeBorderFactory.createTitledBorder(
    InspectionsBundle.message("inspection.scope.for.title"), true),
                                                     BorderFactory.createEmptyBorder(0, 3, 3, 3)));

  final Hashtable<Integer, JComponent> sliderLabels = new Hashtable<Integer, JComponent>();
  for (int i = 0; i < modifiers.length; i++) {
    sliderLabels.put(i + 1, new JLabel(modifiers[i]));
  }

  final JSlider slider = new JSlider(SwingConstants.VERTICAL, 1, modifiers.length, 1);

  slider.setLabelTable(sliderLabels);
  slider.putClientProperty(UIUtil.JSLIDER_ISFILLED, Boolean.TRUE);
  slider.setPreferredSize(JBUI.size(80, 50));
  slider.setPaintLabels(true);
  slider.setSnapToTicks(true);
  slider.addChangeListener(new ChangeListener() {
    @Override
    public void stateChanged(ChangeEvent e) {
      int value = slider.getValue();
      options.ACCESS_JAVADOC_REQUIRED_FOR = modifiers[value - 1];
      for (Integer key : sliderLabels.keySet()) {
        sliderLabels.get(key).setForeground(key.intValue() <= value ? Color.black : Gray._100);
      }
    }
  });

  Color fore = Color.black;
  for (int i = 0; i < modifiers.length; i++) {
    sliderLabels.get(i + 1).setForeground(fore);

    if (modifiers[i].equals(options.ACCESS_JAVADOC_REQUIRED_FOR)) {
      slider.setValue(i + 1);
      fore = Gray._100;
    }
  }

  panel.add(slider, BorderLayout.WEST);

  return panel;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:43,代码来源:JavaDocLocalInspection.java

示例4: getBorderColor

private Color getBorderColor() {
  if (comboBox != null && myComboBox.isEnabled()) {
    return new JBColor(Gray._150, Gray._100);
  }
  return new JBColor(Gray._150, Gray._88);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:6,代码来源:DarculaComboBoxUI.java

示例5: getFocusColor

protected Color getFocusColor(B button) {
  return Gray._100;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:3,代码来源:StickyButtonUI.java

示例6: getBorderColor

private static Color getBorderColor() {
  return new JBColor(Gray._150, Gray._100);
}
 
开发者ID:GoogleCloudPlatform,项目名称:google-cloud-intellij,代码行数:3,代码来源:CustomizableComboBox.java

示例7: createScopePanel

private JPanel createScopePanel(final String[] modifiers, final Options options) {
  JPanel panel = new JPanel(new BorderLayout());
  panel.setBorder(BorderFactory.createCompoundBorder(IdeBorderFactory.createTitledBorder(
    InspectionsBundle.message("inspection.scope.for.title"), true),
                                                     BorderFactory.createEmptyBorder(0, 3, 3, 3)));

  final Hashtable<Integer, JLabel> sliderLabels = new Hashtable<Integer, JLabel>();
  for (int i = 0; i < modifiers.length; i++) {
    sliderLabels.put(i + 1, new JLabel(modifiers[i]));
  }

  final JSlider slider = new JSlider(SwingConstants.VERTICAL, 1, modifiers.length, 1);

  slider.setLabelTable(sliderLabels);
  slider.putClientProperty(UIUtil.JSLIDER_ISFILLED, Boolean.TRUE);
  slider.setPreferredSize(new Dimension(80, 50));
  slider.setPaintLabels(true);
  slider.setSnapToTicks(true);
  slider.addChangeListener(new ChangeListener() {
    @Override
    public void stateChanged(ChangeEvent e) {
      int value = slider.getValue();
      options.ACCESS_JAVADOC_REQUIRED_FOR = modifiers[value - 1];
      for (Integer key : sliderLabels.keySet()) {
        sliderLabels.get(key).setForeground(key.intValue() <= value ? Color.black : Gray._100);
      }
    }
  });

  Color fore = Color.black;
  for (int i = 0; i < modifiers.length; i++) {
    sliderLabels.get(i + 1).setForeground(fore);

    if (modifiers[i].equals(options.ACCESS_JAVADOC_REQUIRED_FOR)) {
      slider.setValue(i + 1);
      fore = Gray._100;
    }
  }

  panel.add(slider, BorderLayout.WEST);

  return panel;
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:43,代码来源:JavaDocLocalInspection.java

示例8: getBorderColor

private static Gray getBorderColor() {
  return Gray._100;
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:3,代码来源:DarculaComboBoxUI.java


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