summaryrefslogtreecommitdiffstats
path: root/generic/tkEntry.c
diff options
context:
space:
mode:
authorjingham <jingham@noemail.net>1999-08-10 05:04:44 (GMT)
committerjingham <jingham@noemail.net>1999-08-10 05:04:44 (GMT)
commitc582bf35bf20084065646debe5530181755dd44e (patch)
tree7316e518597bb3d84ce7a7a7cabcf5b05832add8 /generic/tkEntry.c
parent961a6ba6f98f8f6bbb1f1654697976bd4771cc6d (diff)
downloadtk-c582bf35bf20084065646debe5530181755dd44e.zip
tk-c582bf35bf20084065646debe5530181755dd44e.tar.gz
tk-c582bf35bf20084065646debe5530181755dd44e.tar.bz2
New Function: TkpDrawHighlightBorder. Use this in place of Tk_DrawFocusHighlight. The latter did not work on the Mac, since you need to know both foreground & background color when you draw the active focus ring.
FossilOrigin-Name: 9bb078186f93162afcdcd453066e44b705aa8186
Diffstat (limited to 'generic/tkEntry.c')
-rw-r--r--generic/tkEntry.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/generic/tkEntry.c b/generic/tkEntry.c
index fb3af5e..fd46cb3 100644
--- a/generic/tkEntry.c
+++ b/generic/tkEntry.c
@@ -11,7 +11,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkEntry.c,v 1.4 1999/04/24 01:50:47 stanton Exp $
+ * RCS: @(#) $Id: tkEntry.c,v 1.5 1999/08/10 05:05:48 jingham Exp $
*/
#include "tkInt.h"
@@ -1405,14 +1405,17 @@ DisplayEntry(clientData)
entryPtr->borderWidth, entryPtr->relief);
}
if (entryPtr->highlightWidth != 0) {
- GC gc;
+ GC fgGC, bgGC;
+ bgGC = Tk_GCForColor(entryPtr->highlightBgColorPtr, pixmap);
if (entryPtr->flags & GOT_FOCUS) {
- gc = Tk_GCForColor(entryPtr->highlightColorPtr, pixmap);
+ fgGC = Tk_GCForColor(entryPtr->highlightColorPtr, pixmap);
+ TkpDrawHighlightBorder(tkwin, fgGC, bgGC,
+ entryPtr->highlightWidth, pixmap);
} else {
- gc = Tk_GCForColor(entryPtr->highlightBgColorPtr, pixmap);
+ TkpDrawHighlightBorder(tkwin, bgGC, bgGC,
+ entryPtr->highlightWidth, pixmap);
}
- Tk_DrawFocusHighlight(tkwin, gc, entryPtr->highlightWidth, pixmap);
}
/*