org.apache.myfaces.tobago.renderkit.html
Class HtmlRendererUtil

java.lang.Object
  extended by org.apache.myfaces.tobago.renderkit.html.HtmlRendererUtil

public final class HtmlRendererUtil
extends Object


Method Summary
static void addAcceleratorKey(FacesContext facesContext, String func, char key)
           
static void addAcceleratorKey(FacesContext facesContext, String func, char key, String modifier)
           
static void addClickAcceleratorKey(FacesContext facesContext, String clientId, char key)
           
static void addClickAcceleratorKey(FacesContext facesContext, String clientId, char key, String modifier)
           
static void addCssClass(UIComponent component, String clazz)
          Deprecated. Please use StyleClasses.ensureStyleClasses(component).add(clazz);
static void addImageSources(FacesContext facesContext, TobagoResponseWriter writer, String src, String id)
           
static void addMarkupClass(UIComponent component, String rendererName, String subComponent, StringBuilder tobagoClass)
          Deprecated. Please use StyleClasses.addMarkupClass()
static void addMarkupClass(UIComponent component, String rendererName, StyleClasses classes)
          Deprecated. Please use StyleClasses.addMarkupClass()
static String addTip(String title, Object tip)
           
static String createAcceleratorKeyJsStatement(String func, char key, String modifier)
           
static void createCssClass(FacesContext facesContext, UIComponent component)
           
static void createHeaderAndBodyStyles(FacesContext facesContext, UIComponent component)
           
static void createHeaderAndBodyStyles(FacesContext facesContext, UIComponent component, boolean width)
           
static String createOnclickAcceleratorKeyJsStatement(String clientId, char key, String modifier)
           
static String createSrc(String src, String ext)
           
static void endJavascript(ResponseWriter writer)
          Deprecated. use TobagoResponseWriter.writeJavascript()
static String getComponentId(FacesContext context, UIComponent component, String componentId)
           
static String getJavascriptArray(String[] list)
           
static String getJavascriptString(String str)
           
static String getLayoutSpaceStyle(UIComponent component)
           
static String getRenderedPartiallyJavascriptArray(FacesContext facesContext, UICommand command)
           
static String getRendererName(FacesContext facesContext, UIComponent component)
           
static Integer getStyleAttributeIntValue(HtmlStyleMap style, String name)
           
static String getStyleAttributeValue(String style, String name)
           
static String getTitleFromTipAndMessages(FacesContext facesContext, UIComponent component)
           
static TobagoResponseWriter getTobagoResponseWriter(FacesContext facesContext)
           
static void layoutHeight(FacesContext facesContext, UIComponent component)
           
static void layoutSpace(FacesContext facesContext, UIComponent component, boolean width)
           
static void layoutWidth(FacesContext facesContext, UIComponent component)
           
static HtmlStyleMap prepareInnerStyle(UIComponent component)
           
static void prepareRender(FacesContext facesContext, UIComponent component)
           
static String removeStyleAttribute(String style, String name)
          Deprecated.  
static void removeStyleAttribute(UIComponent component, String name)
           
static void removeStyleClasses(UIComponent cell)
           
static void renderFocusId(FacesContext facesContext, UIComponent component)
           
static void renderFocusId(FacesContext facesContext, UIInput component)
           
static void renderImageTip(UIComponent component, TobagoResponseWriter writer)
           
static void renderSelectItems(UIInput component, List<SelectItem> items, Object[] values, TobagoResponseWriter writer, FacesContext facesContext)
           
static void renderTip(UIComponent component, TobagoResponseWriter writer)
           
static String replaceStyleAttribute(String style, String name, String value)
          Deprecated.  
static void replaceStyleAttribute(UIComponent component, String styleAttribute, int value)
           
static void replaceStyleAttribute(UIComponent component, String styleAttribute, String value)
           
static void replaceStyleAttribute(UIComponent component, String attribute, String styleAttribute, int value)
           
static void replaceStyleAttribute(UIComponent component, String attribute, String styleAttribute, String value)
           
static void setDefaultTransition(FacesContext facesContext, boolean transition)
           
static void startJavascript(ResponseWriter writer)
          Deprecated. use TobagoResponseWriter.writeJavascript()
