2 Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved.
\r
3 For licensing, see LICENSE.html or http://ckeditor.com/license
\r
8 var spacesRegex = /[\t\r\n ]{2,}|[\t\r\n]/g;
\r
11 * A lightweight representation of HTML text.
\r
15 CKEDITOR.htmlParser.text = function( value )
\r
31 CKEDITOR.htmlParser.text.prototype =
\r
34 * The node type. This is a constant value set to {@link CKEDITOR.NODE_TEXT}.
\r
38 type : CKEDITOR.NODE_TEXT,
\r
41 * Writes the HTML representation of this text to a CKEDITOR.htmlWriter.
\r
42 * @param {CKEDITOR.htmlWriter} writer The writer to which write the HTML.
\r
45 writeHtml : function( writer, filter )
\r
47 var text = this.value;
\r
49 if ( filter && !( text = filter.onText( text, this ) ) )
\r
52 writer.text( text );
\r