Class CssUtils


  • public final class CssUtils
    extends Object
    Utility methods for CSS.
    Author:
    eelcohillenius
    • Method Detail

      • writeCss

        @Deprecated
        public static void writeCss​(org.apache.wicket.request.Response response,
                                    CharSequence text,
                                    String id)
        Write the simple text to the response object surrounded by a style tag.
        Parameters:
        response - The HTTP: response
        text - The text to added in between the style tags
        id - Unique identifier of element
      • writeInlineStyle

        public static void writeInlineStyle​(org.apache.wicket.request.Response response,
                                            CharSequence text,
                                            org.apache.wicket.util.value.AttributeMap attributes)
        Write the simple text to the response object surrounded by a style tag. In most cases the text simply an inline CSS.
        Parameters:
        response - The HTTP: response
        text - The text to added in between the style tags
        attributes - Tag attributes map
        See Also:
        Style HTML Element
      • writeOpenTag

        public static void writeOpenTag​(org.apache.wicket.request.Response response,
                                        String id)
        Write open style tag for the inline CSS
        Parameters:
        response -
        id -
      • writeOpenTag

        public static void writeOpenTag​(org.apache.wicket.request.Response response,
                                        org.apache.wicket.util.value.AttributeMap attributes)
        Write open style tag for the inline CSS
        Parameters:
        response - the response to write to
        attributes - Tag attributes map
      • writeCloseTag

        public static void writeCloseTag​(org.apache.wicket.request.Response response)
        Parameters:
        response -
      • writeLinkUrl

        @Deprecated
        public static void writeLinkUrl​(org.apache.wicket.request.Response response,
                                        CharSequence url,
                                        CharSequence media,
                                        String markupId)
        Deprecated.
        Writes a reference to a css file in the response object
        Parameters:
        response - the response to write to
        url - the url of the css reference
        media - the CSS media
        markupId - the markupId
      • writeLinkUrl

        @Deprecated
        public static void writeLinkUrl​(org.apache.wicket.request.Response response,
                                        CharSequence url,
                                        CharSequence media,
                                        String markupId,
                                        String rel)
        Deprecated.
        Writes a reference to a css file in the response object
        Parameters:
        response - the response to write to
        url - the url of the css reference
        media - the CSS media
        markupId - the markupId
        rel - the rel attribute
      • writeLink

        public static void writeLink​(org.apache.wicket.request.Response response,
                                     org.apache.wicket.util.value.AttributeMap attributes)
        Writes a reference to a css file in the response object
        Parameters:
        response - the response to write to
        attributes - Attributes map
        See Also:
        Link HTML Element
      • key

        public static String key​(Class<?> scope,
                                 String facet)
        Get a standardized key for a CSS class.
        Parameters:
        scope - scope of CSS class
        facet - facet of CSS class
        Returns:
        CSS key