Fix print cursor position

This commit is contained in:
Vadim Kuznetsov 2024-03-25 09:26:17 +03:00
parent 3ebcd2e2d2
commit 3470ec6507
2 changed files with 4 additions and 4 deletions

View File

@ -61,8 +61,8 @@ TextDoc::TextDoc(QucsApp *App_, const QString& Name_) : QPlainTextEdit(), QucsDo
connect(this, SIGNAL(cursorPositionChanged()),
SLOT(slotCursorPosChanged()));
if (App_) {
connect(this, SIGNAL(signalCursorPosChanged(int, int)),
App_, SLOT(printCursorPosition(int, int)));
connect(this, SIGNAL(signalCursorPosChanged(int, int, QString)),
App_, SLOT(printCursorPosition(int, int, QString)));
connect(this, SIGNAL(signalUndoState(bool)),
App_, SLOT(slotUpdateUndo(bool)));
connect(this, SIGNAL(signalRedoState(bool)),
@ -318,7 +318,7 @@ void TextDoc::slotCursorPosChanged()
QTextCursor pos = textCursor();
int x = pos.blockNumber();
int y = pos.columnNumber();
emit signalCursorPosChanged(x+1, y+1);
emit signalCursorPosChanged(x+1, y+1, "");
tmpPosX = x;
tmpPosY = y;
}

View File

@ -84,7 +84,7 @@ public:
QMenu* createStandardContextMenu();
signals:
void signalCursorPosChanged(int, int);
void signalCursorPosChanged(int, int, QString);
void signalFileChanged(bool);
void signalUndoState(bool);
void signalRedoState(bool);