|
@@ -0,0 +1,102 @@
|
|
|
+diff -ur ktigcc/ktigcc.cpp ktigcc-obsolete-kde/ktigcc.cpp
|
|
|
+--- ktigcc/ktigcc.cpp 2007-10-09 21:36:50.000000000 +0200
|
|
|
++++ ktigcc-obsolete-kde/ktigcc.cpp 2008-04-28 02:49:41.000000000 +0200
|
|
|
+@@ -39,8 +39,8 @@
|
|
|
+ #include "mainform.h"
|
|
|
+
|
|
|
+ // Check for KDE version at compile time to avoid wasting users' time
|
|
|
+-#if KDE_VERSION < KDE_MAKE_VERSION(3,5,7)
|
|
|
+-#error KDE 3.5.7 or higher required
|
|
|
++#if KDE_VERSION < KDE_MAKE_VERSION(3,5,2)
|
|
|
++#error KDE 3.5.2 or higher required
|
|
|
+ #endif
|
|
|
+
|
|
|
+ using namespace std;
|
|
|
+@@ -78,8 +78,8 @@
|
|
|
+ QTextCodec::setCodecForCStrings(QTextCodec::codecForLocale());
|
|
|
+
|
|
|
+ // Check for KDE version
|
|
|
+- if (KDE::version() < KDE_MAKE_VERSION(3,5,7))
|
|
|
+- qFatal("KDE 3.5.7 or higher required");
|
|
|
++ if (KDE::version() < KDE_MAKE_VERSION(3,5,2))
|
|
|
++ qFatal("KDE 3.5.2 or higher required");
|
|
|
+
|
|
|
+ KAboutData about("ktigcc","TIGCC IDE for KDE","1.09",
|
|
|
+ "TIGCC C and ASM SDK", KAboutData::License_GPL,
|
|
|
+diff -ur ktigcc/preferences.cpp ktigcc-obsolete-kde/preferences.cpp
|
|
|
+--- ktigcc/preferences.cpp 2007-10-09 21:36:50.000000000 +0200
|
|
|
++++ ktigcc-obsolete-kde/preferences.cpp 2008-04-28 02:48:23.000000000 +0200
|
|
|
+@@ -44,12 +44,36 @@
|
|
|
+
|
|
|
+ // versions of the syntax highlighting description file:
|
|
|
+ // 1.00 = KTIGCC 20060807 Beta
|
|
|
+-// 1.01 = KTIGCC 20060814 Beta - 1.07
|
|
|
+-// 1.02 = current KTIGCC 1 (since 1.08)
|
|
|
+-#define CURRENT_SYNFILE_VERSION "1.02"
|
|
|
++// 1.01 = current
|
|
|
++#define CURRENT_SYNFILE_VERSION "1.01"
|
|
|
+
|
|
|
+ TIGCCPrefs preferences;
|
|
|
+
|
|
|
++static void genAllCaseVariants(QString keyword, unsigned pos,
|
|
|
++ QStringList &stringList)
|
|
|
++{
|
|
|
++ // WARNING: Exponential complexity in the keyword length. Yuck!
|
|
|
++ // Blame Kate's lack of flexibility.
|
|
|
++ // Also note that this just LOOKS like a functional recursion, there ARE side
|
|
|
++ // effects.
|
|
|
++ QChar c=keyword[pos];
|
|
|
++ if (c.isNull())
|
|
|
++ stringList.append(keyword);
|
|
|
++ else {
|
|
|
++ QChar upper=c.upper();
|
|
|
++ QChar lower=c.lower();
|
|
|
++ if (lower==upper)
|
|
|
++ genAllCaseVariants(keyword,pos+1,stringList);
|
|
|
++ else {
|
|
|
++ keyword[pos]=upper;
|
|
|
++ genAllCaseVariants(keyword,pos+1,stringList);
|
|
|
++ keyword[pos]=lower;
|
|
|
++ genAllCaseVariants(keyword,pos+1,stringList);
|
|
|
++ keyword[pos]=c;
|
|
|
++ }
|
|
|
++ }
|
|
|
++}
|
|
|
++
|
|
|
+ static void writeSyntaxXML(const Syn_SettingsForDoc &synprefs,
|
|
|
+ const QString &name, const QString &internalName)
|
|
|
+ {
|
|
|
+@@ -95,7 +119,23 @@
|
|
|
+ const Syn_WordList &wordList=*it;
|
|
|
+ CHILD_NODE(list,highlighting,"list");
|
|
|
+ ADD_ATTR(list,"name",wordList.name);
|
|
|
+- QStringList stringList=wordList.list;
|
|
|
++ QStringList stringList;
|
|
|
++ if (wordList.caseSensitive || allWordListsCaseInsensitive)
|
|
|
++ stringList=wordList.list;
|
|
|
++ else {
|
|
|
++ // This is really ugly. Why can't Kate allow me to specify
|
|
|
++ // case-sensitivity per word list?
|
|
|
++ for (QStringList::ConstIterator it=wordList.list.begin();
|
|
|
++ it!=wordList.list.end(); ++it) {
|
|
|
++ const QString &keyword=*it;
|
|
|
++ // This is bad, but I need to cap time, memory and disk space
|
|
|
++ // requirements somewhere.
|
|
|
++ if (keyword.length()<=10)
|
|
|
++ genAllCaseVariants(keyword,0,stringList);
|
|
|
++ else
|
|
|
++ stringList.append(keyword);
|
|
|
++ }
|
|
|
++ }
|
|
|
+ for (QStringList::ConstIterator it=stringList.begin(); it!=stringList.end();
|
|
|
+ ++it) {
|
|
|
+ const QString &keyword=*it;
|
|
|
+@@ -155,8 +195,6 @@
|
|
|
+ ADD_ATTR(detectWordList,"attribute",wordList.name);
|
|
|
+ ADD_ATTR(detectWordList,"context","#stay");
|
|
|
+ ADD_ATTR(detectWordList,"String",wordList.name);
|
|
|
+- if (!(wordList.caseSensitive || allWordListsCaseInsensitive))
|
|
|
+- ADD_ATTR(detectWordList,"insensitive","true");
|
|
|
+ }
|
|
|
+ CHILD_NODE(numFloat,defaultContext,"Float");
|
|
|
+ ADD_ATTR(numFloat,"attribute","Number");
|