From 1a89bfbe3459d508b20d20692eac036ff42017cd Mon Sep 17 00:00:00 2001 From: David Schulz Date: Wed, 22 May 2024 06:51:24 +0200 Subject: [PATCH] TextEditor: explicitly set focus to bookmarks note text Allows the user to directly start typing in additional information for a bookmark after triggering the shortcut. This seemed to have happened automatically before, but since this is desired behavior anyhow it's okay to call it explicitly. Fixes: QTCREATORBUG-30829 Change-Id: I77eef2092052e61397f3a73f15c32e909eda01a0 Reviewed-by: Christian Stenger --- src/plugins/texteditor/bookmarkmanager.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/plugins/texteditor/bookmarkmanager.cpp b/src/plugins/texteditor/bookmarkmanager.cpp index 6dcb4de6cc5..a61cc587363 100644 --- a/src/plugins/texteditor/bookmarkmanager.cpp +++ b/src/plugins/texteditor/bookmarkmanager.cpp @@ -876,6 +876,7 @@ void BookmarkManager::edit() auto layout = new QFormLayout(&dlg); auto noteEdit = new QLineEdit(b->note()); noteEdit->setMinimumWidth(300); + noteEdit->setFocus(); auto lineNumberSpinbox = new QSpinBox; lineNumberSpinbox->setRange(1, INT_MAX); lineNumberSpinbox->setValue(b->lineNumber());