本文整理汇总了Java中org.geomajas.configuration.FontStyleInfo.setSize方法的典型用法代码示例。如果您正苦于以下问题:Java FontStyleInfo.setSize方法的具体用法?Java FontStyleInfo.setSize怎么用?Java FontStyleInfo.setSize使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.geomajas.configuration.FontStyleInfo
的用法示例。
在下文中一共展示了FontStyleInfo.setSize方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createRandomLabelStyle
import org.geomajas.configuration.FontStyleInfo; //导入方法依赖的package包/类
private LabelStyleInfo createRandomLabelStyle(String attributeName) {
LabelStyleInfo labelStyle = new LabelStyleInfo();
labelStyle.setLabelAttributeName(attributeName);
FontStyleInfo fontStyle = new FontStyleInfo();
fontStyle.setColor("#000000");
fontStyle.setFamily("Verdana");
fontStyle.setOpacity(1F);
fontStyle.setSize(8);
labelStyle.setFontStyle(fontStyle);
FeatureStyleInfo backgroundStyle = new FeatureStyleInfo();
backgroundStyle.setFillColor("#FFFFFF");
backgroundStyle.setFillOpacity(0.7F);
backgroundStyle.setStrokeColor("#000099");
backgroundStyle.setStrokeOpacity(1F);
backgroundStyle.setStrokeWidth(1);
labelStyle.setBackgroundStyle(backgroundStyle);
return labelStyle;
}
示例2: buildTitle
import org.geomajas.configuration.FontStyleInfo; //导入方法依赖的package包/类
protected LabelComponentInfo buildTitle() {
if (titleText != null) {
LabelComponentInfo title = new LabelComponentInfo();
FontStyleInfo style = new FontStyleInfo();
style.setFamily("Arial");
style.setStyle("Italic");
style.setSize(14);
title.setFont(style);
title.setBackgroundColor("#FFFFFF");
title.setBorderColor("#000000");
title.setFontColor("#000000");
title.getLayoutConstraint().setAlignmentY(LayoutConstraintInfo.TOP);
title.getLayoutConstraint().setAlignmentX(LayoutConstraintInfo.CENTER);
title.setTag("title");
title.setText(titleText);
title.getLayoutConstraint().setMarginY(2 * marginY);
return title;
} else {
return null;
}
}
示例3: createRandomLabelStyle
import org.geomajas.configuration.FontStyleInfo; //导入方法依赖的package包/类
private LabelStyleInfo createRandomLabelStyle(String attributeName) {
LabelStyleInfo style = new LabelStyleInfo();
style.setBackgroundStyle(createRandomPolygonStyle());
FontStyleInfo fontStyle = new FontStyleInfo();
fontStyle.setColor(style.getBackgroundStyle().getStrokeColor());
fontStyle.setFamily("Verdana");
fontStyle.setOpacity(1F);
fontStyle.setSize(8);
fontStyle.setWeight("normal");
fontStyle.setStyle("normal");
style.setFontStyle(fontStyle);
style.setLabelAttributeName(attributeName);
return style;
}
示例4: buildTitle
import org.geomajas.configuration.FontStyleInfo; //导入方法依赖的package包/类
protected LabelComponentInfo buildTitle() {
LabelComponentInfo label = new LabelComponentInfo();
FontStyleInfo style = new FontStyleInfo();
style.setFamily(PrintingLayout.templateDefaultFontFamily);
style.setStyle(PrintingLayout.templateDefaultFontStyle);
style.setSize((int) PrintingLayout.templateDefaultFontSize);
label.setFont(style);
label.setBackgroundColor(PrintingLayout.templateDefaultBackgroundColor);
label.setBorderColor(PrintingLayout.templateDefaultBorderColor);
label.setFontColor(PrintingLayout.templateDefaultColor);
label.getLayoutConstraint().setAlignmentY(LayoutConstraintInfo.TOP);
label.getLayoutConstraint().setAlignmentX(LayoutConstraintInfo.CENTER);
label.setTag("title");
return label;
}
示例5: createTextSymbolizer
import org.geomajas.configuration.FontStyleInfo; //导入方法依赖的package包/类
private TextSymbolizerInfo createTextSymbolizer(FontStyle style) {
FontStyleInfo font = new FontStyleInfo();
font.setColor(style.getFillColor());
font.setFamily(style.getFontFamily());
font.setSize(style.getFontSize());
font.setStyle(style.getFontStyle());
font.setOpacity(1f);
font.setWeight(style.getFontWeight());
return StyleUtil.createSymbolizer(font);
}
示例6: buildTitle
import org.geomajas.configuration.FontStyleInfo; //导入方法依赖的package包/类
protected LabelComponentInfo buildTitle() {
LabelComponentInfo label = new LabelComponentInfo();
FontStyleInfo style = new FontStyleInfo();
style.setFamily(PrintLayout.templateDefaultFontFamily);
style.setStyle(PrintLayout.templateDefaultFontStyle);
style.setSize((int) PrintLayout.templateDefaultFontSize);
label.setFont(style);
label.setBackgroundColor(PrintLayout.templateDefaultBackgroundColor);
label.setBorderColor(PrintLayout.templateDefaultBorderColor);
label.setFontColor(PrintLayout.templateDefaultColor);
label.getLayoutConstraint().setAlignmentY(LayoutConstraintInfo.TOP);
label.getLayoutConstraint().setAlignmentX(LayoutConstraintInfo.CENTER);
label.setTag("title");
return label;
}
示例7: ScaleBarComponentInfo
import org.geomajas.configuration.FontStyleInfo; //导入方法依赖的package包/类
/** Constructor. */
public ScaleBarComponentInfo() {
getLayoutConstraint().setAlignmentX(LayoutConstraintInfo.LEFT);
getLayoutConstraint().setAlignmentY(LayoutConstraintInfo.BOTTOM);
getLayoutConstraint().setMarginX(20);
getLayoutConstraint().setMarginY(20);
getLayoutConstraint().setWidth(200);
font = new FontStyleInfo();
font.setFamily("Dialog");
font.setStyle("Plain");
font.setSize(10);
}
示例8: LegendComponentInfo
import org.geomajas.configuration.FontStyleInfo; //导入方法依赖的package包/类
/**
* Default constructor.
*/
public LegendComponentInfo() {
getLayoutConstraint().setAlignmentX(LayoutConstraintInfo.RIGHT);
getLayoutConstraint().setAlignmentY(LayoutConstraintInfo.BOTTOM);
getLayoutConstraint().setFlowDirection(LayoutConstraintInfo.FLOW_Y);
getLayoutConstraint().setMarginX(20);
getLayoutConstraint().setMarginY(20);
setTag(LEGEND_TAG);
font = new FontStyleInfo();
font.setFamily(DEFAULT_LEGEND_FONT_FAMILY);
font.setStyle(LEGEND_FONT_STYLE_AS_STRING);
font.setSize(12);
}
示例9: convertFont
import org.geomajas.configuration.FontStyleInfo; //导入方法依赖的package包/类
private FontStyleInfo convertFont(FontInfo font) throws LayerException {
FontStyleInfo fontStyle = new FontStyleInfo();
if (font == null) {
fontStyle.applyDefaults();
} else {
Map<String, String> cssMap = getLiteralMap(font.getCssParameterList());
fontStyle.setFamily(cssMap.get(CSS_FONT_FAMILY));
if (cssMap.containsKey(CSS_FONT_SIZE)) {
fontStyle.setSize((int) parseFloat(cssMap, CSS_FONT_SIZE));
}
fontStyle.setStyle(cssMap.get(CSS_FONT_STYLE));
fontStyle.setWeight(cssMap.get(CSS_FONT_WEIGHT));
}
return fontStyle;
}