Package org.apache.myfaces.trinidadinternal.style

Examples of org.apache.myfaces.trinidadinternal.style.StyleMap


    StyleContext styleContext = imageContext.getStyleContext();
    StyleProvider provider = styleContext.getStyleProvider();
    if (provider != null)
    {
      // Get the StyleMap
      StyleMap map = provider.getStyleMap(styleContext);

      if (map != null)
      {
        // Derive the style name to use from the font name.
        Font font = context.getPaintFont();
        String name = _styleNamePrefix + font.getName();

        return map.getStyleByName(styleContext, name);
      }
    }

    return null;
  }
View Full Code Here


      // If we don't get a background color from the inline
      // style, check the style class
      if ((background == null) && (entry.styleClass != null))
      {
        // We need to look up the style class in the style map
        StyleMap map = context.getStyleContext().getStyleMap();
        if (map != null)
        {
          StyleContext styleContext = context.getStyleContext();
          Style style = map.getStyleByClass(styleContext, entry.styleClass);

          background = _getBackground(style);
        }
      }
View Full Code Here

    Object           className
    )
  {
    if (className != null)
    {
      StyleMap map = context.getStyleContext().getStyleMap();
      if (map != null)
      {
        return map.getStyleByClass(context.getStyleContext(),
                                   className.toString());
      }
    }

    return null;
View Full Code Here

    Object           styleSelector
    )
  {
    if (styleSelector != null)
    {
      StyleMap map = context.getStyleContext().getStyleMap();
      if (map != null)
      {
        return map.getStyleBySelector(context.getStyleContext(),
                                      styleSelector.toString());
      }
    }

    return null;
View Full Code Here

    String       styleID,
    ParsedPropertyKey key,
    boolean      isNamed
    )
  {
    StyleMap map = context.getStyleContext().getStyleMap();

    if (map == null)
    {
// =-=ags Don't log this condition for now.  The ImageGenerator doesn't
//        set up the StyleMap yet, so let's blow this off for now
//      _LOG.fine(_MAP_ERROR);
      return null;
    }

    Style style = null;

    if (isNamed)
      style = map.getStyleByName(context.getStyleContext(), styleID);
    else
      style = map.getStyleByClass(context.getStyleContext(), styleID);

    if (style == null)
    {
      if (_LOG.isFine())
        _LOG.fine(_STYLE_ERROR + styleID);
View Full Code Here

    // Check the af|menuTabs::separator style to see whether a non-zero width
    // is defined
    boolean doRenderSep = false;

    StyleMap styleMap = context.getStyleContext().getStyleMap();
    if (styleMap != null)
    {
      StyleContext styleContext = context.getStyleContext();
      Style style = styleMap.getStyleByClass(styleContext,
                                             AF_MENU_TABS_SEPARATOR_STYLE_CLASS);

      if (style != null)
      {
        String width = style.getProperty("width");
View Full Code Here

    )
  {
    if (name == null)
      return null;

    StyleMap map = context.getStyleContext().getStyleMap();
    if (map == null)
      return null;

    return map.getStyleByName(context.getStyleContext(), name);
  }
View Full Code Here

    if (color != null)
      return color;

    // If the color hasn't been stored on the RenderingContext, get it
    // from the style map.
    StyleMap map = context.getStyleContext().getStyleMap();

    if (map != null)
    {
      Style style = map.getStyleByClass(context.getStyleContext(), styleClass);
      if (style != null)
      {
        try
        {
          color = (Color)style.getParsedProperty(Style.BACKGROUND_KEY);
View Full Code Here

    // Check the af|menuTabs::separator style to see whether a non-zero width
    // is defined
    boolean doRenderSep = false;

    StyleMap styleMap = context.getStyleContext().getStyleMap();
    if (styleMap != null)
    {
      StyleContext styleContext = context.getStyleContext();
      Style style = styleMap.getStyleByClass(styleContext,
                                             AF_MENU_TABS_SEPARATOR_STYLE_CLASS);

      if (style != null)
      {
        String width = style.getProperty("width");
View Full Code Here

    Object           className
    )
  {
    if (className != null)
    {
      StyleMap map = context.getStyleContext().getStyleMap();
      if (map != null)
      {
        return map.getStyleByClass(context.getStyleContext(),
                                   className.toString());
      }
    }

    return null;
View Full Code Here

TOP

Related Classes of org.apache.myfaces.trinidadinternal.style.StyleMap

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.