Package com.google.gwt.user.client.ui
Class InlineHTML
java.lang.Object
com.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.Widget
com.google.gwt.user.client.ui.LabelBase<String>
com.google.gwt.user.client.ui.Label
com.google.gwt.user.client.ui.HTML
com.google.gwt.user.client.ui.InlineHTML
- All Implemented Interfaces:
- IsEditor<LeafValueEditor<String>>,- HasAllDragAndDropHandlers,- HasAllGestureHandlers,- HasAllMouseHandlers,- HasAllTouchHandlers,- HasClickHandlers,- HasDoubleClickHandlers,- HasDragEndHandlers,- HasDragEnterHandlers,- HasDragHandlers,- HasDragLeaveHandlers,- HasDragOverHandlers,- HasDragStartHandlers,- HasDropHandlers,- HasGestureChangeHandlers,- HasGestureEndHandlers,- HasGestureStartHandlers,- HasMouseDownHandlers,- HasMouseMoveHandlers,- HasMouseOutHandlers,- HasMouseOverHandlers,- HasMouseUpHandlers,- HasMouseWheelHandlers,- HasTouchCancelHandlers,- HasTouchEndHandlers,- HasTouchMoveHandlers,- HasTouchStartHandlers,- HasAttachHandlers,- HasHandlers,- HasDirection,- HasDirectionEstimator,- HasSafeHtml,- EventListener,- HasAutoHorizontalAlignment,- HasDirectionalHtml,- HasDirectionalSafeHtml,- HasDirectionalText,- HasHorizontalAlignment,- HasHTML,- HasText,- HasVisibility,- HasWordWrap,- IsWidget,- SourcesClickEvents,- SourcesMouseEvents
A widget that can contain arbitrary HTML.
 This widget uses a <span> element, causing it to be displayed with
 inline layout.
 
 If you only need a simple label (text, but not HTML), then the
 Label widget is more appropriate, as it
 disallows the use of HTML, which can lead to potential security issues if not
 used properly.
 
Built-in Bidi Text Support
This widget is capable of automatically adjusting its direction according to its content. This feature is controlled byLabelBase.setDirectionEstimator(boolean) or
 passing a DirectionEstimator parameter to the constructor, and is off by
 default.
 
 CSS Style Rules
- .gwt-InlineHTML { }
- 
Nested Class SummaryNested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObjectUIObject.DebugIdImpl, UIObject.DebugIdImplEnabledNested classes/interfaces inherited from interface com.google.gwt.i18n.client.HasDirectionHasDirection.DirectionNested classes/interfaces inherited from interface com.google.gwt.user.client.ui.HasHorizontalAlignmentHasHorizontalAlignment.AutoHorizontalAlignmentConstant, HasHorizontalAlignment.HorizontalAlignmentConstant
- 
Field SummaryFields inherited from class com.google.gwt.user.client.ui.LabelDEFAULT_DIRECTION_ESTIMATORFields inherited from class com.google.gwt.user.client.ui.LabelBasedirectionalTextHelperFields inherited from class com.google.gwt.user.client.ui.WidgeteventsToSinkFields inherited from class com.google.gwt.user.client.ui.UIObjectDEBUG_ID_PREFIX, MISSING_ELEMENT_ERROR, SETELEMENT_TWICE_ERRORFields inherited from interface com.google.gwt.user.client.ui.HasAutoHorizontalAlignmentALIGN_CONTENT_END, ALIGN_CONTENT_STARTFields inherited from interface com.google.gwt.user.client.ui.HasHorizontalAlignmentALIGN_CENTER, ALIGN_DEFAULT, ALIGN_JUSTIFY, ALIGN_LEFT, ALIGN_LOCALE_END, ALIGN_LOCALE_START, ALIGN_RIGHT
- 
Constructor SummaryConstructorsModifierConstructorDescriptionCreates an empty HTML widget.protectedInlineHTML(Element element) This constructor may be used by subclasses to explicitly use an existing element.InlineHTML(SafeHtml html) Initializes the widget's HTML from a givenSafeHtmlobject.InlineHTML(SafeHtml html, HasDirection.Direction dir) Creates an HTML widget with the specified contents and with the specified direction.InlineHTML(SafeHtml html, DirectionEstimator directionEstimator) Creates an HTML widget with the specified HTML contents and with a default direction estimator.InlineHTML(String html) Creates an HTML widget with the specified HTML contents.InlineHTML(String html, HasDirection.Direction dir) Creates an HTML widget with the specified HTML contents and with the specified direction.
- 
Method SummaryModifier and TypeMethodDescriptionstatic InlineHTMLCreates an InlineHTML widget that wraps an existing <div> or <span> element.Methods inherited from class com.google.gwt.user.client.ui.HTMLgetHTML, getTextOrHtml, setHTML, setHTML, setHTML, setHTMLMethods inherited from class com.google.gwt.user.client.ui.LabeladdClickHandler, addClickListener, addDoubleClickHandler, addDragEndHandler, addDragEnterHandler, addDragHandler, addDragLeaveHandler, addDragOverHandler, addDragStartHandler, addDropHandler, addGestureChangeHandler, addGestureEndHandler, addGestureStartHandler, addMouseDownHandler, addMouseListener, addMouseMoveHandler, addMouseOutHandler, addMouseOverHandler, addMouseUpHandler, addMouseWheelHandler, addMouseWheelListener, addTouchCancelHandler, addTouchEndHandler, addTouchMoveHandler, addTouchStartHandler, asEditor, getDirection, getText, getTextDirection, removeClickListener, removeMouseListener, removeMouseWheelListener, setDirection, setText, setTextMethods inherited from class com.google.gwt.user.client.ui.LabelBasegetAutoHorizontalAlignment, getDirectionEstimator, getHorizontalAlignment, getWordWrap, setAutoHorizontalAlignment, setDirectionEstimator, setDirectionEstimator, setHorizontalAlignment, setWordWrap, updateHorizontalAlignmentMethods inherited from class com.google.gwt.user.client.ui.WidgetaddAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, doAttachChildren, doDetachChildren, ensureHandlers, fireEvent, getHandlerCount, getHandlerManager, getLayoutData, getParent, isAttached, isOrWasAttached, onAttach, onBrowserEvent, onDetach, onLoad, onUnload, removeFromParent, replaceElement, setLayoutData, setParent, sinkEvents, unsinkEventsMethods inherited from class com.google.gwt.user.client.ui.UIObjectaddStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, resolvePotentialElement, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toStringMethods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.gwt.user.client.ui.HasDirectionalTextgetTextDirection, setTextMethods inherited from interface com.google.gwt.event.shared.HasHandlersfireEvent
- 
Constructor Details- 
InlineHTMLpublic InlineHTML()Creates an empty HTML widget.
- 
InlineHTMLCreates an HTML widget with the specified HTML contents.- Parameters:
- html- the new widget's HTML contents
 
- 
InlineHTMLCreates an HTML widget with the specified HTML contents and with the specified direction.- Parameters:
- html- the new widget's HTML contents
- dir- the content's direction. Note:- Direction.DEFAULTmeans direction should be inherited from the widget's parent element.
 
- 
InlineHTMLThis constructor may be used by subclasses to explicitly use an existing element. This element must be either a <div> <span> element.- Parameters:
- element- the element to be used
 
 
- 
- 
Method Details- 
wrapCreates an InlineHTML widget that wraps an existing <div> or <span> element. This element must already be attached to the document. If the element is removed from the document, you must callWidget.removeFromParent().- Parameters:
- element- the element to be wrapped
 
 
-