[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: Using the KHTML DOM Implementation
From:       Simon Hausmann <sh () caldera ! de>
Date:       2000-11-21 8:09:15
[Download RAW message or body]

On Tue, Nov 21, 2000 at 05:05:40AM +0000, Jono Bacon wrote:
>  - What I would like to do is to display the contents of the DOM tree to 
> check that my current code can work ok. The root of the document in the DOM 
> seems to be the htmlDocument() method, and I can use methods such as 
> createElement(). Firstly, how do I set what the htmlDocument() is?

You do that by creating a document via the begin/(),write(),write,..,end()
calls or by calling openURL( url ) . htmlDocument() then returns your a
reference to DOM tree, representing the HTML document. Of course you can
do all the things you would like to do with it, like calling createElement
or any other methods available.
 
>  - Finally, when I have inserted an element into the DOM tree, do I need to 
> update the tree and then update the view? If so, how?

Modifying the DOM tree _means_ updating the tree. Modifying it should 
automatically update the view.

Bye,
 Simon
 
>> Visit http://master.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic