Class Xinha.Config

Object
   |
   +--Xinha.Config

class Xinha.Config

Defined in XinhaCore.js

Version: $Rev: 819 $ $LastChangedDate: 2007-04-20 01:20:22 +0200 (Fr, 20 Apr 2007) $


Field Summary
 String|null baseHref
          Specify a base href for relative links
ATTENTION: this does not work as expected and needs t be changed, see Ticket #961
Default: null
 Boolean|null browserQuirksMode
          Whether the edited document should be rendered in Quirksmode or Standard Compliant (Strict) Mode.
This is commonly known as the "doctype switch"
for details read here http://www.quirksmode.org/css/quirksmode.html
<private>  Object btn
          
 Object btnList
          The button list conains the definitions of the toolbar button.
<private>  Object cfg
          
 Boolean changeJustifyWithDirection
          Set this to true if you want to explicitly right-justify when setting the text direction to right-to-left
Default: false
 String charSet
          CharSet of the iframe, default is the charset of the document
 String colorPickerCellSize
          Size of color picker cells
Use number + "px"
Default: "6px"
 Integer colorPickerGranularity
          Granularity of color picker cells (number per column/row)
Default: 18
 String colorPickerPosition
          Position of color picker from toolbar button
Default: "bottom,right"
 Integer colorPickerSaveColors
          Number of recent colors to remember
Default: 20
 Boolean colorPickerWebSafe
          Set to true to show only websafe checkbox in picker
Default: false
 Boolean convertUrlsToLinks
          See if the text just typed looks like a URL, or email address and link it appropriatly Note: Setting this option to false only affects Mozilla based browsers.
 Object customSelects
          ??
 Boolean debug
          Switches on some debugging (only in execCommand() as far as I see at the moment)
 Boolean expandRelativeUrl
          If true, relative URLs (../) will be made absolute.
 Boolean flowToolbars
          Turning this on will turn all "linebreak" and "separator" items in your toolbar into soft-breaks, this means that if the items between that item and the next linebreak/separator can fit on the same line as that which came before then they will, otherwise they will float down to the next line.
 Object fontname
          The fontnames listed in the fontname dropdown Default value:
xinha_config.fontname =
{
  "— font —" : '',
  "Arial"                : 'arial,helvetica,sans-serif',
  "Courier New"          : 'courier new,courier,monospace',
  "Georgia"              : 'georgia,times new roman,times,serif',
  "Tahoma"               : 'tahoma,arial,helvetica,sans-serif',
  "Times New Roman"      : 'times new roman,times,serif',
  "Verdana"              : 'verdana,arial,helvetica,sans-serif',
  "impact"               : 'impact',
  "WingDings"            : 'wingdings'
};
 Object fontsize
          The fontsizes listed in the fontsize dropdown Default value:
xinha_config.fontsize =
{
  "— size —": "",
  "1 (8 pt)" : "1",
  "2 (10 pt)": "2",
  "3 (12 pt)": "3",
  "4 (14 pt)": "4",
  "5 (18 pt)": "5",
  "6 (24 pt)": "6",
  "7 (36 pt)": "7"
};
 Object formatblock
          The tags listed in the formatblock dropdown Default value:
xinha_config.formatblock =
{
  "— size —": "",
  "1 (8 pt)" : "1",
  "2 (10 pt)": "2",
  "3 (12 pt)": "3",
  "4 (14 pt)": "4",
  "5 (18 pt)": "5",
  "6 (24 pt)": "6",
  "7 (36 pt)": "7"
};
 Boolean fullPage
          If true then Xinha will retrieve the full HTML, starting with the <HTML> tag.
Default: false
 Boolean fullScreen
          Start up the editor in fullscreen mode
Default: false
 Array fullScreenMargins
          You can tell the fullscreen mode to leave certain margins on each side.
The value is an array with the values for [top,right,bottom,left] in that order
Default: [0,0,0,0]
 String getHtmlMethod
          This determines the method how the HTML output is generated.
 String height
          This property controls the height of the editor.
Allowed values are 'auto' or a numeric value followed by px.
"auto": let Xinha choose the height to use.
numeric value: forced height in pixels ('200px').
Default: "auto"
 Boolean htmlareaPaste
          Intercept ^V and use the Xinha paste command If false, then passes ^V through to browser editor widget, which is the only way it works without problems in Mozilla
 RegExp|null htmlRemoveTags
          Remove given tags when rendering the HTML (these have to be a regexp, or null if this functionality is not desired)
Default: null
 Integer|null iframeWidth
          To make the iframe width narrower than the toolbar width, e.g.
 Object imgURL
          
 Boolean killWordOnPaste
          Set to true if you want Word code to be cleaned upon Paste.
 Boolean makeLinkShowsTarget
          Enable the 'Target' field in the Make Link dialog.
 String mozParaHandler
          Gecko only: Let the built-in routine for handling the return key decide if to enter br or p tags, or use a custom implementation.
For information about the rules applied by Gecko, see Mozilla website
Possible values are built-in or best
 Boolean only7BitPrintablesInURLs
          In URLs all characters above ASCII value 127 have to be encoded using % codes
Default: true
 String pageStyle
          Raw style definitions included in the edited document
When a lot of inline style is used, perhaps it is wiser to use one or more external stylesheets.
To set tags P in red, H1 in blue andn A not underlined, we may do the following
 xinha_config.pageStyle =
  'p { color:red; }\n' +
  'h1 { color:bleu; }\n' +
  'a {text-decoration:none; }';
Default: "" (empty)
 Array pageStyleSheets
          Array of external stylesheets to load.
 Object panel_dimensions
          each of the panels has a dimension, for the left/right it's the width for the top/bottom it's the height.
 Object popupURL
          
 Function removeToolbarElement
          Alias of Xinha.Config.prototype.hideSomeButtons()
 Boolean sevenBitClean
          If you are putting the HTML written in Xinha into an email you might want it to be 7-bit characters only.
 Boolean showLoading
          Set to true if you want the loading panel to show at startup
Default: false
 Boolean sizeIncludesBars
          Specifies whether the toolbar should be included in the size, or are extra to it.
 Boolean sizeIncludesPanels
          Specifies whether the panels should be included in the size, or are extra to it.
 Object specialReplacements
          Sometimes we want to be able to replace some string in the html comng in and going out so that in the editor we use the "internal" string, and outside and in the source view we use the "external" string this is useful for say making special codes for your absolute links, your external string might be some special code, say "{server_url}" an you say that the internal represenattion of that should be http://your.server/
Example: {'external_string' : 'internal_string'}
Default: {} (empty)
 Boolean statusBar
          Enable creation of the status bar?
 Boolean stripBaseHref
          We can strip the server part out of URL to make/leave them semi-absolute, reason for this is that the browsers will prefix the server to any relative links to make them absolute, which isn't what you want most the time.
Default: true
 Boolean stripScripts
          Set to false if you want to allow JavaScript in the content, otherwise <script> tags are stripped out.
This currently only affects the "DOMwalk" getHtmlMethod.
Default: true
 Boolean stripSelfNamedAnchors
          We can strip the url of the editor page from named links (eg <a href="#top">...</a>) reason for this is that mozilla at least (and IE ?) prefixes location.href to any anchor that don't have a url prefixing them
Default: true
 Array toolbar
          This array orders all buttons except plugin buttons in the toolbar.
 String toolbarAlign
          Set to center or right to change button alignment in toolbar
 Integer undoSteps
          Maximum size of the undo queue
Default: 20
 Integer milliseconds undoTimeout
          The time interval at which undo samples are taken
Default: 500 (1/2 sec)
 Object URIs
          
 Object version
          
 String width
          This property controls the width of the editor.
Allowed values are 'auto', 'toolbar' or a numeric value followed by "px".
auto: let Xinha choose the width to use.
toolbar: compute the width size from the toolbar width.
numeric value: forced width in pixels ('600px').
Default: "auto"
 
Constructor Summary
Xinha.Config()
            This class creates an object that can be passed to the Xinha constructor as a parameter.
 
Method Summary
 void addToolbarElement(id, where, position)
           Helper Function: add buttons/drop-downs boxes with title or separator to the toolbar if the buttons/drop-downs boxes doesn't allready exists.
 void hideSomeButtons(remove)
           Call this function to remove some buttons/drop-down boxes from the toolbar.
 Object registerButton(id, tooltip, image, textMode, action, context)
           Helper function: register a new button with the configuration.
 void registerDropdown(object)
           The following helper function registers a dropdown box with the editor configuration.

Field Detail

baseHref

String|null baseHref

browserQuirksMode

Boolean|null browserQuirksMode

btn

<private> Object btn

btnList

Object btnList

cfg

<private> Object cfg

changeJustifyWithDirection

Boolean changeJustifyWithDirection

charSet

String charSet

colorPickerCellSize

String colorPickerCellSize

colorPickerGranularity

Integer colorPickerGranularity

colorPickerPosition

String colorPickerPosition

colorPickerSaveColors

Integer colorPickerSaveColors

colorPickerWebSafe

Boolean colorPickerWebSafe

convertUrlsToLinks

Boolean convertUrlsToLinks

customSelects

Object customSelects

debug

Boolean debug

expandRelativeUrl

Boolean expandRelativeUrl

flowToolbars

Boolean flowToolbars

fontname

Object fontname

fontsize

Object fontsize

formatblock

Object formatblock

fullPage

Boolean fullPage

fullScreen

Boolean fullScreen

fullScreenMargins

Array fullScreenMargins

getHtmlMethod

String getHtmlMethod

height

String height

htmlareaPaste

Boolean htmlareaPaste

htmlRemoveTags

RegExp|null htmlRemoveTags

iframeWidth

Integer|null iframeWidth

imgURL

Object imgURL

killWordOnPaste

Boolean killWordOnPaste

makeLinkShowsTarget

Boolean makeLinkShowsTarget

mozParaHandler

String mozParaHandler

only7BitPrintablesInURLs

Boolean only7BitPrintablesInURLs

pageStyle

String pageStyle

pageStyleSheets

Array pageStyleSheets

panel_dimensions

Object panel_dimensions

popupURL

Object popupURL

removeToolbarElement

Function removeToolbarElement

sevenBitClean

Boolean sevenBitClean

showLoading

Boolean showLoading

sizeIncludesBars

Boolean sizeIncludesBars

sizeIncludesPanels

Boolean sizeIncludesPanels

specialReplacements

Object specialReplacements

statusBar

Boolean statusBar

stripBaseHref

Boolean stripBaseHref

stripScripts

Boolean stripScripts

stripSelfNamedAnchors

Boolean stripSelfNamedAnchors

toolbar

Array toolbar

toolbarAlign

String toolbarAlign

undoSteps

Integer undoSteps

undoTimeout

Integer milliseconds undoTimeout

URIs

Object URIs

version

Object version

width

String width

Constructor Detail

Xinha.Config

Xinha.Config()

Method Detail

addToolbarElement

void addToolbarElement(id, where, position)

hideSomeButtons

void hideSomeButtons(remove)

registerButton

Object registerButton(id, tooltip, image, textMode, action, context)

registerDropdown

void registerDropdown(object)


Documentation generated by JSDoc on Fri Apr 20 01:21:16 2007