JasonWoof Got questions, comments, patches, etc.? Contact Jason Woofenden
vanilla ckeditor-3.4.2
[ckeditor.git] / _source / core / config.js
index f7a2ad7..a408d93 100644 (file)
@@ -8,19 +8,34 @@ For licensing, see LICENSE.html or http://ckeditor.com/license
  * default configuration settings.\r
  */\r
 \r
+/**\r
+ * Used in conjuction with {@link CKEDITOR.config.enterMode} and\r
+ * {@link CKEDITOR.config.shiftEnterMode} to make the editor produce <p>\r
+ * tags when using the ENTER key.\r
+ * @constant\r
+ */\r
 CKEDITOR.ENTER_P       = 1;\r
+\r
+/**\r
+ * Used in conjuction with {@link CKEDITOR.config.enterMode} and\r
+ * {@link CKEDITOR.config.shiftEnterMode} to make the editor produce <br>\r
+ * tags when using the ENTER key.\r
+ * @constant\r
+ */\r
 CKEDITOR.ENTER_BR      = 2;\r
+\r
+/**\r
+ * Used in conjuction with {@link CKEDITOR.config.enterMode} and\r
+ * {@link CKEDITOR.config.shiftEnterMode} to make the editor produce <div>\r
+ * tags when using the ENTER key.\r
+ * @constant\r
+ */\r
 CKEDITOR.ENTER_DIV     = 3;\r
 \r
 /**\r
- * Holds the default configuration settings. Changes to this object are\r
+ * @namespace Holds the default configuration settings. Changes to this object are\r
  * reflected in all editor instances, if not specificaly specified for those\r
  * instances.\r
- * @namespace\r
- * @example\r
- * // All editor created after the following setting will not load custom\r
- * // configuration files.\r
- * CKEDITOR.config.customConfig = '';\r
  */\r
 CKEDITOR.config =\r
 {\r
@@ -56,7 +71,7 @@ CKEDITOR.config =
         * The base href URL used to resolve relative and absolute URLs in the\r
         * editor content.\r
         * @type String\r
-        * @default '' (empty string)\r
+        * @default '' (empty)\r
         * @example\r
         * config.baseHref = 'http://www.example.com/path/';\r
         */\r
@@ -76,21 +91,35 @@ CKEDITOR.config =
 \r
        /**\r
         * The writting direction of the language used to write the editor\r
-        * contents. Allowed values are 'ltr' for Left-To-Right language (like\r
-        * English), or 'rtl' for Right-To-Left languages (like Arabic).\r
-        * @default 'ltr'\r
+        * contents. Allowed values are:\r
+        * <ul>\r
+        *     <li>'ui' - which indicate content direction will be the same with the user interface language direction;</li>\r
+        *     <li>'ltr' - for Left-To-Right language (like English);</li>\r
+        *     <li>'rtl' - for Right-To-Left languages (like Arabic).</li>\r
+        * </ul>\r
+        * @default 'ui'\r
         * @type String\r
         * @example\r
         * config.contentsLangDirection = 'rtl';\r
         */\r
-       contentsLangDirection : 'ltr',\r
+       contentsLangDirection : 'ui',\r
+\r
+       /**\r
+        * Language code of  the writting language which is used to author the editor\r
+        * contents.\r
+        * @default Same value with editor's UI language.\r
+        * @type String\r
+        * @example\r
+        * config.contentsLanguage = 'fr';\r
+        */\r
+       contentsLanguage : '',\r
 \r
        /**\r
         * The user interface language localization to use. If empty, the editor\r
         * automatically localize the editor to the user language, if supported,\r
         * otherwise the {@link CKEDITOR.config.defaultLanguage} language is used.\r
-        * @default true\r
-        * @type Boolean\r
+        * @default '' (empty)\r
+        * @type String\r
         * @example\r
         * // Load the German interface.\r
         * config.language = 'de';\r
@@ -130,6 +159,18 @@ CKEDITOR.config =
        enterMode : CKEDITOR.ENTER_P,\r
 \r
        /**\r
+        * Force the respect of {@link CKEDITOR.config.enterMode} as line break regardless of the context,\r
+        * E.g. If {@link CKEDITOR.config.enterMode} is set to {@link CKEDITOR.ENTER_P},\r
+        * press enter key inside a 'div' will create a new paragraph with 'p' instead of 'div'.\r
+        * @since 3.2.1\r
+        * @default false\r
+        * @example\r
+        * // Not recommended.\r
+        * config.forceEnterMode = true;\r
+        */\r
+       forceEnterMode : false,\r
+\r
+       /**\r
         * Just like the {@link CKEDITOR.config.enterMode} setting, it defines the behavior for the SHIFT+ENTER key.\r
         * The allowed values are the following constants, and their relative\r
         * behavior:\r
@@ -167,16 +208,30 @@ CKEDITOR.config =
        docType : '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">',\r
 \r
        /**\r
-        * Sets the 'id' attribute to be used on body if it doesn't have one.\r
+        * Sets the "id" attribute to be used on the body element of the editing\r
+        * area. This can be useful when reusing the original CSS file you're using\r
+        * on your live website and you want to assing to the editor the same id\r
+        * you're using for the region that'll hold the contents. In this way,\r
+        * id specific CSS rules will be enabled.\r
+        * @since 3.1\r
         * @type String\r
-        * @default ''\r
+        * @default '' (empty)\r
+        * @example\r
+        * config.bodyId = 'contents_id';\r
         */\r
        bodyId : '',\r
 \r
        /**\r
-        * Sets the 'class' attribute to be used on body if it doesn't have one.\r
+        * Sets the "class" attribute to be used on the body element of the editing\r
+        * area. This can be useful when reusing the original CSS file you're using\r
+        * on your live website and you want to assing to the editor the same class\r
+        * name you're using for the region that'll hold the contents. In this way,\r
+        * class specific CSS rules will be enabled.\r
+        * @since 3.1\r
         * @type String\r
-        * @default ''\r
+        * @default '' (empty)\r
+        * @example\r
+        * config.bodyClass = 'contents';\r
         */\r
        bodyClass : '',\r
 \r
@@ -185,6 +240,7 @@ CKEDITOR.config =
         * HTML page. A full page includes the &lt;html&gt;, &lt;head&gt; and\r
         * &lt;body&gt; tags. The final output will also reflect this setting,\r
         * including the &lt;body&gt; contents only if this setting is disabled.\r
+        * @since 3.1\r
         * @type Boolean\r
         * @default false\r
         * @example\r
@@ -212,7 +268,63 @@ CKEDITOR.config =
         * @type String\r
         * @example\r
         */\r
-       plugins : 'about,basicstyles,blockquote,button,clipboard,colorbutton,colordialog,contextmenu,div,elementspath,enterkey,entities,filebrowser,find,flash,font,format,forms,horizontalrule,htmldataprocessor,image,indent,justify,keystrokes,link,list,maximize,newpage,pagebreak,pastefromword,pastetext,popup,preview,print,removeformat,resize,save,scayt,smiley,showblocks,showborders,sourcearea,stylescombo,table,tabletools,specialchar,tab,templates,toolbar,undo,wysiwygarea,wsc',\r
+       plugins :\r
+               'about,' +\r
+               'a11yhelp,' +\r
+               'basicstyles,' +\r
+               'bidi,' +\r
+               'blockquote,' +\r
+               'button,' +\r
+               'clipboard,' +\r
+               'colorbutton,' +\r
+               'colordialog,' +\r
+               'contextmenu,' +\r
+               'dialogadvtab,' +\r
+               'div,' +\r
+               'elementspath,' +\r
+               'enterkey,' +\r
+               'entities,' +\r
+               'filebrowser,' +\r
+               'find,' +\r
+               'flash,' +\r
+               'font,' +\r
+               'format,' +\r
+               'forms,' +\r
+               'horizontalrule,' +\r
+               'htmldataprocessor,' +\r
+               'image,' +\r
+               'indent,' +\r
+               'justify,' +\r
+               'keystrokes,' +\r
+               'link,' +\r
+               'list,' +\r
+               'liststyle,' +\r
+               'maximize,' +\r
+               'newpage,' +\r
+               'pagebreak,' +\r
+               'pastefromword,' +\r
+               'pastetext,' +\r
+               'popup,' +\r
+               'preview,' +\r
+               'print,' +\r
+               'removeformat,' +\r
+               'resize,' +\r
+               'save,' +\r
+               'scayt,' +\r
+               'smiley,' +\r
+               'showblocks,' +\r
+               'showborders,' +\r
+               'sourcearea,' +\r
+               'stylescombo,' +\r
+               'table,' +\r
+               'tabletools,' +\r
+               'specialchar,' +\r
+               'tab,' +\r
+               'templates,' +\r
+               'toolbar,' +\r
+               'undo,' +\r
+               'wysiwygarea,' +\r
+               'wsc',\r
 \r
        /**\r
         * List of additional plugins to be loaded. This is a tool setting which\r
@@ -299,4 +411,20 @@ CKEDITOR.config =
        baseFloatZIndex : 10000\r
 };\r
 \r
+/**\r
+ * Indicates that some of the editor features, like alignment and text\r
+ * direction, should used the "computed value" of the feature to indicate it's\r
+ * on/off state, instead of using the "real value".<br />\r
+ * <br />\r
+ * If enabled, in a left to right written document, the "Left Justify"\r
+ * alignment button will show as active, even if the aligment style is not\r
+ * explicitly applied to the current paragraph in the editor.\r
+ * @name CKEDITOR.config.useComputedState\r
+ * @type Boolean\r
+ * @default true\r
+ * @since 3.4\r
+ * @example\r
+ * config.useComputedState = false;\r
+ */\r
+\r
 // PACKAGER_RENAME( CKEDITOR.config )\r