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

List:       kde-commits
Subject:    kdewebdev/quanta/parts/kafka
From:       Paulo Moura Guedes <moura () kdewebdev ! org>
Date:       2004-12-29 20:44:21
Message-ID: 20041229204421.079F61CEB2 () office ! kde ! org
[Download RAW message or body]

CVS commit by mojo: 

Have space between tags in consideration, e.g., <i>biltre</i> <i>azulado</i> should \
render "biltre azulado". NVU can't handle this. This partially fixes #76717.

CCBUG: 76717


  M +3 -2      undoredo.cpp   1.52
  M +13 -8     wkafkapart.cpp   1.89


--- kdewebdev/quanta/parts/kafka/undoredo.cpp  #1.51:1.52
@@ -201,5 +201,6 @@ void undoRedo::addNewModifsSet(NodeModif
   while(node)
   {
-    if(!node->tag->cleanStrBuilt() && node->tag->type == Tag::Text)
+      if(!node->tag->cleanStrBuilt() && 
+          (node->tag->type == Tag::Text || (node->tag->type == Tag::Empty && \
!node->tag->tagStr().isEmpty())))  {
       if(!node->insideSpecial)

--- kdewebdev/quanta/parts/kafka/wkafkapart.cpp  #1.88:1.89
@@ -498,5 +498,10 @@ bool KafkaDocument::buildKafkaNodeFromNo
         int i;
 
-        if(node->tag->type == Tag::XmlTag || (node->tag->type == Tag::Text && \
!node->insideSpecial)) +//     This is a hack to not created DOM::Nodes from quanta \
empty nodes if outside body, because KHTML +//     moves a node in that condition \
into the body and then the trees become desynchronized. +    bool isInsideBody = \
kafkaCommon::hasParent(node, "body"); +    
+    if(node->tag->type == Tag::XmlTag || 
+       ((node->tag->type == Tag::Text || (node->tag->type == Tag::Empty && \
isInsideBody)) && !node->insideSpecial))  {
                 str = node->tag->name.lower();
@@ -530,5 +535,5 @@ bool KafkaDocument::buildKafkaNodeFromNo
                         else
                         {
-                                if(node->tag->type == Tag::Text)
+                if(node->tag->type == Tag::Text || node->tag->type == Tag::Empty)
                                 {
                                         newNode = kafkaCommon::createTextDomNode("", \
m_kafkaPart->document()); @@ -566,5 +571,5 @@ bool \
KafkaDocument::buildKafkaNodeFromNo  else
                 {
-                        if(node->tag->type == Tag::Text)
+            if(node->tag->type == Tag::Text || node->tag->type == Tag::Empty)
                         {
                                 newNode = kafkaCommon::createTextDomNode("", \
m_kafkaPart->document()); @@ -586,5 +591,5 @@ bool \
KafkaDocument::buildKafkaNodeFromNo  
                 connectDomNodeToQuantaNode(newNode, node);
-                if(node->tag->type == Tag::Text)
+        if(node->tag->type == Tag::Text || node->tag->type == Tag::Empty)
                 {
                         //Now we get if the whitespaces at the left and right are \
kept or not.


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

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