いっぽんの猟銃のむこうに (DAIZOじいさんとGun)

ヌルめの技術メモとか。フリーランスやってます (http://acez.jp/)

<rich:editor>カスタマイズ

TinyMCEベースなので比較的柔軟なカスタマイズが可能

■カスタマイズ方法

以下のようにしてタグを埋め込む

    <rich:editor value=""  configuration="richeditor"/>

クラスパスが通ったところに ${configuration}.propertiesとして設定ファイルを配置
設定内容の詳細はTinyMCEの設定を参照


※例: test/src/richeditor.properties

# rich:editor settings
theme="advanced" 
theme_advanced_toolbar_location="top" 
theme_advanced_toolbar_align="left" 
language="ja" 
# reference by http://wiki.moxiecode.com/index.php/TinyMCE:Control_reference
theme_advanced_buttons1="forecolor,backcolor,separator,bullist,numlist,outdent,indent,undo,redo,hr,removeformat,visualaid,sub,sup,charmap,separator,fontselect,fontsizeselect" 
theme_advanced_buttons2="" 
theme_advanced_buttons3="" 

ツールバーは複数行が可能。デフォルト3行だが設定例では1行に


## 表示可能なボタンについては以下を参照
http://wiki.moxiecode.com/index.php/TinyMCE:Control_reference