[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdeextragear-2/kile/kile
From: Jeroen Wijnhout <wijnhout () science ! uva ! nl>
Date: 2003-09-05 20:25:24
[Download RAW message or body]
CVS commit by wijnhout:
- ignore \(re)newcommand in parsing the TeX source for section, bibitems etc.
- fix a few #pop's in latex-kile.xml syntax highlighting
M +4 -0 kiledocumentinfo.cpp 1.22
M +3 -3 syntax/latex-kile.xml 1.9
--- kdeextragear-2/kile/kile/kiledocumentinfo.cpp #1.21:1.22
@@ -243,4 +243,5 @@ void KileDocumentInfo::updateStruct(int
QRegExp reRoot("\\\\documentclass|\\\\documentstyle");
QRegExp reBD("\\\\begin\\s*\\{\\s*document\\s*\\}");
+ QRegExp reNewCommand("\\\\(re)?newcommand.*$");
int tagStart;
@@ -260,4 +261,7 @@ void KileDocumentInfo::updateStruct(int
//remove comments
s.replace(reComments, "");
+
+ //if the command is a \renewcommand or \newcommand, ignore rest of \
the line + s.replace(reNewCommand, "");
//find all commands in this line
--- kdeextragear-2/kile/kile/syntax/latex-kile.xml #1.8:1.9
@@ -63,5 +63,5 @@
</context>
- <context name="Label" attribute="Normal Text" \
lineEndContext="#pop" fallthrough="true" fallthroughContext="#pop"> + \
<context name="Label" attribute="Normal Text" lineEndContext="#pop#pop" \
fallthrough="true" fallthroughContext="#pop#pop">
<RegExpr String="\s*\{\s*" attribute="Normal Text" \
context="#stay"/>
<RegExpr String="[^\}]+" attribute="Environment" \
context="#stay"/> @@ -70,5 +70,5 @@
<context name="Verb" attribute="Verbatim" \
lineEndContext="#pop" fallthrough="true" fallthroughContext="#pop">
- <RegExpr String="(.).*\1" attribute="Verbatim" \
context="#pop" minimal="true"/> + <RegExpr \
String="(.).*\1" attribute="Verbatim" context="#pop#pop" minimal="true"/> </context>
<context name="VerbatimEnv" attribute="Environment" \
lineEndContext="#stay"> @@ -82,5 +82,5 @@
<DetectChar char="{" attribute="Normal Text" \
context="#stay"/>
<StringDetect String="verbatim" \
attribute="Environment" context="#stay"/>
- <DetectChar char="}" attribute="Normal Text" \
context="#pop#pop"/> + <DetectChar char="}" \
attribute="Normal Text" context="#pop#pop#pop#pop"/> </context>
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic