equal
deleted
inserted
replaced
48 CodeEditor::CodeEditor(QWidget *parent) : QPlainTextEdit(parent) |
48 CodeEditor::CodeEditor(QWidget *parent) : QPlainTextEdit(parent) |
49 { |
49 { |
50 lineNumberArea = new LineNumberArea(this); |
50 lineNumberArea = new LineNumberArea(this); |
51 |
51 |
52 connect(this, SIGNAL(blockCountChanged(int)), this, SLOT(updateLineNumberAreaWidth(int))); |
52 connect(this, SIGNAL(blockCountChanged(int)), this, SLOT(updateLineNumberAreaWidth(int))); |
53 connect(this, SIGNAL(updateRequest(const QRect &, int)), this, SLOT(updateLineNumberArea(const QRect &, int))); |
53 connect(this, SIGNAL(updateRequest(QRect,int)), this, SLOT(updateLineNumberArea(QRect,int))); |
54 connect(this, SIGNAL(cursorPositionChanged()), this, SLOT(highlightCurrentLine())); |
54 connect(this, SIGNAL(cursorPositionChanged()), this, SLOT(highlightCurrentLine())); |
55 |
55 |
56 updateLineNumberAreaWidth(0); |
56 updateLineNumberAreaWidth(0); |
57 highlightCurrentLine(); |
57 highlightCurrentLine(); |
58 } |
58 } |