OSDN Git Service

初回コミット(v2.6.17.1)
[magic3/magic3.git] / scripts / m3 / ckconfig_safe.js
1 /*
2  * CKEditor(WYSIWYGエディター)の設定
3  *
4  * LICENSE: This source file is licensed under the terms of the GNU General Public License.
5  *
6  * @package    Magic3 Framework
7  * @author     平田直毅(Naoki Hirata) <naoki@aplo.co.jp>
8  * @copyright  Copyright 2006-2013 Magic3 Project.
9  * @license    http://www.gnu.org/copyleft/gpl.html  GPL License
10  * @version    SVN: $Id: ckconfig_safe.js 6074 2013-06-04 12:57:46Z fishbone $
11  * @link       http://www.magic3.org
12  */
13 // デフォルトスタイル定義
14 CKEDITOR.stylesSet.add( 'default', []);
15
16 CKEDITOR.editorConfig = function( config ) {
17         config.language = 'ja';
18 //      config.enterMode = CKEDITOR.ENTER_BR; // 改行をbrに変更
19 //      config.shiftEnterMode = CKEDITOR.ENTER_DIV;
20 //      config.autoParagraph = false;
21 //      config.fillEmptyBlocks = false;         // 「&nbsp;」が自動的に入るのを防ぐ
22 //      config.toolbarCanCollapse = true;               // ツールバー表示制御
23         
24         // ツールバーの設定
25         config.toolbar_Safe = [
26 //              { name: 'debug', items: [ 'Source' ] },
27                 { name: 'basicstyles', items: [ 'Bold', 'Italic', 'Underline' ] },
28                 { name: 'colors', items : [ 'TextColor' ] },
29 //              { name: 'styles', items: [ 'FontSize' ] },              // bug?
30                 { name: 'insert', items: [ 'Image' ] }
31         ];
32         
33         // 追加プラグインの設定
34         config.extraPlugins = 'bbcode';
35         config.removePlugins = 'elementspath';
36 };
37 /*
38 CKEDITOR.on('dialogDefinition', function(ev){
39         var dialogName = ev.data.name;
40         var dialogDefinition = ev.data.definition;
41         var dialog = dialogDefinition.dialog;
42         
43         if (dialogName == 'image'){
44                 dialogDefinition.removeContents('Link');        // 「リンク」タブ削除
45         }
46 });*/