r19368 by craig - #11505: Strip added tabs from fronts of lines

scribus-commit scribus-commit at lists.scribus.net
Thu Jul 24 21:50:26 UTC 2014


Author: craig
Date: Thu Jul 24 21:50:25 2014
New Revision: 19368

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=19368
Log:
#11505: Strip added tabs from fronts of lines

Modified:
    trunk/Scribus/scribus/plugins/gettext/csvim/csvim.cpp

Modified: trunk/Scribus/scribus/plugins/gettext/csvim/csvim.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=19368&path=/trunk/Scribus/scribus/plugins/gettext/csvim/csvim.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/gettext/csvim/csvim.cpp (original)
+++ trunk/Scribus/scribus/plugins/gettext/csvim/csvim.cpp Thu Jul 24 21:50:25 2014
@@ -132,6 +132,9 @@
 		if (colCount < colIndex)
 			colCount = colIndex;
 	}
+	if (data.startsWith("\t"))
+		data.remove(0,1);
+	data.replace("\n\t","\n");
 }
 
 void CsvIm::parseLine(const QString& line, bool isHeader)
@@ -159,7 +162,7 @@
 			header += "\t" + line;
 		else
 			data += "\t" + line;
-		return; // error in line, no closing valuedelimiter could be found	
+		return; // error in line, no closing valuedelimiter could be found
 	}
 
 	int fdIndex = line.indexOf(fieldDelimiter, vdIndexEnd + 1);




More information about the scribus-commit mailing list