From: Mark Levedahl <mlevedahl@gmail.com>
To: j6t@kdbg.org
Cc: git@vger.kernel.org, Mark Levedahl <mlevedahl@gmail.com>
Subject: [PATCH] gitk: use makedroplist, not ::combobox
Date: Sat, 10 May 2025 13:17:23 -0400 [thread overview]
Message-ID: <20250510171723.32163-1-mlevedahl@gmail.com> (raw)
gitk offers to not use themed tk (ttk), and cannot use such on Tcl/Tk
earlier than 8.5 where ttk was introduced. To facilitate this, widgets
are switched from themed to not by use of the global ${NS}: ${NS} == ttk
to select themed widgets, "" for non-themed. The combobox widget exists
only in ttk, and proc makedroplist exists to create a combobox like
widget using only base tk widgets.
However, 904b36b815 ("gitk: add text wrapping preferences", 2024-12-05),
introduced two instances of ${NS}::combobox, and since that commit,
gitk effectively requires Tk >= 8.5 and themed widgets enabled.
Fix this by using makedropbox instead.
Signed-off-by: Mark Levedahl <mlevedahl@gmail.com>
---
gitk | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/gitk b/gitk
index 11ad639..d48982f 100755
--- a/gitk
+++ b/gitk
@@ -11736,12 +11736,12 @@ proc prefspage_general {notebook} {
grid x $page.tabstopl $page.tabstop -sticky w
${NS}::label $page.wrapcommentl -text [mc "Wrap comment text"]
- ${NS}::combobox $page.wrapcomment -values {none char word} -state readonly \
+ makedroplist $page.wrapcomment -values {none char word} -state readonly \
-textvariable wrapcomment
grid x $page.wrapcommentl $page.wrapcomment -sticky w
${NS}::label $page.wrapdefaultl -text [mc "Wrap other text"]
- ${NS}::combobox $page.wrapdefault -values {none char word} -state readonly \
+ makedroplist $page.wrapdefault -values {none char word} -state readonly \
-textvariable wrapdefault
grid x $page.wrapdefaultl $page.wrapdefault -sticky w
--
2.49.0.99.610
next reply other threads:[~2025-05-10 17:17 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-10 17:17 Mark Levedahl [this message]
2025-05-10 17:52 ` [PATCH] gitk: use makedroplist, not ::combobox Johannes Sixt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250510171723.32163-1-mlevedahl@gmail.com \
--to=mlevedahl@gmail.com \
--cc=git@vger.kernel.org \
--cc=j6t@kdbg.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox