JasonWoof Got questions, comments, patches, etc.? Contact Jason Woofenden
vanilla ckeditor-3.6.2
[ckeditor.git] / _source / core / config.js
index 8d45ebe..db77f76 100644 (file)
@@ -4,64 +4,67 @@ For licensing, see LICENSE.html or http://ckeditor.com/license
 */\r
 \r
 /**\r
- * @fileOverview Defines the {@link CKEDITOR.config} object, which holds the\r
+ * @fileOverview Defines the <code>{@link CKEDITOR.config}</code> object that stores the\r
  * 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 &lt;p&gt;\r
- * tags when using the ENTER key.\r
+ * Used in conjunction with <code>{@link CKEDITOR.config.enterMode}</code>\r
+ * and <code>{@link CKEDITOR.config.shiftEnterMode}</code> configuration\r
+ * settings to make the editor produce <code>&lt;p&gt;</code> tags when\r
+ * using the <em>Enter</em> 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 &lt;br&gt;\r
- * tags when using the ENTER key.\r
+ * Used in conjunction with <code>{@link CKEDITOR.config.enterMode}</code>\r
+ * and <code>{@link CKEDITOR.config.shiftEnterMode}</code> configuration\r
+ * settings to make the editor produce <code>&lt;br&gt;</code> tags when\r
+ * using the <em>Enter</em> 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 &lt;div&gt;\r
- * tags when using the ENTER key.\r
+ * Used in conjunction with <code>{@link CKEDITOR.config.enterMode}</code>\r
+ * and <code>{@link CKEDITOR.config.shiftEnterMode}</code> configuration\r
+ * settings to make the editor produce <code>&lt;div&gt;</code> tags when\r
+ * using the <em>Enter</em> key.\r
  * @constant\r
  */\r
 CKEDITOR.ENTER_DIV     = 3;\r
 \r
 /**\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 Stores default configuration settings. Changes to this object are\r
+ * reflected in all editor instances, if not specified otherwise for a particular\r
+ * instance.\r
  */\r
 CKEDITOR.config =\r
 {\r
        /**\r
         * The URL path for the custom configuration file to be loaded. If not\r
-        * overloaded with inline configurations, it defaults to the "config.js"\r
+        * overloaded with inline configuration, it defaults to the <code>config.js</code>\r
         * file present in the root of the CKEditor installation directory.<br /><br />\r
         *\r
         * CKEditor will recursively load custom configuration files defined inside\r
         * other custom configuration files.\r
         * @type String\r
-        * @default '&lt;CKEditor folder&gt;/config.js'\r
+        * @default <code>'<em>&lt;CKEditor folder&gt;</em>/config.js'</code>\r
         * @example\r
         * // Load a specific configuration file.\r
-        * CKEDITOR.replace( 'myfiled', { customConfig : '/myconfig.js' } );\r
+        * CKEDITOR.replace( 'myfield', { customConfig : '/myconfig.js' } );\r
         * @example\r
         * // Do not load any custom configuration file.\r
-        * CKEDITOR.replace( 'myfiled', { customConfig : '' } );\r
+        * CKEDITOR.replace( 'myfield', { customConfig : '' } );\r
         */\r
        customConfig : 'config.js',\r
 \r
        /**\r
-        * Whether the replaced element (usually a textarea) is to be updated\r
-        * automatically when posting the form containing the editor.\r
+        * Whether the replaced element (usually a <code>&lt;textarea&gt;</code>)\r
+        * is to be updated automatically when posting the form containing the editor.\r
         * @type Boolean\r
-        * @default true\r
+        * @default <code>true</code>\r
         * @example\r
         * config.autoUpdateElement = true;\r
         */\r
@@ -71,18 +74,18 @@ CKEDITOR.config =
         * The base href URL used to resolve relative and absolute URLs in the\r
         * editor content.\r
         * @type String\r
-        * @default '' (empty)\r
+        * @default <code>''</code> (empty)\r
         * @example\r
         * config.baseHref = 'http://www.example.com/path/';\r
         */\r
        baseHref : '',\r
 \r
        /**\r
-        * The CSS file(s) to be used to apply style to the contents. It should\r
+        * The CSS file(s) to be used to apply style to editor contents. It should\r
         * reflect the CSS used in the final pages where the contents are to be\r
         * used.\r
         * @type String|Array\r
-        * @default '&lt;CKEditor folder&gt;/contents.css'\r
+        * @default <code>'<em>&lt;CKEditor folder&gt;</em>/contents.css'</code>\r
         * @example\r
         * config.contentsCss = '/css/mysitestyles.css';\r
         * config.contentsCss = ['/css/mysitestyles.css', '/css/anotherfile.css'];\r
@@ -90,14 +93,14 @@ CKEDITOR.config =
        contentsCss : CKEDITOR.basePath + 'contents.css',\r
 \r
        /**\r
-        * The writting direction of the language used to write the editor\r
+        * The writing direction of the language used to create the editor\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
+        *     <li><code>'ui'</code> &ndash; indicates that content direction will be the same as the user interface language direction;</li>\r
+        *     <li><code>'ltr'</code> &ndash; for Left-To-Right language (like English);</li>\r
+        *     <li><code>'rtl'</code> &ndash; for Right-To-Left languages (like Arabic).</li>\r
         * </ul>\r
-        * @default 'ui'\r
+        * @default <code>'ui'</code>\r
         * @type String\r
         * @example\r
         * config.contentsLangDirection = 'rtl';\r
@@ -105,9 +108,9 @@ CKEDITOR.config =
        contentsLangDirection : 'ui',\r
 \r
        /**\r
-        * Language code of  the writting language which is used to author the editor\r
+        * Language code of  the writing language which is used to create the editor\r
         * contents.\r
-        * @default Same value with editor's UI language.\r
+        * @default Same value as editor UI language.\r
         * @type String\r
         * @example\r
         * config.contentsLanguage = 'fr';\r
@@ -115,10 +118,11 @@ CKEDITOR.config =
        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 '' (empty)\r
+        * The user interface language localization to use. If left empty, the editor\r
+        * will automatically be localized to the user language. If the user language is not supported,\r
+        * the language specified in the <code>{@link CKEDITOR.config.defaultLanguage}</code>\r
+        * configuration setting is used.\r
+        * @default <code>''</code> (empty)\r
         * @type String\r
         * @example\r
         * // Load the German interface.\r
@@ -127,9 +131,9 @@ CKEDITOR.config =
        language : '',\r
 \r
        /**\r
-        * The language to be used if {@link CKEDITOR.config.language} is left empty and it's not\r
-        * possible to localize the editor to the user language.\r
-        * @default 'en'\r
+        * The language to be used if the <code>{@link CKEDITOR.config.language}</code>\r
+        * setting is left empty and it is not possible to localize the editor to the user language.\r
+        * @default <code>'en'</code>\r
         * @type String\r
         * @example\r
         * config.defaultLanguage = 'it';\r
@@ -137,21 +141,20 @@ CKEDITOR.config =
        defaultLanguage : 'en',\r
 \r
        /**\r
-        * Sets the behavior for the ENTER key. It also dictates other behaviour\r
-        * rules in the editor, like whether the &lt;br&gt; element is to be used\r
+        * Sets the behavior of the <em>Enter</em> key. It also determines other behavior\r
+        * rules of the editor, like whether the <code>&lt;br&gt;</code> element is to be used\r
         * as a paragraph separator when indenting text.\r
-        * The allowed values are the following constants, and their relative\r
-        * behavior:\r
+        * The allowed values are the following constants that cause the behavior outlined below:\r
         * <ul>\r
-        *     <li>{@link CKEDITOR.ENTER_P} (1): new &lt;p&gt; paragraphs are created;</li>\r
-        *     <li>{@link CKEDITOR.ENTER_BR} (2): lines are broken with &lt;br&gt; elements;</li>\r
-        *     <li>{@link CKEDITOR.ENTER_DIV} (3): new &lt;div&gt; blocks are created.</li>\r
+        *     <li><code>{@link CKEDITOR.ENTER_P}</code> (1) &ndash; new <code>&lt;p&gt;</code> paragraphs are created;</li>\r
+        *     <li><code>{@link CKEDITOR.ENTER_BR}</code> (2) &ndash; lines are broken with <code>&lt;br&gt;</code> elements;</li>\r
+        *     <li><code>{@link CKEDITOR.ENTER_DIV}</code> (3) &ndash; new <code>&lt;div&gt;</code> blocks are created.</li>\r
         * </ul>\r
-        * <strong>Note</strong>: It's recommended to use the\r
-        * {@link CKEDITOR.ENTER_P} value because of its semantic value and\r
-        * correctness. The editor is optimized for this value.\r
+        * <strong>Note</strong>: It is recommended to use the\r
+        * <code>{@link CKEDITOR.ENTER_P}</code> setting because of its semantic value and\r
+        * correctness. The editor is optimized for this setting.\r
         * @type Number\r
-        * @default {@link CKEDITOR.ENTER_P}\r
+        * @default <code>{@link CKEDITOR.ENTER_P}</code>\r
         * @example\r
         * // Not recommended.\r
         * config.enterMode = CKEDITOR.ENTER_BR;\r
@@ -159,11 +162,14 @@ 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
+        * Force the use of <code>{@link CKEDITOR.config.enterMode}</code> as line break regardless\r
+        * of the context. If, for example, <code>{@link CKEDITOR.config.enterMode}</code> is set\r
+        * to <code>{@link CKEDITOR.ENTER_P}</code>, pressing the <em>Enter</em> key inside a\r
+        * <code>&lt;div&gt;</code> element will create a new paragraph with <code>&lt;p&gt;</code>\r
+        * instead of a <code>&lt;div&gt;</code>.\r
         * @since 3.2.1\r
-        * @default false\r
+        * @type Boolean\r
+        * @default <code>false</code>\r
         * @example\r
         * // Not recommended.\r
         * config.forceEnterMode = true;\r
@@ -171,16 +177,16 @@ CKEDITOR.config =
        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
+        * Similarly to the <code>{@link CKEDITOR.config.enterMode}</code> setting, it defines the behavior\r
+        * of the <em>Shift+Enter</em> key combination.\r
+        * The allowed values are the following constants the behavior outlined below:\r
         * <ul>\r
-        *     <li>{@link CKEDITOR.ENTER_P} (1): new &lt;p&gt; paragraphs are created;</li>\r
-        *     <li>{@link CKEDITOR.ENTER_BR} (2): lines are broken with &lt;br&gt; elements;</li>\r
-        *     <li>{@link CKEDITOR.ENTER_DIV} (3): new &lt;div&gt; blocks are created.</li>\r
+        *     <li><code>{@link CKEDITOR.ENTER_P}</code> (1) &ndash; new <code>&lt;p&gt;</code> paragraphs are created;</li>\r
+        *     <li><code>{@link CKEDITOR.ENTER_BR}</code> (2) &ndash; lines are broken with <code>&lt;br&gt;</code> elements;</li>\r
+        *     <li><code>{@link CKEDITOR.ENTER_DIV}</code> (3) &ndash; new <code>&lt;div&gt;</code> blocks are created.</li>\r
         * </ul>\r
         * @type Number\r
-        * @default {@link CKEDITOR.ENTER_BR}\r
+        * @default <code>{@link CKEDITOR.ENTER_BR}</code>\r
         * @example\r
         * config.shiftEnterMode = CKEDITOR.ENTER_P;\r
         */\r
@@ -188,71 +194,73 @@ CKEDITOR.config =
 \r
        /**\r
         * A comma separated list of plugins that are not related to editor\r
-        * instances. Reserved to plugins that extend the core code only.<br /><br />\r
+        * instances. Reserved for plugins that extend the core code only.<br /><br />\r
         *\r
-        * There are no ways to override this setting, except by editing the source\r
-        * code of CKEditor (_source/core/config.js).\r
+        * There are no ways to override this setting except by editing the source\r
+        * code of CKEditor (<code>_source/core/config.js</code>).\r
         * @type String\r
         * @example\r
         */\r
        corePlugins : '',\r
 \r
        /**\r
-        * Sets the doctype to be used when loading the editor content as HTML.\r
+        * Sets the <code>DOCTYPE</code> to be used when loading the editor content as HTML.\r
         * @type String\r
-        * @default '&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt;'\r
+        * @default <code>'&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt;'</code>\r
         * @example\r
-        * // Set the doctype to the HTML 4 (quirks) mode.\r
+        * // Set the DOCTYPE to the HTML 4 (Quirks) mode.\r
         * config.docType = '&lt;!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"&gt;';\r
         */\r
        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 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
+        * Sets the <code>id</code> attribute to be used on the <code>body</code> element\r
+        * of the editing area. This can be useful when you intend to reuse the original CSS\r
+        * file you are using on your live website and want to assign the editor the same ID\r
+        * as the section that will include the contents. In this way ID-specific CSS rules will\r
+        * be enabled.\r
         * @since 3.1\r
         * @type String\r
-        * @default '' (empty)\r
+        * @default <code>''</code> (empty)\r
         * @example\r
         * config.bodyId = 'contents_id';\r
         */\r
        bodyId : '',\r
 \r
        /**\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
+        * Sets the <code>class</code> attribute to be used on the <code>body</code> element\r
+        * of the editing area. This can be useful when you intend to reuse the original CSS\r
+        * file you are using on your live website and want to assign the editor the same class\r
+        * as the section that will include the contents. In this way class-specific CSS rules will\r
+        * be enabled.\r
         * @since 3.1\r
         * @type String\r
-        * @default '' (empty)\r
+        * @default <code>''</code> (empty)\r
         * @example\r
         * config.bodyClass = 'contents';\r
         */\r
        bodyClass : '',\r
 \r
        /**\r
-        * Indicates whether the contents to be edited are being inputted as a full\r
-        * 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
+        * Indicates whether the contents to be edited are being input as a full\r
+        * HTML page. A full page includes the <code>&lt;html&gt;</code>,\r
+        * <code>&lt;head&gt;</code>, and <code>&lt;body&gt;</code> elements.\r
+        * The final output will also reflect this setting, including the\r
+        * <code>&lt;body&gt;</code> contents only if this setting is disabled.\r
         * @since 3.1\r
         * @type Boolean\r
-        * @default false\r
+        * @default <code>false</code>\r
         * @example\r
         * config.fullPage = true;\r
         */\r
        fullPage : false,\r
 \r
        /**\r
-        * The height of editing area( content ), in relative or absolute, e.g. 30px, 5em.\r
-        * Note: Percentage unit is not supported yet. e.g. 30%.\r
+        * The height of the editing area (that includes the editor content),\r
+        * in relative or absolute units, e.g. <code>30px</code>, <code>5em</code>.\r
+        * <strong>Note:</strong> Percentage units, like <code>30%</code>, are not supported yet.\r
         * @type Number|String\r
-        * @default '200'\r
+        * @default <code>'200'</code>\r
         * @example\r
         * config.height = 500;\r
         * config.height = '25em';\r
@@ -261,10 +269,10 @@ CKEDITOR.config =
        height : 200,\r
 \r
        /**\r
-        * Comma separated list of plugins to load and initialize for an editor\r
-        * instance. This should be rarely changed, using instead the\r
-        * {@link CKEDITOR.config.extraPlugins} and\r
-        * {@link CKEDITOR.config.removePlugins} for customizations.\r
+        * Comma separated list of plugins to be loaded and initialized for an editor\r
+        * instance. This setting should rarely be changed. It is recommended to use the\r
+        * <code>{@link CKEDITOR.config.extraPlugins}</code> and\r
+        * <code>{@link CKEDITOR.config.removePlugins}</code> for customization purposes instead.\r
         * @type String\r
         * @example\r
         */\r
@@ -328,9 +336,9 @@ CKEDITOR.config =
                'wsc',\r
 \r
        /**\r
-        * List of additional plugins to be loaded. This is a tool setting which\r
-        * makes it easier to add new plugins, whithout having to touch and\r
-        * possibly breaking the {@link CKEDITOR.config.plugins} setting.\r
+        * A list of additional plugins to be loaded. This setting makes it easier\r
+        * to add new plugins without having to touch and potentially break the\r
+        * <code>{@link CKEDITOR.config.plugins}</code> setting.\r
         * @type String\r
         * @example\r
         * config.extraPlugins = 'myplugin,anotherplugin';\r
@@ -338,10 +346,9 @@ CKEDITOR.config =
        extraPlugins : '',\r
 \r
        /**\r
-        * List of plugins that must not be loaded. This is a tool setting which\r
-        * makes it easier to avoid loading plugins definied in the\r
-        * {@link CKEDITOR.config.plugins} setting, whithout having to touch it and\r
-        * potentially breaking it.\r
+        * A list of plugins that must not be loaded. This setting makes it possible\r
+        * to avoid loading some plugins defined in the <code>{@link CKEDITOR.config.plugins}</code>\r
+        * setting, without having to touch it and potentially break it.\r
         * @type String\r
         * @example\r
         * config.removePlugins = 'elementspath,save,font';\r
@@ -349,30 +356,31 @@ CKEDITOR.config =
        removePlugins : '',\r
 \r
        /**\r
-        * List of regular expressions to be executed over the input HTML,\r
-        * indicating HTML source code that matched must <strong>not</strong> present in WYSIWYG mode for editing.\r
+        * List of regular expressions to be executed on input HTML,\r
+        * indicating HTML source code that when matched, must <strong>not</strong> be available in the WYSIWYG\r
+        * mode for editing.\r
         * @type Array\r
-        * @default [] (empty array)\r
+        * @default <code>[]</code> (empty array)\r
         * @example\r
-        * config.protectedSource.push( /<\?[\s\S]*?\?>/g );   // PHP Code\r
-        * config.protectedSource.push( /<%[\s\S]*?%>/g );   // ASP Code\r
-        * config.protectedSource.push( /(<asp:[^\>]+>[\s|\S]*?<\/asp:[^\>]+>)|(<asp:[^\>]+\/>)/gi );   // ASP.Net Code\r
+        * config.protectedSource.push( /<\?[\s\S]*?\?>/g );   // PHP code\r
+        * config.protectedSource.push( /<%[\s\S]*?%>/g );   // ASP code\r
+        * config.protectedSource.push( /(<asp:[^\>]+>[\s|\S]*?<\/asp:[^\>]+>)|(<asp:[^\>]+\/>)/gi );   // ASP.Net code\r
         */\r
        protectedSource : [],\r
 \r
        /**\r
-        * The editor tabindex value.\r
+        * The editor <code>tabindex</code> value.\r
         * @type Number\r
-        * @default 0 (zero)\r
+        * @default <code>0</code> (zero)\r
         * @example\r
         * config.tabIndex = 1;\r
         */\r
        tabIndex : 0,\r
 \r
        /**\r
-        * The theme to be used to build the UI.\r
+        * The theme to be used to build the user interface.\r
         * @type String\r
-        * @default 'default'\r
+        * @default <code>'default'</code>\r
         * @see CKEDITOR.config.skin\r
         * @example\r
         * config.theme = 'default';\r
@@ -383,7 +391,7 @@ CKEDITOR.config =
         * The skin to load. It may be the name of the skin folder inside the\r
         * editor installation path, or the name and the path separated by a comma.\r
         * @type String\r
-        * @default 'default'\r
+        * @default <code>'default'</code>\r
         * @example\r
         * config.skin = 'v2';\r
         * @example\r
@@ -392,9 +400,9 @@ CKEDITOR.config =
        skin : 'kama',\r
 \r
        /**\r
-        * The editor width in CSS size format or pixel integer.\r
+        * The editor width in CSS-defined units or an integer denoting a value in pixels.\r
         * @type String|Number\r
-        * @default '' (empty)\r
+        * @default <code>''</code> (empty)\r
         * @example\r
         * config.width = 850;\r
         * @example\r
@@ -403,9 +411,9 @@ CKEDITOR.config =
        width : '',\r
 \r
        /**\r
-        * The base Z-index for floating dialogs and popups.\r
+        * The base Z-index for floating dialog windows and popups.\r
         * @type Number\r
-        * @default 10000\r
+        * @default <code>10000</code>\r
         * @example\r
         * config.baseFloatZIndex = 2000\r
         */\r
@@ -414,15 +422,15 @@ CKEDITOR.config =
 \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
+ * direction, should use the "computed value" of the feature to indicate its\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
+ * If enabled in a Left-To-Right written document, the "Left Justify"\r
+ * alignment button will be shown as active, even if the alignment 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
+ * @default <code>true</code>\r
  * @since 3.4\r
  * @example\r
  * config.useComputedState = false;\r