本文整理汇总了Java中org.netbeans.api.visual.widget.Widget.setForeground方法的典型用法代码示例。如果您正苦于以下问题:Java Widget.setForeground方法的具体用法?Java Widget.setForeground怎么用?Java Widget.setForeground使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.netbeans.api.visual.widget.Widget
的用法示例。
在下文中一共展示了Widget.setForeground方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: installUI
import org.netbeans.api.visual.widget.Widget; //导入方法依赖的package包/类
public void installUI (VMDNodeWidget widget) {
widget.setBorder (VMDFactory.createVMDNodeBorder ());
widget.setOpaque (false);
Widget header = widget.getHeader ();
header.setBorder (BORDER_PIN);
header.setBackground (COLOR_SELECTED);
header.setOpaque (false);
Widget minimize = widget.getMinimizeButton ();
minimize.setBorder (BORDER_MINIMIZE);
Widget pinsSeparator = widget.getPinsSeparator ();
pinsSeparator.setForeground (BORDER_CATEGORY_BACKGROUND);
}
示例2: installUI
import org.netbeans.api.visual.widget.Widget; //导入方法依赖的package包/类
public void installUI (VMDNodeWidget widget) {
widget.setBorder (BORDER60);
Widget header = widget.getHeader ();
header.setBackground (COLOR60_HOVER_BACKGROUND);
header.setBorder (VMDOriginalColorScheme.BORDER_PIN);
Widget pinsSeparator = widget.getPinsSeparator ();
pinsSeparator.setForeground (VMDOriginalColorScheme.BORDER_CATEGORY_BACKGROUND);
}
示例3: unsetHovering
import org.netbeans.api.visual.widget.Widget; //导入方法依赖的package包/类
public void unsetHovering(Widget w) {
w.setForeground(color_enabled);
ObjectState state = w.getState();
w.setState(state.deriveWidgetHovered(false));
w.bringToBack();
endPreview();
}
示例4: setHovering
import org.netbeans.api.visual.widget.Widget; //导入方法依赖的package包/类
public void setHovering(Widget w) {
ObjectState state = w.getState();
w.setState(state.deriveWidgetHovered(true));
w.setForeground(color_hover);
w.bringToFront();
nodeWidget.bringToFront();
startPreview();
}
示例5: createSelectionWidget
import org.netbeans.api.visual.widget.Widget; //导入方法依赖的package包/类
public Widget createSelectionWidget() {
Widget widget = new Widget(this);
widget.setOpaque(false);
widget.setBorder(BorderFactory.createLineBorder(Color.black, 2));
widget.setForeground(Color.red);
return widget;
}