本文整理汇总了Java中com.google.gwt.dom.client.Style.setBackgroundColor方法的典型用法代码示例。如果您正苦于以下问题:Java Style.setBackgroundColor方法的具体用法?Java Style.setBackgroundColor怎么用?Java Style.setBackgroundColor使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.google.gwt.dom.client.Style
的用法示例。
在下文中一共展示了Style.setBackgroundColor方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: setQuasiDeleted
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
@Override
public void setQuasiDeleted(String title, boolean isRowOwnerDeleted) {
self.addClassName(css.deleted());
// white margins are shown only if blip doesn't have a deleted row owner blip
int marginWidthPct = isRowOwnerDeleted ? 0 : 100;
getTopMargin().getStyle().setWidth(marginWidthPct, Style.Unit.PCT);
getBottomMargin().getStyle().setWidth(marginWidthPct, Style.Unit.PCT);
Style metaFrameStyle = DomViewHelper.load(getMeta().getId(),
BlipMetaViewBuilder.Components.FRAME).getStyle();
metaFrameStyle.setBackgroundColor(DELETED_COLOR);
metaFrameStyle.setBorderColor(DELETED_COLOR);
DomUtil.findFirstChildElement(meta, Type.BLIP_INDICATOR).getStyle().setBorderColor(DELETED_COLOR);
self.setTitle(title);
// Unset cursor shape for children
setAutoCursor(DomUtil.findFirstChildElement(getMeta(), Type.BLIP_CONTINUATION_BAR));
Element timeAndMenu = DomUtil.findFirstChildElement(getMeta(), Type.META_BAR, Type.TIME_AND_MENU);
setAutoCursor(timeAndMenu);
setAutoCursor(DomUtil.findFirstChildElement(timeAndMenu, Type.BLIP_TIME));
Element menuButton = DomUtil.findFirstChildElement(timeAndMenu, Type.BLIP_MENU_BUTTON);
setAutoCursor(menuButton);
// Remove arrow from menu button
menuButton.getStyle().setColor(DELETED_COLOR);
DomUtil.setQuasiDeleted(self);
}
示例2: initSearchPopUp
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
private void initSearchPopUp() {
this.searchPopUp = new SearchPopUp();
Style style = this.searchPopUp.getElement().getStyle();
style.setBackgroundColor("grey");
style.setBorderStyle(Style.BorderStyle.SOLID);
style.setBorderColor("#dbdbdb");
style.setBorderWidth(1, Style.Unit.PX);
style.setPadding(2, Style.Unit.PX);
style.setPosition(Style.Position.FIXED);
style.setTop(100, Style.Unit.PX);
style.setLeft(20, Style.Unit.PX);
}
示例3: setMessage
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
public void setMessage(String msg, String bkgColor, String txtColor) {
label_.setText(msg);
Style labelStyle = label_.getElement().getStyle();
labelStyle.setFontSize(1.6, Style.Unit.EM);
labelStyle.setBackgroundColor(bkgColor);
labelStyle.setColor(txtColor);
labelStyle.setPadding(5, Style.Unit.PX);
}
示例4: setLine
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
private static void setLine(final Style style,
final int width,
final int top,
final int height,
final String color) {
style.setPosition(Position.ABSOLUTE);
style.setTop(top,
PX);
style.setHeight(height,
PX);
style.setWidth(width,
PX);
style.setBackgroundColor(color);
style.setZIndex(Integer.MAX_VALUE);
}