Tabnine Logo
Font.getFontWeight
Code IndexAdd Tabnine to your IDE (free)

How to use
getFontWeight
method
in
org.geotools.styling.Font

Best Java code snippets using org.geotools.styling.Font.getFontWeight (Showing top 12 results out of 315)

origin: geotools/geotools

String reqWeight = evalToString(curr.getFontWeight(), feature, null);
origin: geotools/geotools

@SuppressWarnings("deprecation")
@Test
public void font() throws Exception {
  List<Expression> family = new ArrayList<Expression>();
  family.add(ff.literal("ariel"));
  family.add(ff.literal("Helvetica"));
  family.add(ff.literal("sanserif"));
  Expression style = ff.literal("noraml");
  Expression weight = ff.literal("normal");
  Expression size = ff.literal(12);
  Font font = sf.font(family, style, weight, size);
  assertEquals(family, font.getFamily());
  assertEquals(style, font.getStyle()); // oblique or italic
  assertEquals(weight, font.getWeight()); // bold or normal
  assertEquals(size, font.getSize());
  assertSame(font.getFontStyle(), font.getStyle());
  assertSame(font.getFontFamily(), family.get(0));
  assertSame(font.getFontWeight(), font.getWeight());
  assertSame(font.getFontSize(), font.getSize());
  FontImpl cast = FontImpl.cast(font);
  assertSame(cast, font);
}
origin: org.geotools/gt-render

private java.awt.Font styleFont(Object feature, Font curr,
  java.awt.Font javaFont) {
  String reqStyle = evalToString(curr.getFontStyle(), feature, null);
  int styleCode;
  if (fontStyleLookup.containsKey(reqStyle)) {
    styleCode = ((Integer) fontStyleLookup.get(reqStyle)).intValue();
  } else {
    styleCode = java.awt.Font.PLAIN;
  }
  String reqWeight = evalToString(curr.getFontWeight(), feature, null);
  if ("Bold".equalsIgnoreCase(reqWeight)) {
    styleCode = styleCode | java.awt.Font.BOLD;
  }
  float size = evalToFloat(curr.getSize(), feature, 10);
  return javaFont.deriveFont(styleCode, size);
}
origin: org.geotools/gt2-render

String reqWeight = (String) fonts[k].getFontWeight().evaluate(feature);
String reqWeight = (String) fonts[k].getFontWeight().evaluate(feature);
origin: org.geotools/gt-widgets-swing-pending

public void setEdited(Font font){        
  this.font = font;
  
  if(font != null){
    guiFamily.setExpression(font.getFontFamily());
    guiSize.setExpression(font.getFontSize());
    guiStyle.setExpression(font.getFontStyle());
    guiWeight.setExpression(font.getFontWeight());
  }
}

origin: org.geotools/gt-main

/** Null safe copy of a single font */
protected Font copy(Font font) {
  if( font == null) return font;
  
  Expression fontFamily = copy( font.getFontFamily() );
  Expression fontStyle = copy( font.getFontStyle() );
  Expression fontWeight = copy( font.getFontWeight() );
  Expression fontSize = copy( font.getFontSize() );
  Font copy = sf.createFont(fontFamily, fontStyle, fontWeight, fontSize);
  return copy;
}

origin: org.geotools/gt-render

if (font.getFontWeight() != null) {
  font.getFontWeight().accept(this, null);
origin: org.geotools/gt2-main

if (font.getFontWeight() != null) {
  font.getFontWeight().accept(this,null);
origin: org.geotools/gt2-main

if (font.getFontWeight() != null) {
  font.getFontWeight().accept(this,null);
origin: org.geotools/gt-main

encodeCssParam("font-weight", fonts[0].getFontWeight());
end("Font");
origin: org.geotools/gt-render

if (font.getFontWeight() != null) {
  font.getFontWeight().accept(this,null);
origin: org.geotools/gt2-main

encodeCssParam("font-weight", fonts[0].getFontWeight());
end("Font");
org.geotools.stylingFontgetFontWeight

Popular methods of Font

  • getFamily
  • getSize
  • getStyle
  • getWeight
  • getFontFamily
  • getFontSize
  • getFontStyle
  • setSize
  • setStyle
  • setFontFamily
  • setFontSize
  • setFontStyle
  • setFontSize,
  • setFontStyle,
  • setFontWeight,
  • setWeight

Popular in Java

  • Creating JSON documents from java classes using gson
  • startActivity (Activity)
  • getSystemService (Context)
  • getResourceAsStream (ClassLoader)
  • BufferedImage (java.awt.image)
    The BufferedImage subclass describes an java.awt.Image with an accessible buffer of image data. All
  • URLEncoder (java.net)
    This class is used to encode a string using the format required by application/x-www-form-urlencoded
  • MessageFormat (java.text)
    Produces concatenated messages in language-neutral way. New code should probably use java.util.Forma
  • BoxLayout (javax.swing)
  • JComboBox (javax.swing)
  • Scheduler (org.quartz)
    This is the main interface of a Quartz Scheduler. A Scheduler maintains a registry of org.quartz.Job
  • Top plugins for Android Studio
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now