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

List:       kde-commits
Subject:    kdesdk/kbabel/common
From:       Stanislav Višňovský
Date:       2003-05-22 16:02:12
[Download RAW message or body]

CVS commit by nanulo: 

Partial fix for #57642. Insert space after commas in copyright. Also,
add dot after each translator copyright, if missing.


  M +12 -5     catalog.cpp   1.116


--- kdesdk/kbabel/common/catalog.cpp  #1.115:1.116
@@ -486,5 +486,5 @@ CatalogItem Catalog::updatedHeader(Catal
                             "It will not be updated."));
                         } else {
-                            (*it).insert(index+1, QString(",")+cy);
+                            (*it).insert(index+1, QString(", ")+cy);
                         }
                     }
@@ -527,5 +527,5 @@ CatalogItem Catalog::updatedHeader(Catal
          temp+=(" <"+d->_identitySettings.authorEmail+">");
       }
-      temp+=", "+QDate::currentDate().toString("yyyy");
+      temp+=", "+QDate::currentDate().toString("yyyy")+".";
       
       for( it = commentList.begin(); it != commentList.end(); ++it )
@@ -567,6 +567,7 @@ CatalogItem Catalog::updatedHeader(Catal
                     int index = (*ait).findRev( QRegExp("[\\d]+[\\d\\-, ]*") );
                     if( index == -1 ) (*ait)+=", "+cy;
-                    else (*ait).insert(index+1, QString(",")+cy);
+                    else (*ait).insert(index+1, QString(", ")+cy);
                 }
+                
         }
         else foundAuthors.append(temp);
@@ -577,5 +578,11 @@ CatalogItem Catalog::updatedHeader(Catal
         it++;
         for( ait = foundAuthors.begin() ; ait != foundAuthors.end() ; ++ait )
-            commentList.insert(it, (*ait));
+        {
+            QString s = (*ait);
+
+            // ensure dot at the end of copyright
+            if( !s.endsWith(".") ) s += ".";
+            commentList.insert(it, s);
+        }
    }
 
@@ -651,5 +658,5 @@ QString Catalog::packageName() const
     QString package=d->_url.fileName();
 
-    int index=package.findRev(QRegExp(".pot?"));
+    int index=package.findRev(QRegExp("\\.pot?"));
 
     if(index>0)


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

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