Class CSS2FontHelper

java.lang.Object
org.eclipse.e4.ui.css.core.css2.CSS2FontHelper

public class CSS2FontHelper extends Object
CSS2 Font Helper.
Version:
1.0.0
Author:
Angelo ZERR
  • Constructor Details

    • CSS2FontHelper

      public CSS2FontHelper()
  • Method Details

    • getFontFamily

      public static String getFontFamily(String family)
      Return CSS2 font-family. Escape font family with " if need.
    • getFontSize

      public static String getFontSize(int size)
      Return CSS2 font-size of int size.
    • getFontStyle

      public static String getFontStyle(boolean isItalic)
      Return CSS2 font-style.
    • getFontWeight

      public static String getFontWeight(boolean isBold)
      Return CSS2 font-weight.
    • getCSSFontPropertyName

      public static String getCSSFontPropertyName(CSSPrimitiveValue value)
      Return the CSS Font Property name (font-style, font-weight, font-size, font-family) switch the CSSPrimitiveValue value.