public abstract class RichTextAreaImplStandard extends RichTextAreaImpl implements RichTextArea.Formatter
Modifier and Type | Field and Description |
---|---|
protected boolean |
initializing
Set to true when the
RichTextArea is attached to the page and
initElement() is called. |
elem, owner
Constructor and Description |
---|
RichTextAreaImplStandard() |
Modifier and Type | Method and Description |
---|---|
Element |
createElement() |
void |
createLink(String url)
Creates a link to the supplied URL.
|
String |
getBackColor()
Gets the background color.
|
String |
getForeColor()
Gets the foreground color.
|
String |
getHTML() |
protected String |
getHTMLImpl() |
String |
getText() |
protected String |
getTextImpl() |
protected void |
hookEvents() |
void |
initElement() |
void |
insertHorizontalRule()
Inserts a horizontal rule.
|
void |
insertHTML(String html)
Inserts generic html.
|
void |
insertImage(String url)
Inserts an image element.
|
void |
insertOrderedList()
Starts an numbered list.
|
void |
insertUnorderedList()
Starts an bulleted list.
|
boolean |
isBold()
Is the current region bold?
|
boolean |
isEnabled() |
protected boolean |
isEnabledImpl() |
boolean |
isItalic()
Is the current region italic?
|
boolean |
isStrikethrough()
Is the current region strikethrough?
|
boolean |
isSubscript()
Is the current region subscript?
|
boolean |
isSuperscript()
Is the current region superscript?
|
boolean |
isUnderlined()
Is the current region underlined?
|
void |
leftIndent()
Left indent.
|
protected void |
onElementInitialized() |
protected void |
onElementInitializing() |
void |
redo()
Redo an action that was just undone.
|
void |
removeFormat()
Removes all formatting on the selected text.
|
void |
removeLink()
Removes any link from the selected text.
|
void |
rightIndent()
Right indent.
|
void |
selectAll()
Selects all the text.
|
void |
setBackColor(String color)
Sets the background color.
|
void |
setEnabled(boolean enabled) |
protected void |
setEnabledImpl(boolean enabled) |
void |
setFocus(boolean focused) |
protected void |
setFocusImpl(boolean focused) |
void |
setFontName(String name)
Sets the font name.
|
void |
setFontSize(RichTextArea.FontSize fontSize)
Sets the font size.
|
void |
setForeColor(String color)
Sets the foreground color.
|
void |
setHTML(String html) |
protected void |
setHTMLImpl(String html) |
void |
setJustification(RichTextArea.Justification justification)
Sets the justification.
|
void |
setText(String text) |
protected void |
setTextImpl(String text) |
void |
toggleBold()
Toggles bold.
|
void |
toggleItalic()
Toggles italic.
|
void |
toggleStrikethrough()
Toggles strikethrough.
|
void |
toggleSubscript()
Toggles subscript.
|
void |
toggleSuperscript()
Toggles superscript.
|
void |
toggleUnderline()
Toggles underline.
|
void |
undo()
Undo the last action.
|
protected void |
unhookEvents() |
void |
uninitElement() |
getElement, setOwner, setWidget
protected boolean initializing
RichTextArea
is attached to the page and
initElement()
is called. If the RichTextArea
is detached
before onElementInitialized()
is called, this will be set to
false. See issue 1897 for details.public Element createElement()
createElement
in class RichTextAreaImpl
public void createLink(String url)
RichTextArea.Formatter
createLink
in interface RichTextArea.ExtendedFormatter
createLink
in interface RichTextArea.Formatter
url
- the URL to be linked topublic String getBackColor()
RichTextArea.Formatter
getBackColor
in interface RichTextArea.BasicFormatter
getBackColor
in interface RichTextArea.Formatter
public String getForeColor()
RichTextArea.Formatter
getForeColor
in interface RichTextArea.BasicFormatter
getForeColor
in interface RichTextArea.Formatter
public final String getHTML()
getHTML
in class RichTextAreaImpl
public final String getText()
getText
in class RichTextAreaImpl
public void initElement()
initElement
in class RichTextAreaImpl
public void insertHorizontalRule()
RichTextArea.Formatter
insertHorizontalRule
in interface RichTextArea.ExtendedFormatter
insertHorizontalRule
in interface RichTextArea.Formatter
public void insertHTML(String html)
RichTextArea.Formatter
insertHTML
in interface RichTextArea.Formatter
html
- the HTML to insertpublic void insertImage(String url)
RichTextArea.Formatter
insertImage
in interface RichTextArea.ExtendedFormatter
insertImage
in interface RichTextArea.Formatter
url
- the url of the image to be insertedpublic void insertOrderedList()
RichTextArea.Formatter
insertOrderedList
in interface RichTextArea.ExtendedFormatter
insertOrderedList
in interface RichTextArea.Formatter
public void insertUnorderedList()
RichTextArea.Formatter
insertUnorderedList
in interface RichTextArea.ExtendedFormatter
insertUnorderedList
in interface RichTextArea.Formatter
public boolean isBold()
RichTextArea.Formatter
isBold
in interface RichTextArea.BasicFormatter
isBold
in interface RichTextArea.Formatter
public boolean isEnabled()
isEnabled
in class RichTextAreaImpl
public boolean isItalic()
RichTextArea.Formatter
isItalic
in interface RichTextArea.BasicFormatter
isItalic
in interface RichTextArea.Formatter
public boolean isStrikethrough()
RichTextArea.Formatter
isStrikethrough
in interface RichTextArea.ExtendedFormatter
isStrikethrough
in interface RichTextArea.Formatter
public boolean isSubscript()
RichTextArea.Formatter
isSubscript
in interface RichTextArea.BasicFormatter
isSubscript
in interface RichTextArea.Formatter
public boolean isSuperscript()
RichTextArea.Formatter
isSuperscript
in interface RichTextArea.BasicFormatter
isSuperscript
in interface RichTextArea.Formatter
public boolean isUnderlined()
RichTextArea.Formatter
isUnderlined
in interface RichTextArea.BasicFormatter
isUnderlined
in interface RichTextArea.Formatter
public void leftIndent()
RichTextArea.Formatter
leftIndent
in interface RichTextArea.ExtendedFormatter
leftIndent
in interface RichTextArea.Formatter
public void redo()
RichTextArea.Formatter
redo
in interface RichTextArea.Formatter
public void removeFormat()
RichTextArea.Formatter
removeFormat
in interface RichTextArea.ExtendedFormatter
removeFormat
in interface RichTextArea.Formatter
public void removeLink()
RichTextArea.Formatter
removeLink
in interface RichTextArea.ExtendedFormatter
removeLink
in interface RichTextArea.Formatter
public void rightIndent()
RichTextArea.Formatter
rightIndent
in interface RichTextArea.ExtendedFormatter
rightIndent
in interface RichTextArea.Formatter
public void selectAll()
RichTextArea.Formatter
selectAll
in interface RichTextArea.BasicFormatter
selectAll
in interface RichTextArea.Formatter
public void setBackColor(String color)
RichTextArea.Formatter
setBackColor
in interface RichTextArea.BasicFormatter
setBackColor
in interface RichTextArea.Formatter
color
- the new background colorpublic void setEnabled(boolean enabled)
setEnabled
in class RichTextAreaImpl
public void setFocus(boolean focused)
setFocus
in class RichTextAreaImpl
public void setFontName(String name)
RichTextArea.Formatter
setFontName
in interface RichTextArea.BasicFormatter
setFontName
in interface RichTextArea.Formatter
name
- the new font namepublic void setFontSize(RichTextArea.FontSize fontSize)
RichTextArea.Formatter
setFontSize
in interface RichTextArea.BasicFormatter
setFontSize
in interface RichTextArea.Formatter
fontSize
- the new font sizepublic void setForeColor(String color)
RichTextArea.Formatter
setForeColor
in interface RichTextArea.BasicFormatter
setForeColor
in interface RichTextArea.Formatter
color
- the new foreground colorpublic final void setHTML(String html)
setHTML
in class RichTextAreaImpl
public void setJustification(RichTextArea.Justification justification)
RichTextArea.Formatter
setJustification
in interface RichTextArea.BasicFormatter
setJustification
in interface RichTextArea.Formatter
justification
- the new justificationpublic final void setText(String text)
setText
in class RichTextAreaImpl
public void toggleBold()
RichTextArea.Formatter
toggleBold
in interface RichTextArea.BasicFormatter
toggleBold
in interface RichTextArea.Formatter
public void toggleItalic()
RichTextArea.Formatter
toggleItalic
in interface RichTextArea.BasicFormatter
toggleItalic
in interface RichTextArea.Formatter
public void toggleStrikethrough()
RichTextArea.Formatter
toggleStrikethrough
in interface RichTextArea.ExtendedFormatter
toggleStrikethrough
in interface RichTextArea.Formatter
public void toggleSubscript()
RichTextArea.Formatter
toggleSubscript
in interface RichTextArea.BasicFormatter
toggleSubscript
in interface RichTextArea.Formatter
public void toggleSuperscript()
RichTextArea.Formatter
toggleSuperscript
in interface RichTextArea.BasicFormatter
toggleSuperscript
in interface RichTextArea.Formatter
public void toggleUnderline()
RichTextArea.Formatter
toggleUnderline
in interface RichTextArea.BasicFormatter
toggleUnderline
in interface RichTextArea.Formatter
public void undo()
RichTextArea.Formatter
undo
in interface RichTextArea.Formatter
public void uninitElement()
uninitElement
in class RichTextAreaImpl
protected String getHTMLImpl()
protected String getTextImpl()
protected void hookEvents()
hookEvents
in class RichTextAreaImpl
protected boolean isEnabledImpl()
protected void onElementInitialized()
onElementInitialized
in class RichTextAreaImpl
protected void onElementInitializing()
protected void setEnabledImpl(boolean enabled)
protected void setFocusImpl(boolean focused)
protected void setHTMLImpl(String html)
protected void setTextImpl(String text)
protected void unhookEvents()
Copyright © 2018. All rights reserved.