From 87c0b76bbd4d488c67f7d0cb6fd14306afb18b0f Mon Sep 17 00:00:00 2001 From: ericm Date: Thu, 11 May 2000 00:40:16 +0000 Subject: Added link relief support. --- win/tkWinButton.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/win/tkWinButton.c b/win/tkWinButton.c index 77135fb..3a78d29 100644 --- a/win/tkWinButton.c +++ b/win/tkWinButton.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tkWinButton.c,v 1.6 1999/09/21 06:43:06 hobbs Exp $ + * RCS: @(#) $Id: tkWinButton.c,v 1.7 2000/05/11 00:40:16 ericm Exp $ */ #define OEMRESOURCE @@ -390,6 +390,20 @@ TkpDisplayButton(clientData) } /* + * LINK relief means that the button has a raised relief when it is + * active, and a flat relief otherwise (like toolbar buttons). It + * is supported for true buttons only. + */ + + if ((butPtr->type == TYPE_BUTTON) && butPtr->relief == TK_RELIEF_LINK) { + if (butPtr->state == STATE_ACTIVE) { + relief = TK_RELIEF_RAISED; + } else { + relief = TK_RELIEF_FLAT; + } + } + + /* * Compute width of default ring and offset for pushed buttons. */ -- cgit v0.12