Summary: | Word left/right does not respect C operators | ||
---|---|---|---|
Product: | [Applications] kate | Reporter: | Jon Smirl <jonsmirl> |
Component: | syntax | Assignee: | KWrite Developers <kwrite-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | jfirebaugh |
Priority: | NOR | ||
Version: | SVN | ||
Target Milestone: | --- | ||
Platform: | Compiled Sources | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: |
Description
Jon Smirl
2004-10-03 03:34:37 UTC
The "language specific syntax highlighting modules" are part of Kate. Reassigning. *** Bug 91038 has been marked as a duplicate of this bug. *** CVS commit by alund: fix #90681 backport follows CCMAIL: 90681-done@bugs.kde.org M +9 -4 katehighlight.cpp 1.183 M +7 -2 katehighlight.h 1.82 --- kdelibs/kate/part/katehighlight.cpp #1.182:1.183 @@ -1979,6 +1979,8 @@ int KateHighlighting::hlKeyForAttrib( in bool KateHighlighting::isInWord( QChar c, int attrib ) const { + kdDebug(13010)<<"KateHighlighting::isInWord("<<c<<", "<<attrib<<")"<<endl; + kdDebug(13010)<<"i have this numnber of strings: "<<m_additionalData[0].count()<<endl; static const QString& sq = KGlobal::staticQString(" \"'"); - return getCommentString(3, attrib).find(c) < 0 && sq.find(c) < 0; + return getCommentString(4, attrib).find(c) < 0 && sq.find(c) < 0; } @@ -1986,5 +1988,5 @@ bool KateHighlighting::canBreakAt( QChar { static const QString& sq = KGlobal::staticQString("\"'"); - return (getCommentString(4, attrib).find(c) != -1) && (sq.find(c) == -1); + return (getCommentString(5, attrib).find(c) != -1) && (sq.find(c) == -1); } @@ -2005,4 +2007,7 @@ bool KateHighlighting::canComment( int s QString KateHighlighting::getCommentString( int which, int attrib ) const { + if ( noHl ) + return which == 4 ? stdDeliminator : ""; + int k = hlKeyForAttrib( attrib ); const QStringList& lst = m_additionalData[k]; --- kdelibs/kate/part/katehighlight.h #1.81:1.82 @@ -169,5 +169,5 @@ class KateHighlighting * Define comment marker type. */ - enum commentData { Start, End, MultiLineRegion,SingleLine }; + enum commentData { Start, End, MultiLineRegion, SingleLine }; /** @@ -195,4 +195,9 @@ class KateHighlighting QString getCommentSingleLineStart( int attrib=0 ) const; + /** + * @return the attribute for @p context. + */ + int attribute( int context ) const; + void clearAttributeArrays (); CVS commit by alund: Backport fix for 90681 CCMAIL: 90681@bugs.kde.org M +3 -0 katehighlight.cpp 1.171.2.4 --- kdelibs/kate/part/katehighlight.cpp #1.171.2.3:1.171.2.4 @@ -1990,4 +1990,7 @@ bool KateHighlighting::canComment( int s QString KateHighlighting::getCommentString( int which, int attrib ) const { + if ( noHl ) + return which == 3 ? stdDeliminator : ""; + int k = hlKeyForAttrib( attrib ); const QStringList& lst = m_additionalData[k]; |