org.eclipse.swt.widgets.Canvas.setForeground()方法的使用及代码示例

x33g5p2x  于2022-01-18 转载在 其他  
字(9.2k)|赞(0)|评价(0)|浏览(137)

本文整理了Java中org.eclipse.swt.widgets.Canvas.setForeground()方法的一些代码示例,展示了Canvas.setForeground()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Canvas.setForeground()方法的具体详情如下:
包路径:org.eclipse.swt.widgets.Canvas
类名称:Canvas
方法名:setForeground

Canvas.setForeground介绍

暂无

代码示例

代码示例来源:origin: org.eclipse/org.eclipse.help.ui

public void setForeground(Color c) {
  super.setForeground(c);
  label.setForeground(c);
}

代码示例来源:origin: org.eclipse.platform/org.eclipse.ui.forms

@Override
public void setForeground(Color fg) {
  super.setForeground(fg);
  titleLabel.setForeground(fg);
  if (menuHyperlink != null)
    menuHyperlink.setForeground(fg);
}

代码示例来源:origin: org.eclipse.platform/org.eclipse.ui.forms

/**
 * Sets the foreground of all the custom controls in the expandable.
 */
@Override
public void setForeground(Color fg) {
  super.setForeground(fg);
  if (textLabel != null)
    textLabel.setForeground(fg);
  if (toggle != null)
    toggle.setForeground(fg);
}

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.ui.forms

/**
 * Sets the foreground color of the header.
 */
@Override
public void setForeground(Color fg) {
  super.setForeground(fg);
  titleRegion.setForeground(fg);
  if (messageRegion != null)
    messageRegion.setForeground(fg);
}

代码示例来源:origin: org.eclipse.platform/org.eclipse.ui.forms

/**
 * Sets the foreground color of the header.
 */
@Override
public void setForeground(Color fg) {
  super.setForeground(fg);
  titleRegion.setForeground(fg);
  if (messageRegion != null)
    messageRegion.setForeground(fg);
}

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.ui.forms

@Override
public void setForeground(Color fg) {
  super.setForeground(fg);
  titleLabel.setForeground(fg);
  if (menuHyperlink != null)
    menuHyperlink.setForeground(fg);
}

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.ui.forms

/**
 * Sets the foreground of all the custom controls in the expandable.
 */
@Override
public void setForeground(Color fg) {
  super.setForeground(fg);
  if (textLabel != null)
    textLabel.setForeground(fg);
  if (toggle != null)
    toggle.setForeground(fg);
}

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x

/**
 * Sets the receiver's foreground color to the color specified
 * by the argument, or to the default system color for the control
 * if the argument is null.
 * <p>
 * Note: This operation is a hint and may be overridden by the platform.
 * </p>
 * @param color the new color (or null)
 *
 * @exception IllegalArgumentException <ul>
 *    <li>ERROR_INVALID_ARGUMENT - if the argument has been disposed</li>
 * </ul>
 * @exception SWTException <ul>
 *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
 *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
 * </ul>
 */
@Override
public void setForeground (Color color) {
  foreground = color;
  super.setForeground(getForeground());
  redraw();
}

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc

/**
 * Sets the receiver's foreground color to the color specified
 * by the argument, or to the default system color for the control
 * if the argument is null.
 * <p>
 * Note: This operation is a hint and may be overridden by the platform.
 * </p>
 * @param color the new color (or null)
 *
 * @exception IllegalArgumentException <ul>
 *    <li>ERROR_INVALID_ARGUMENT - if the argument has been disposed</li>
 * </ul>
 * @exception SWTException <ul>
 *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
 *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
 * </ul>
 */
@Override
public void setForeground (Color color) {
  foreground = color;
  super.setForeground(getForeground());
  redraw();
}

代码示例来源:origin: org.eclipse.swt.cocoa.macosx/x86_64

/**
 * Sets the receiver's foreground color to the color specified
 * by the argument, or to the default system color for the control
 * if the argument is null.
 * <p>
 * Note: This operation is a hint and may be overridden by the platform.
 * </p>
 * @param color the new color (or null)
 *
 * @exception IllegalArgumentException <ul>
 *    <li>ERROR_INVALID_ARGUMENT - if the argument has been disposed</li> 
 * </ul>
 * @exception SWTException <ul>
 *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
 *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
 * </ul>
 */
