git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mark Hills <mark@pogo.org.uk>
To: Paul Mackerras <paulus@samba.org>
Cc: git@vger.kernel.org
Subject: [PATCH 5/5] gitk: Use consistent font for all text input fields
Date: Wed, 13 Jan 2010 20:40:22 +0000	[thread overview]
Message-ID: <1263415222-5911-5-git-send-email-mark@pogo.org.uk> (raw)
In-Reply-To: <1263415222-5911-4-git-send-email-mark@pogo.org.uk>

Instead of setting the font for specific widgets, set the font for the
widget type. If themed widgets are not available, this is via the X
resources. If themed widgets are available, the theme font is used.

The exception is the SHA1 ID which is forced to use the fixed-width
font, even where themed widgets are used.

Signed-off-by: Mark Hills <mark@pogo.org.uk>
---
 gitk |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/gitk b/gitk
index 54f4fb3..1f5f456 100755
--- a/gitk
+++ b/gitk
@@ -1877,7 +1877,8 @@ proc setoptions {} {
     option add *Menubutton.font uifont startupFile
     option add *Label.font uifont startupFile
     option add *Message.font uifont startupFile
-    option add *Entry.font uifont startupFile
+    option add *Entry.font textfont startupFile
+    option add *Text.font textfont startupFile
     option add *Labelframe.font uifont startupFile
     option add *Spinbox.font textfont startupFile
     option add *Listbox.font mainfont startupFile
@@ -2176,7 +2177,7 @@ proc makewindow {} {
     set findstring {}
     set fstring .tf.lbar.findstring
     lappend entries $fstring
-    ${NS}::entry $fstring -width 30 -font textfont -textvariable findstring
+    ${NS}::entry $fstring -width 30 -textvariable findstring
     trace add variable findstring write find_change
     set findtype [mc "Exact"]
     set findtypemenu [makedroplist .tf.lbar.findtype \
@@ -2219,7 +2220,7 @@ proc makewindow {} {
     pack .bleft.top.search -side left -padx 5
     set sstring .bleft.top.sstring
     set searchstring ""
-    ${NS}::entry $sstring -width 20 -font textfont -textvariable searchstring
+    ${NS}::entry $sstring -width 20 -textvariable searchstring
     lappend entries $sstring
     trace add variable searchstring write incrsearch
     pack $sstring -side left -expand 1 -fill x
@@ -4039,7 +4040,7 @@ proc vieweditor {top n title} {
 	} elseif {$type eq "path"} {
 	    ${NS}::label $top.l -text $title
 	    pack $top.l -in $top -side top -pady [list 3 0] -anchor w -padx 3
-	    text $top.t -width 40 -height 5 -background $bgcolor -font uifont
+	    text $top.t -width 40 -height 5 -background $bgcolor
 	    if {[info exists viewfiles($n)]} {
 		foreach f $viewfiles($n) {
 		    $top.t insert end $f
-- 
1.6.6.5.ge408

  reply	other threads:[~2010-01-13 20:40 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-01-13 20:40 [PATCH resend] gitk: font and theme use Mark Hills
2010-01-13 20:40 ` [PATCH 1/5] gitk: Remove forced use of sans-serif font Mark Hills
2010-01-13 20:40   ` [PATCH 2/5] gitk: Set the font for all spinbox widgets Mark Hills
2010-01-13 20:40     ` [PATCH 3/5] gitk: Set the font for all listbox widgets Mark Hills
2010-01-13 20:40       ` [PATCH 4/5] gitk: Disable option when themed widgets are not available Mark Hills
2010-01-13 20:40         ` Mark Hills [this message]
  -- strict thread matches above, loose matches on Subject: below --
2009-12-28 20:03 [PATCH 1/5] gitk: Remove forced use of sans-serif font Mark Hills
2009-12-28 20:04 ` [PATCH 2/5] gitk: Set the font for all spinbox widgets Mark Hills
2009-12-28 20:04   ` [PATCH 3/5] gitk: Set the font for all listbox widgets Mark Hills
2009-12-28 20:04     ` [PATCH 4/5] gitk: Disable option when themed widgets are not available Mark Hills
2009-12-28 20:04       ` [PATCH 5/5] gitk: Use consistent font for all text input fields Mark Hills

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=1263415222-5911-5-git-send-email-mark@pogo.org.uk \
    --to=mark@pogo.org.uk \
    --cc=git@vger.kernel.org \
    --cc=paulus@samba.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;
as well as URLs for NNTP newsgroup(s).