gitk: use text labels for next/prev search buttons
gitk allows searching for commits with various criteria, and provides up/down search buttons to facilitate this search. These buttons are labelled with bitmaps, and those bitmaps are not always recolored correctly for the ui scheme as the theme colors are not known. Let's just use text labels on these, allowing the styles to handle any coloring needed. Use utf codepoints for the arrows, presuming that these code points are available in the selected font. Signed-off-by: Mark Levedahl <mlevedahl@gmail.com>
Mark Levedahl committed
Sep 21, 2025 at 15:17 UTC
9950eff84178459a90c6047bb168659b05a998e6
1 file changed
+2
-25
gitk
+2
-25
@@ -2542,31 +2542,8 @@ proc makewindow {} {
2542
# build up the bottom bar of upper window
2543
ttk::label .tf.lbar.flabel -text "[mc "Find"] "
2544
2545
- set bm_down_data {
2546
- #define down_width 16
2547
- #define down_height 16
2548
- static unsigned char down_bits[] = {
2549
- 0x80, 0x01, 0x80, 0x01, 0x80, 0x01, 0x80, 0x01,
2550
- 0x80, 0x01, 0x80, 0x01, 0x80, 0x01, 0x80, 0x01,
2551
- 0x87, 0xe1, 0x8e, 0x71, 0x9c, 0x39, 0xb8, 0x1d,
2552
- 0xf0, 0x0f, 0xe0, 0x07, 0xc0, 0x03, 0x80, 0x01};
2553
- }
2554
- image create bitmap bm-down -data $bm_down_data -foreground $uifgcolor
2555
- ttk::button .tf.lbar.fnext -width 26 -command {dofind 1 1}
2556
- .tf.lbar.fnext configure -image bm-down
2557
-
2558
- set bm_up_data {
2559
- #define up_width 16
2560
- #define up_height 16
2561
- static unsigned char up_bits[] = {
2562
- 0x80, 0x01, 0xc0, 0x03, 0xe0, 0x07, 0xf0, 0x0f,
2563
- 0xb8, 0x1d, 0x9c, 0x39, 0x8e, 0x71, 0x87, 0xe1,
2564
- 0x80, 0x01, 0x80, 0x01, 0x80, 0x01, 0x80, 0x01,
2565
- 0x80, 0x01, 0x80, 0x01, 0x80, 0x01, 0x80, 0x01};
2566
- }
2567
- image create bitmap bm-up -data $bm_up_data -foreground $uifgcolor
2568
- ttk::button .tf.lbar.fprev -width 26 -command {dofind -1 1}
2569
- .tf.lbar.fprev configure -image bm-up
2545
+ ttk::button .tf.lbar.fnext -command {dofind 1 1} -text \u2193 -width 3
2546
+ ttk::button .tf.lbar.fprev -command {dofind -1 1} -text \u2191 -width 3
2547
2548
ttk::label .tf.lbar.flab2 -text " [mc "commit"] "
2549