本文整理了Java中org.eclipse.ui.forms.widgets.Hyperlink.setBackground()
方法的一些代码示例,展示了Hyperlink.setBackground()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Hyperlink.setBackground()
方法的具体详情如下:
包路径:org.eclipse.ui.forms.widgets.Hyperlink
类名称:Hyperlink
方法名:setBackground
暂无
代码示例来源:origin: org.eclipse.platform/org.eclipse.ui.forms
public void setBackground(Color bg) {
if (messageHyperlink != null)
messageHyperlink.setBackground(bg);
if (messageLabel != null)
messageLabel.setBackground(bg);
}
代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.ui.forms
public void setBackground(Color bg) {
if (messageHyperlink != null)
messageHyperlink.setBackground(bg);
if (messageLabel != null)
messageLabel.setBackground(bg);
}
代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.ui.forms
/**
* Sets the group background and also sets the background of all the
* currently managed links.
*
* @param bg
* the new background
*/
@Override
public void setBackground(Color bg) {
super.setBackground(bg);
isBackgroundSet = true;
if (links != null) {
for (int i = 0; i < links.size(); i++) {
Hyperlink label = links.get(i);
label.setBackground(bg);
}
}
}
/**
代码示例来源:origin: org.eclipse.platform/org.eclipse.ui.forms
/**
* Sets the group background and also sets the background of all the
* currently managed links.
*
* @param bg
* the new background
*/
@Override
public void setBackground(Color bg) {
super.setBackground(bg);
isBackgroundSet = true;
if (links != null) {
for (int i = 0; i < links.size(); i++) {
Hyperlink label = links.get(i);
label.setBackground(bg);
}
}
}
/**
代码示例来源:origin: org.eclipse.platform/org.eclipse.ui.forms
private void onMouseExit(Event e) {
Hyperlink link = (Hyperlink) e.widget;
if (isActiveBackgroundSet)
link.setBackground(previousBackground);
if (isActiveForegroundSet)
link.setForeground(previousForeground);
if (getHyperlinkUnderlineMode() == UNDERLINE_HOVER)
link.setUnderlined(false);
}
@Override
代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.ui.forms
private void onMouseExit(Event e) {
Hyperlink link = (Hyperlink) e.widget;
if (isActiveBackgroundSet)
link.setBackground(previousBackground);
if (isActiveForegroundSet)
link.setForeground(previousForeground);
if (getHyperlinkUnderlineMode() == UNDERLINE_HOVER)
link.setUnderlined(false);
}
@Override
代码示例来源:origin: org.eclipse.platform/org.eclipse.team.ui
link.setBackground(getListBackgroundColor());
link.setUnderlined(true);
link.setBackground(getListBackgroundColor());
link.setUnderlined(true);
代码示例来源:origin: org.eclipse/org.eclipse.team.ui
link.setBackground(getBackgroundColor());
link.setUnderlined(true);
link.setBackground(getBackgroundColor());
link.setUnderlined(true);
代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.ui.forms
/**
* Adds a hyperlink to the group to be jointly managed. Hyperlink will be
* managed until it is disposed. Settings like colors, cursors and modes
* will affect all managed hyperlinks.
*
* @param link
*/
public void add(Hyperlink link) {
if (isBackgroundSet)
link.setBackground(getBackground());
if (isForegroundSet)
link.setForeground(getForeground());
if (getHyperlinkUnderlineMode() == UNDERLINE_ALWAYS)
link.setUnderlined(true);
hook(link);
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.ui.forms
/**
* Adds a hyperlink to the group to be jointly managed. Hyperlink will be
* managed until it is disposed. Settings like colors, cursors and modes
* will affect all managed hyperlinks.
*
* @param link
*/
public void add(Hyperlink link) {
if (isBackgroundSet)
link.setBackground(getBackground());
if (isForegroundSet)
link.setForeground(getForeground());
if (getHyperlinkUnderlineMode() == UNDERLINE_ALWAYS)
link.setUnderlined(true);
hook(link);
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.ui.forms
private void onMouseEnter(Event e) {
Hyperlink link = (Hyperlink) e.widget;
previousBackground = link.getBackground();
previousForeground = link.getForeground();
if (isActiveBackgroundSet)
link.setBackground(getActiveBackground());
if (isActiveForegroundSet)
link.setForeground(getActiveForeground());
if (getHyperlinkUnderlineMode() == UNDERLINE_HOVER)
link.setUnderlined(true);
link.setCursor(getHyperlinkCursor());
}
private void onMouseExit(Event e) {
代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.ui.forms
private void onMouseEnter(Event e) {
Hyperlink link = (Hyperlink) e.widget;
previousBackground = link.getBackground();
previousForeground = link.getForeground();
if (isActiveBackgroundSet)
link.setBackground(getActiveBackground());
if (isActiveForegroundSet)
link.setForeground(getActiveForeground());
if (getHyperlinkUnderlineMode() == UNDERLINE_HOVER)
link.setUnderlined(true);
link.setCursor(getHyperlinkCursor());
}
private void onMouseExit(Event e) {
代码示例来源:origin: org.eclipse.pde/org.eclipse.pde.ui
prev.setBackground(getBackground());
if (page == 0)
prev.setEnabled(false);
Hyperlink pageLink = new Hyperlink(this, SWT.NONE);
pageLink.setText(String.valueOf(i));
pageLink.setBackground(pageLink.getParent().getBackground());
if (i != curPage) {
final int selectedPage = i;
next.setBackground(getBackground());
if (lastPage)
next.setEnabled(false);
代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.ui.forms
messageHyperlink = new Hyperlink(FormHeading.this, SWT.NULL);
messageHyperlink.setUnderlined(true);
messageHyperlink.setBackground(getBackground());
messageHyperlink.setText(message);
messageHyperlink.setHref(messages);
代码示例来源:origin: org.eclipse.platform/org.eclipse.ui.forms
messageHyperlink = new Hyperlink(FormHeading.this, SWT.NULL);
messageHyperlink.setUnderlined(true);
messageHyperlink.setBackground(getBackground());
messageHyperlink.setText(message);
messageHyperlink.setHref(messages);
内容来源于网络,如有侵权,请联系作者删除!