1 /* 2 Copyright (c) 2003-2009, CKSource - Frederico Knabben. All rights reserved. 3 For licensing, see LICENSE.html or http://ckeditor.com/license 4 */ 5 6 /** 7 * @fileOverview Defines the {@link CKEDITOR.config} object, which holds the 8 * default configuration settings. 9 */ 10 11 /** 12 * Holds the default configuration settings. Changes to this object are 13 * reflected in all editor instances, if not specificaly specified for those 14 * instances. 15 * @namespace 16 * @example 17 * // All editor created after the following setting will not load custom 18 * // configuration files. 19 * CKEDITOR.config.customConfig = ''; 20 */ 21 CKEDITOR.config = 22 { 23 /** 24 * The URL path for the custom configuration file to be loaded. If not 25 * overloaded with inline configurations, it defaults to the "config.js" 26 * file present in the root of the CKEditor installation directory.<br /><br /> 27 * 28 * CKEditor will recursively load custom configuration files defined inside 29 * other custom configuration files. 30 * @type String 31 * @default '<CKEditor folder>/config.js' 32 * @example 33 * // Load a specific configuration file. 34 * CKEDITOR.replace( 'myfiled', { customConfig : '/myconfig.js' } ); 35 * @example 36 * // Do not load any custom configuration file. 37 * CKEDITOR.replace( 'myfiled', { customConfig : '' } ); 38 */ 39 customConfig : CKEDITOR.getUrl( 'config.js' ), 40 41 autoUpdateElement : true, 42 43 /** 44 * The base href URL used to resolve relative and absolute URLs in the 45 * editor content. 46 * @type String 47 * @default '' (empty string) 48 * @example 49 * config.baseHref = 'http://www.example.com/path/'; 50 */ 51 baseHref : '', 52 53 /** 54 * The CSS file to be used to apply style to the contents. It should 55 * reflect the CSS used in the final pages where the contents are to be 56 * used. 57 * @type String 58 * @default '<CKEditor folder>/contents.css' 59 * @example 60 * config.contentsCss = '/css/mysitestyles.css'; 61 */ 62 contentsCss : CKEDITOR.basePath + 'contents.css', 63 64 /** 65 * The writting direction of the language used to write the editor 66 * contents. Allowed values are 'ltr' for Left-To-Right language (like 67 * English), or 'rtl' for Right-To-Left languages (like Arabic). 68 * @default 'ltr' 69 * @type String 70 * @example 71 * config.contentsLangDirection = 'rtl'; 72 */ 73 contentsLangDirection : 'ltr', 74 75 /** 76 * Instructs the editor to automatically localize the editor to the user 77 * language, if possible. If set to false, the [@link #defaultLanguage] 78 * language is used. 79 * @default true 80 * @type Boolean 81 * @example 82 * // Forces the editor to always load the German interface. 83 * config.autoLanguage = false; 84 * config.defaultLanguage = 'de'; 85 */ 86 autoLanguage : true, 87 88 /** 89 * The language to be used if [@link #autoLanguage] is set to false, or 90 * when it's not possible to localize the editor to the user language. 91 * @default 'en' 92 * @type String 93 * @example 94 * config.defaultLanguage = 'it'; 95 */ 96 defaultLanguage : 'en', 97 98 enterMode : 'p', 99 shiftEnterMode : 'br', 100 101 /** 102 * A comma separated list of plugins that are not related to editor 103 * instances. Reserved to plugins that extend the core code only.<br /><br /> 104 * 105 * There are no ways to override this setting, except by editing the source 106 * code of CKEditor (_source/core/config.js). 107 * @type String 108 * @example 109 */ 110 corePlugins : '', 111 112 /** 113 * Sets the doctype to be used when loading the editor content as HTML. 114 * @type String 115 * @default '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">' 116 * @example 117 * // Set the doctype to the HTML 4 (quirks) mode. 118 * config.docType = '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">'; 119 */ 120 docType : '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">', 121 122 /** 123 * Indicates whether the contents to be edited are being inputted as a full 124 * HTML page. A full page includes the <html>, <head> and 125 * <body> tags. The final output will also reflect this setting, 126 * including the <body> contents only if this setting is disabled. 127 * @type Boolean 128 * @default false 129 * @example 130 * config.fullPage = true; 131 */ 132 fullPage : false, 133 134 /** 135 * The editor height, in CSS size format or pixel integer. 136 * @type String|Number 137 * @default '200' 138 * @example 139 */ 140 height : 200, 141 142 /** 143 * Comma separated list of plugins to load and initialize for an editor 144 * instance. 145 * @type String 146 * @example 147 * config.plugins = 'basicstyles,button,htmldataprocessor,toolbar,wysiwygarea'; 148 */ 149 plugins : 'basicstyles,button,elementspath,horizontalrule,htmldataprocessor,keystrokes,newpage,removeformat,smiley,sourcearea,specialchar,tab,toolbar,wysiwygarea', 150 151 /** 152 * The theme to be used to build the UI. 153 * @type String 154 * @default 'default' 155 * @see CKEDITOR.config.skin 156 * @example 157 * config.theme = 'default'; 158 */ 159 theme : 'default', 160 161 /** 162 * The skin to load. 163 * @type String 164 * @default 'default' 165 * @example 166 * config.skin = 'v2'; 167 */ 168 skin : 'default', 169 170 /** 171 * The editor width in CSS size format or pixel integer. 172 * @type String|Number 173 * @default '100%' 174 * @example 175 */ 176 width : '100%', 177 178 /** 179 * The base Z-index for floating dialogs and popups. 180 * @type Number 181 * @default 10000 182 * @example 183 * config.baseFloatZIndex = 2000 184 */ 185 baseFloatZIndex : 10000 186 187 }; 188 189 // PACKAGER_RENAME( CKEDITOR.config ) 190