Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
s Guide
3.31 Editor
Editor is an input component with rich text editing capabilities.
Info
Tag Component Class Component Type Component Family Renderer Type Renderer Class editor org.primefaces.component.editor.Editor org.primefaces.component.Editor org.primefaces.component org.primefaces.component.EditorRenderer org.primefaces.component.editor.EditorRenderer
Attributes
Name id rendered binding value converter Default null TRUE null null null Type String Boolean Object Object Converter/ String Description Unique identifier of the component. Boolean value to specify the rendering of the component. An el expression that maps to a server side UIComponent instance in a backing bean. Value of the component than can be either an EL expression of a literal text. An el expression or a literal text that defines a converter for the component. When its an EL expression, its resolved to a converter instance. In case its a static text, it must refer to a converter id.
166
Name immediate
Default FALSE
Type Boolean
Description When set true, process validations logic is executed at apply request values phase for this component. Marks component as required. A method expression that refers to a method validationg the input. A method expression that refers to a method for handling a valuchangeevent. Message to be displayed when required field validation fails. Message to be displayed when conversion fails. Message to be displayed when validation fails. Name of the client side widget. List of controls to customize toolbar. Height of the editor. Width of the editor. Disables editor. Inline style of the editor container. Style class of the editor container. Client side callback to execute when editor data changes.
required validator valueChangeListener requiredMessage converterMessage validatorMessage widgetVar controls height width disabled style styleClass onchange
FALSE null null null null null null null null null FALSE null null null
Boolean MethodExpr MethodExpr String String String String String Integer Integer Boolean String String String
Getting started with the Editor Rich Text entered using the Editor is passed to the server using value expression.
public class Bean { ! ! ! private String text; //getter and setter
167
Here is the full list of all available controls; bold italic underline strikethrough subscript superscript font size style color highlight bullets numbering alignleft center alignright justify undo redo rule image link unlink cut copy paste pastetext print source outdent indent removeFormat
Description Initializes a lazy editor, subsequent calls do not reinit the editor. Saves html text in iframe back to the textarea. Clears the text in editor.
Params -
Return Type void void void void String String Enables editing. Disables editing.
Description
Adds cursor focus to edit area. Selects all text in editor. Returns selected text as HTML. Returns selected text in plain format.
Editor is not integrated with ThemeRoller as there is only one icon set for the controls.
169