static String toStyleString(String key, Integer value)
           
static String toStyleString(String key, String value)
           
static void updateClassAttribute(String cssClass, String rendererName, UIComponent component)
          Deprecated. Please use StyleClasses.ensureStyleClasses(component).updateClassAttribute(renderer, component);
static void writeJavascript(ResponseWriter writer, String script)
          Deprecated. use TobagoResponseWriter.writeJavascript()
static void writeLabelWithAccessKey(TobagoResponseWriter writer, LabelWithAccessKey label)
           
static void writeScriptLoader(FacesContext facesContext, String script)
           
static void writeScriptLoader(FacesContext facesContext, String[] scripts, String[] afterLoadCmds)
           
static void writeStyleLoader(FacesContext facesContext, String[] styles)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

renderFocusId

public static void renderFocusId(FacesContext facesContext,
                                 UIComponent component)
                          throws IOException
Throws:
IOException

renderFocusId

public static void renderFocusId(FacesContext facesContext,
                                 UIInput component)
                          throws IOException
Throws:
IOException

prepareRender

public static void prepareRender(FacesContext facesContext,
                                 UIComponent component)

prepareInnerStyle

public static HtmlStyleMap prepareInnerStyle(UIComponent component)

createCssClass

public static void createCssClass(FacesContext facesContext,
                                  UIComponent component)

getRendererName

public static String getRendererName(FacesContext facesContext,
                                     UIComponent component)

writeLabelWithAccessKey

public static void writeLabelWithAccessKey(TobagoResponseWriter writer,
                                           LabelWithAccessKey label)
                                    throws IOException
Throws:
IOException

setDefaultTransition

public static void setDefaultTransition(FacesContext facesContext,
                                        boolean transition)
                                 throws IOException
Throws:
IOException

addClickAcceleratorKey

public static void addClickAcceleratorKey(FacesContext facesContext,
                                          String clientId,
                                          char key)
                                   throws IOException
Throws:
IOException

addClickAcceleratorKey

public static void addClickAcceleratorKey(FacesContext facesContext,
                                          String clientId,
                                          char key,
                                          String modifier)
                                   throws IOException
Throws:
IOException

addAcceleratorKey

public static void addAcceleratorKey(FacesContext facesContext,
                                     String func,
                                     char key)
                              throws IOException
Throws:
IOException

addAcceleratorKey

public static void addAcceleratorKey(FacesContext facesContext,
                                     String func,
                                     char key,
                                     String modifier)
                              throws IOException
Throws:
IOException

createOnclickAcceleratorKeyJsStatement

public static String createOnclickAcceleratorKeyJsStatement(String clientId,
                                                            char key,
                                                            String modifier)

createAcceleratorKeyJsStatement

public static String createAcceleratorKeyJsStatement(String func,
                                                     char key,
                                                     String modifier)

getLayoutSpaceStyle

public static String getLayoutSpaceStyle(UIComponent component)

getStyleAttributeIntValue

public static Integer getStyleAttributeIntValue(HtmlStyleMap style,
                                                String name)

getStyleAttributeValue

public static String getStyleAttributeValue(String style,
                                            String name)

replaceStyleAttribute

public static void replaceStyleAttribute(UIComponent component,
                                         String styleAttribute,
                                         String value)

replaceStyleAttribute

public static void replaceStyleAttribute(UIComponent component,
                                         String attribute,
                                         String styleAttribute,
                                         String value)

replaceStyleAttribute

public static void replaceStyleAttribute(UIComponent component,
                                         String styleAttribute,
                                         int value)

replaceStyleAttribute

public static void replaceStyleAttribute(UIComponent component,
                                         String attribute,
                                         String styleAttribute,
                                         int value)

replaceStyleAttribute

public static String replaceStyleAttribute(String style,
                                           String name,
                                           String value)
Deprecated. 


removeStyleAttribute

public static String removeStyleAttribute(String style,
                                          String name)
Deprecated. 


removeStyleAttribute

public static void removeStyleAttribute(UIComponent component,
                                        String name)

addCssClass

@Deprecated
public static void addCssClass(UIComponent component,
                                          String clazz)
Deprecated. Please use StyleClasses.ensureStyleClasses(component).add(clazz);