public void setForeground (Color color) {
  foreground = color;
  super.setForeground(getForeground());
  redraw();
}
/**

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc

/**
 * Sets the receiver's foreground color to the color specified
 * by the argument, or to the default system color for the control
 * if the argument is null.
 * <p>
 * Note: This operation is a hint and may be overridden by the platform.
 * </p>
 * @param color the new color (or null)
 *
 * @exception IllegalArgumentException <ul>
 *    <li>ERROR_INVALID_ARGUMENT - if the argument has been disposed</li>
 * </ul>
 * @exception SWTException <ul>
 *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
 *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
 * </ul>
 */
@Override
public void setForeground (Color color) {
  foreground = color;
  super.setForeground(getForeground());
  redraw();
}
/**

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc

/**
 * Sets the receiver's foreground color to the color specified
 * by the argument, or to the default system color for the control
 * if the argument is null.
 * <p>
 * Note: This operation is a hint and may be overridden by the platform.
 * </p>
 * @param color the new color (or null)
 *
 * @exception IllegalArgumentException <ul>
 *    <li>ERROR_INVALID_ARGUMENT - if the argument has been disposed</li>
 * </ul>
 * @exception SWTException <ul>
 *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
 *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
 * </ul>
 */
@Override
public void setForeground (Color color) {
  foreground = color;
  super.setForeground(getForeground());
  redraw();
}

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.swt.win32.win32.x86

/**
 * Sets the receiver's foreground color to the color specified
 * by the argument, or to the default system color for the control
 * if the argument is null.
 * <p>
 * Note: This operation is a hint and may be overridden by the platform.
 * </p>
 * @param color the new color (or null)
 *
 * @exception IllegalArgumentException <ul>
 *    <li>ERROR_INVALID_ARGUMENT - if the argument has been disposed</li>
 * </ul>
 * @exception SWTException <ul>
 *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
 *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
 * </ul>
 */
@Override
public void setForeground (Color color) {
  foreground = color;
  super.setForeground(getForeground());
  redraw();
}

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.swt.win32.win32.x86

/**
 * Sets the receiver's foreground color to the color specified
 * by the argument, or to the default system color for the control
 * if the argument is null.
 * <p>
 * Note: This operation is a hint and may be overridden by the platform.
 * </p>
 * @param color the new color (or null)
 *
 * @exception IllegalArgumentException <ul>
 *    <li>ERROR_INVALID_ARGUMENT - if the argument has been disposed</li>
 * </ul>
 * @exception SWTException <ul>
 *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
 *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
 * </ul>
 */
@Override
public void setForeground (Color color) {
  foreground = color;
  super.setForeground(getForeground());
  redraw();
}
/**

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc

/**
 * Sets the receiver's foreground color to the color specified
 * by the argument, or to the default system color for the control
 * if the argument is null.
 * <p>
 * Note: This operation is a hint and may be overridden by the platform.
 * </p>
 * @param color the new color (or null)
 *
 * @exception IllegalArgumentException <ul>
 *    <li>ERROR_INVALID_ARGUMENT - if the argument has been disposed</li>
 * </ul>
 * @exception SWTException <ul>
 *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
 *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
 * </ul>
 */
@Override
public void setForeground (Color color) {
  foreground = color;
  super.setForeground(getForeground());
  redraw();
}
/**

代码示例来源:origin: org.eclipse.swt.cocoa.macosx/x86_64

public void setForeground(Color color) {
  checkWidget();
  foreground = color;
  super.setForeground(getForeground());
  resetCache(0, content.getLineCount());
  setCaretLocation();
  super.redraw();
}
/**

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc

@Override
public void setForeground(Color color) {
  checkWidget();
  foreground = color;
  super.setForeground(getForeground());
  resetCache(0, content.getLineCount());
  setCaretLocation();
  super.redraw();
}
/**

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x

@Override
public void setForeground(Color color) {
  checkWidget();
  foreground = color;
  super.setForeground(getForeground());
  resetCache(0, content.getLineCount());
  setCaretLocation();
  super.redraw();
}
/**

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.swt.win32.win32.x86

@Override
public void setForeground(Color color) {
  checkWidget();
  foreground = color;
  super.setForeground(getForeground());
  resetCache(0, content.getLineCount());
  setCaretLocation();
  super.redraw();
}
/**

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc

@Override
public void setForeground(Color color) {
  checkWidget();
  foreground = color;
  super.setForeground(getForeground());
  resetCache(0, content.getLineCount());
  setCaretLocation();
  super.redraw();
}
/**

相关文章

Canvas类方法