QmlJS: Allow folding of multi-line comments.

This also makes the editor auto-fold the license comment.

Task-number: QTCREATORBUG-1455
Reviewed-by: Erik Verbruggen
This commit is contained in:
Christian Kamm
2010-05-27 11:26:20 +02:00
parent 385034722c
commit 57f2b3e44d
4 changed files with 21 additions and 10 deletions

View File

@@ -77,13 +77,18 @@ public:
class QMLJS_EXPORT Scanner
{
public:
enum {
Normal = 0,
MultiLineComment = 1
};
Scanner();
virtual ~Scanner();
bool scanComments() const;
void setScanComments(bool scanComments);
QList<Token> operator()(const QString &text, int startState = 0);
QList<Token> operator()(const QString &text, int startState = Normal);
int state() const;
bool isKeyword(const QString &text) const;