layoutWidth

public static void layoutWidth(FacesContext facesContext,
                               UIComponent component)

layoutHeight

public static void layoutHeight(FacesContext facesContext,
                                UIComponent component)

layoutSpace

public static void layoutSpace(FacesContext facesContext,
                               UIComponent component,
                               boolean width)

createHeaderAndBodyStyles

public static void createHeaderAndBodyStyles(FacesContext facesContext,
                                             UIComponent component)

createHeaderAndBodyStyles

public static void createHeaderAndBodyStyles(FacesContext facesContext,
                                             UIComponent component,
                                             boolean width)

updateClassAttribute

@Deprecated
public static void updateClassAttribute(String cssClass,
                                                   String rendererName,
                                                   UIComponent component)
Deprecated. Please use StyleClasses.ensureStyleClasses(component).updateClassAttribute(renderer, component);


addMarkupClass

@Deprecated
public static void addMarkupClass(UIComponent component,
                                             String rendererName,
                                             String subComponent,
                                             StringBuilder tobagoClass)
Deprecated. Please use StyleClasses.addMarkupClass()


addMarkupClass

@Deprecated
public static void addMarkupClass(UIComponent component,
                                             String rendererName,
                                             StyleClasses classes)
Deprecated. Please use StyleClasses.addMarkupClass()


addImageSources

public static void addImageSources(FacesContext facesContext,
                                   TobagoResponseWriter writer,
                                   String src,
                                   String id)
                            throws IOException
Throws:
IOException

createSrc

public static String createSrc(String src,
                               String ext)

getTobagoResponseWriter

public static TobagoResponseWriter getTobagoResponseWriter(FacesContext facesContext)

writeJavascript

@Deprecated
public static void writeJavascript(ResponseWriter writer,
                                              String script)
                            throws IOException
Deprecated. use TobagoResponseWriter.writeJavascript()

Throws:
IOException

startJavascript

@Deprecated
public static void startJavascript(ResponseWriter writer)
                            throws IOException
Deprecated. use TobagoResponseWriter.writeJavascript()

Throws:
IOException

endJavascript

@Deprecated
public static void endJavascript(ResponseWriter writer)
                          throws IOException
Deprecated. use TobagoResponseWriter.writeJavascript()

Throws:
IOException

writeScriptLoader

public static void writeScriptLoader(FacesContext facesContext,
                                     String script)
                              throws IOException
Throws:
IOException

writeScriptLoader

public static void writeScriptLoader(FacesContext facesContext,
                                     String[] scripts,
                                     String[] afterLoadCmds)
                              throws IOException
Throws:
IOException

writeStyleLoader

public static void writeStyleLoader(FacesContext facesContext,
                                    String[] styles)
                             throws IOException
Throws:
IOException

getTitleFromTipAndMessages

public static String getTitleFromTipAndMessages(FacesContext facesContext,
                                                UIComponent component)

addTip

public static String addTip(String title,
                            Object tip)

renderSelectItems

public static void renderSelectItems(UIInput component,
                                     List<SelectItem> items,
                                     Object[] values,
                                     TobagoResponseWriter writer,
                                     FacesContext facesContext)
                              throws IOException
Throws:
IOException

getComponentId

public static String getComponentId(FacesContext context,
                                    UIComponent component,
                                    String componentId)

toStyleString

public static String toStyleString(String key,
                                   Integer value)

toStyleString

public static String toStyleString(String key,
                                   String value)

renderTip

public static void renderTip(UIComponent component,
                             TobagoResponseWriter writer)
                      throws IOException
Throws:
IOException

renderImageTip

public static void renderImageTip(UIComponent component,
                                  TobagoResponseWriter writer)
                           throws IOException
Throws:
IOException

getJavascriptString

public static String getJavascriptString(String str)

getRenderedPartiallyJavascriptArray

public static String getRenderedPartiallyJavascriptArray(FacesContext facesContext,
                                                         UICommand command)

getJavascriptArray

public static String getJavascriptArray(String[] list)

removeStyleClasses

public static void removeStyleClasses(UIComponent cell)


Copyright © 2002-2011 Apache Software Foundation. All Rights Reserved.