wicket.contrib.tinymce
Class TinyMceBehavior

java.lang.Object
  extended by org.apache.wicket.behavior.Behavior
      extended by wicket.contrib.tinymce.TinyMceBehavior
All Implemented Interfaces:
Serializable, org.apache.wicket.IComponentAwareEventSink, org.apache.wicket.markup.html.IComponentAwareHeaderContributor, org.apache.wicket.util.io.IClusterable
Direct Known Subclasses:
InPlaceEditBehavior

public class TinyMceBehavior
extends org.apache.wicket.behavior.Behavior

Renders a component (textarea) as WYSIWYG editor, using TinyMce.

See Also:
Serialized Form

Constructor Summary
TinyMceBehavior()
           
TinyMceBehavior(TinyMCESettings settings)
           
 
Method Summary
 void bind(org.apache.wicket.Component component)
           
protected  String getAddTinyMceSettingsScript(TinyMCESettings.Mode mode, Collection<org.apache.wicket.Component> components)
           
protected  org.apache.wicket.Component getComponent()
           
protected  boolean isMarkupIdRequired()
           
 void renderHead(org.apache.wicket.Component c, org.apache.wicket.markup.head.IHeaderResponse response)
           
protected  org.apache.wicket.markup.head.HeaderItem wrapTinyMceSettingsScript(String settingScript, org.apache.wicket.Component component)
          Wrap the initialization script for TinyMCE into a HeaderItem.
 
Methods inherited from class org.apache.wicket.behavior.Behavior
afterRender, beforeRender, canCallListenerInterface, detach, getStatelessHint, isEnabled, isTemporary, onComponentTag, onConfigure, onEvent, onException, onRemove, unbind
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TinyMceBehavior

public TinyMceBehavior()

TinyMceBehavior

public TinyMceBehavior(TinyMCESettings settings)
Method Detail

renderHead

public void renderHead(org.apache.wicket.Component c,
                       org.apache.wicket.markup.head.IHeaderResponse response)
Specified by:
renderHead in interface org.apache.wicket.markup.html.IComponentAwareHeaderContributor
Overrides:
renderHead in class org.apache.wicket.behavior.Behavior

wrapTinyMceSettingsScript

protected org.apache.wicket.markup.head.HeaderItem wrapTinyMceSettingsScript(String settingScript,
                                                                             org.apache.wicket.Component component)
Wrap the initialization script for TinyMCE into a HeaderItem. In this way we can control when and how the script should be executed.

Parameters:
settingScript - the actual initialization script for TinyMCE
component - the target component that must be decorated with TinyMCE
Returns:
the HeaderItem containing

getAddTinyMceSettingsScript

protected String getAddTinyMceSettingsScript(TinyMCESettings.Mode mode,
                                             Collection<org.apache.wicket.Component> components)

bind

public void bind(org.apache.wicket.Component component)
Overrides:
bind in class org.apache.wicket.behavior.Behavior

isMarkupIdRequired

protected boolean isMarkupIdRequired()

getComponent

protected org.apache.wicket.Component getComponent()


Copyright © 2004–2016. All rights reserved.