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

List:       quanta-devel
Subject:    Re: [quanta-devel] Re: KDOM
From:       Paulo Moura Guedes <moura () kdewebdev ! org>
Date:       2005-05-25 2:37:28
Message-ID: 200505250337.28653.moura () kdewebdev ! org
[Download RAW message or body]

On Wednesday 25 May 2005 02:19, Jens Herden wrote:
> Hi,
>
> > > 1. in the future we should not save the text that was parsed inside the
> > > node. Just the coordinates is sufficient, if we need the text we can
> > > look into the texteditor.
> >
> > Yes. But we have to take care of the indentation... maybe we could just
> > save the indentation text like "\n     ".
>
> I do not understand this.

We need to take care of indentation when working in VPL or we end with a 
document that is a mess. Currently this is taken care by adding line breaks 
and space in the tag strings but I'm sure we can arrange a smarter way.

> > > 2. in order to preserve the user formatted source we should
> > > copy/cut/paste just in the textdocument. Then we can use the undo
> > > feature of the texteditor. We have to take care of syncing the dom tree
> > > though.
> >
> > Interesting thought... so you mean making the the changes in the node
> > tree and then synch the text editor. I see some disadvantages though: 1.
> > in VPL you'll have to rebuild all the tree when undoing.
>
> If we would be able to find the area in the text document that has changed
> we could avoid this. Maybe we need support from the Kate part for this?

I'm not sure if I understand. The tool we have to make modifications in the 
document is the node tree. Copy/Cut/Paste is just an example but we have to 
do all kinds of operations that are only doable by manipulating the DOM with 
editing comands. Like Nicolas said, it is the golden rule, and this is one 
point I agree with him. So, we end up modifying the tree and syncing with the 
text editor. But if you are only talking about undoing, I thinks it's a smart 
way to achieve it, though maybe is incompatible with WebCore editing code.

> > 2. you can't have user defined indentation.
>
> What is this?
>
> > 3. what holds the document is the tree not the text editor.
>
> That is what you say now and not what I am proposing. I would like to think
> about the opposite. The textdocument is the document and the tree is just a
> view.

See above.

> > So if count on the text to make changes to your document you'll soon will
> > find some limitations like the first point.
>
> Maybe, but I think it is worse to investigate this. Maybe the parser is
> fast enough so that this is not a problem at all.

Don't count on it :) 

> > I don't think this is a good approach.
>
> I don't think that what we have now is a good approach ;-)

I think that some things we have now are poorly designed but I don't know 
precisely which one you are talking about.

> > It would apply the Quanta formating. See above. Eric want's custom
> > indentation and I would like to implement that so I think it would be
> > more an advantage that the opposite.
>
> I am not aware about what Eric wants. 

See the mailing list for topics like "Indentation rules" and "Indentation in 
VPL" in 2004-12. They are pretty explicit. I can't give you more details now 
because I don't have the emails saved in this computer.

> And until it is not discussed in the 
> public his wishes are non existent for me, sorry. A am not able to take
> care of things I do not know. My abilities of mind reading are
> unfortunately very limited.

I didn't discuss anything in private, please don't be sarcastic. I wouldn't 
miss you opinion which, sincerely, I consider very valuable.

-- 
Paulo Moura Guedes

http://caixamagica.org
http://kdewebdev.org
_______________________________________________
quanta-devel mailing list
quanta-devel@kde.org
https://mail.kde.org/mailman/listinfo/quanta-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

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