0000488: python console: buggy CallTips completion for members, starting with underscore ('_')
git-svn-id: https://free-cad.svn.sourceforge.net/svnroot/free-cad/trunk@5152 e8eeb9e2-ec13-0410-a4a9-efa5cf37419d
This commit is contained in:
parent
10b33d91fa
commit
dbbf111ff0
|
@ -579,8 +579,9 @@ void CallTipsList::callTipItemActivated(QListWidgetItem *item)
|
|||
QString sel = cursor.selectedText();
|
||||
if (!sel.isEmpty()) {
|
||||
// in case the cursor moved too far on the right side
|
||||
QChar ch = sel.at(sel.count()-1);
|
||||
if (!ch.isLetterOrNumber())
|
||||
const QChar underscore = QLatin1Char('_');
|
||||
const QChar ch = sel.at(sel.count()-1);
|
||||
if (!ch.isLetterOrNumber() && ch != underscore)
|
||||
cursor.movePosition(QTextCursor::Left, QTextCursor::KeepAnchor);
|
||||
}
|
||||
cursor.insertText( text );
|
||||
|
|
Loading…
Reference in New Issue
Block a user