• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdelibs API Reference
  • KDE Home
  • Contact Us
 

KHTML

  • sources
  • kde-4.14
  • kdelibs
  • khtml
  • dom
dom_text.h
Go to the documentation of this file.
1 /*
2  * This file is part of the DOM implementation for KDE.
3  *
4  * Copyright 1999 Lars Knoll (knoll@kde.org)
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Library General Public
8  * License as published by the Free Software Foundation; either
9  * version 2 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  * Library General Public License for more details.
15  *
16  * You should have received a copy of the GNU Library General Public License
17  * along with this library; see the file COPYING.LIB. If not, write to
18  * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
19  * Boston, MA 02110-1301, USA.
20  *
21  * This file includes excerpts from the Document Object Model (DOM)
22  * Level 1 Specification (Recommendation)
23  * http://www.w3.org/TR/REC-DOM-Level-1/
24  * Copyright © World Wide Web Consortium , (Massachusetts Institute of
25  * Technology , Institut National de Recherche en Informatique et en
26  * Automatique , Keio University ). All Rights Reserved.
27  *
28  */
29 #ifndef _DOM_CharacterData_h_
30 #define _DOM_CharacterData_h_
31 
32 #include <dom/dom_node.h>
33 
34 namespace DOM {
35 
36 class DOMString;
37 class CharacterDataImpl;
38 
49 class KHTML_EXPORT CharacterData : public Node
50 {
51  friend class CharacterDataImpl;
52 
53 public:
54  CharacterData();
55  CharacterData(const CharacterData &other);
56  CharacterData(const Node &other) : Node()
57  {(*this)=other;}
58 
59  CharacterData & operator = (const Node &other);
60  CharacterData & operator = (const CharacterData &other);
61 
62  ~CharacterData();
63 
80  DOMString data() const;
81 
88  void setData( const DOMString & );
89 
97  unsigned long length() const;
98 
120  DOMString substringData ( const unsigned long offset, const unsigned long count );
121 
136  void appendData ( const DOMString &arg );
137 
154  void insertData ( const unsigned long offset, const DOMString &arg );
155 
178  void deleteData ( const unsigned long offset, const unsigned long count );
179 
206  void replaceData ( const unsigned long offset, const unsigned long count, const DOMString &arg );
207 
208 protected:
209  CharacterData(CharacterDataImpl *i);
210 };
211 
212 
213 class CommentImpl;
214 
223 class KHTML_EXPORT Comment : public CharacterData
224 {
225  friend class Document;
226  friend class TextImpl;
227 
228 public:
229  Comment();
230  Comment(const Comment &other);
231  Comment(const Node &other) : CharacterData()
232  {(*this)=other;}
233 
234  Comment & operator = (const Node &other);
235  Comment & operator = (const Comment &other);
236 
237  ~Comment();
238 
239 protected:
240  Comment(CommentImpl *i);
241 };
242 
243 class TextImpl;
244 
269 class KHTML_EXPORT Text : public CharacterData
270 {
271  friend class Document;
272  friend class TextImpl;
273 
274 public:
275  Text();
276  Text(const Text &other);
277  Text(const Node &other) : CharacterData()
278  {(*this)=other;}
279 
280  Text & operator = (const Node &other);
281  Text & operator = (const Text &other);
282 
283  ~Text();
284 
304  Text splitText ( const unsigned long offset );
305 
306 protected:
307  Text(TextImpl *i);
308 
309 };
310 
311 } //namespace
312 #endif
DOM::Node
The Node interface is the primary datatype for the entire Document Object Model.
Definition: dom_node.h:270
DOM::Text::Text
Text(const Node &other)
Definition: dom_text.h:277
DOM::Comment::Comment
Comment(const Node &other)
Definition: dom_text.h:231
DOM::Comment
This represents the content of a comment, i.e., all the characters between the starting '
Definition: dom_text.h:223
DOM::Text
The Text interface represents the textual content (termed character data in XML) of an Element or At...
Definition: dom_text.h:269
dom_node.h
DOM::DOMString
This class implements the basic string we use in the DOM.
Definition: dom_string.h:43
DOM::Document
The Document interface represents the entire HTML or XML document.
Definition: dom_doc.h:245
DOM::CharacterData::CharacterData
CharacterData(const Node &other)
Definition: dom_text.h:56
DOM::CharacterData
The CharacterData interface extends Node with a set of attributes and methods for accessing character...
Definition: dom_text.h:49
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:26:18 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KHTML

Skip menu "KHTML"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdelibs API Reference

Skip menu "kdelibs API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal