summaryrefslogtreecommitdiffstats
path: root/unix
diff options
context:
space:
mode:
authorhobbs <hobbs>2004-05-03 23:23:14 (GMT)
committerhobbs <hobbs>2004-05-03 23:23:14 (GMT)
commit54dcf4f1b84596fa9f6efe96936510c3ad594b14 (patch)
tree53a81f709c7d3ddc663ae9f0b9eaa5b2ac1262fa /unix
parent97fa7ebd6f2a17c1baa3ad2b199a7fa35650ba0a (diff)
downloadtk-54dcf4f1b84596fa9f6efe96936510c3ad594b14.zip
tk-54dcf4f1b84596fa9f6efe96936510c3ad594b14.tar.gz
tk-54dcf4f1b84596fa9f6efe96936510c3ad594b14.tar.bz2
* win/tkWinMenu.c, unix/tkUnixMenu.c (DrawMenuEntryLabel): place
images of compound menu entries in indicator space if not a radio of checkbutton. [Bug #756952] (eserte)
Diffstat (limited to 'unix')
-rw-r--r--unix/tkUnixMenu.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/unix/tkUnixMenu.c b/unix/tkUnixMenu.c
index 1e6a682..c96dd9b 100644
--- a/unix/tkUnixMenu.c
+++ b/unix/tkUnixMenu.c
@@ -8,7 +8,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkUnixMenu.c,v 1.9 2003/08/14 12:30:11 dkf Exp $
+ * RCS: @(#) $Id: tkUnixMenu.c,v 1.10 2004/05/03 23:23:14 hobbs Exp $
*/
#include "tkPort.h"
@@ -763,10 +763,23 @@ DrawMenuEntryLabel(menuPtr, mePtr, d, gc, tkfont, fmPtr, x, y, width, height)
break;
}
case COMPOUND_LEFT: {
+ /*
+ * Position image in the indicator space to the left of the
+ * entries, unless this entry is a radio|check button because
+ * then the indicator space will be used.
+ */
textXOffset = imageWidth + 2;
textYOffset = 0;
imageXOffset = 0;
imageYOffset = 0;
+ if ((mePtr->type != CHECK_BUTTON_ENTRY)
+ && (mePtr->type != RADIO_BUTTON_ENTRY)) {
+ textXOffset -= indicatorSpace;
+ if (textXOffset < 0) {
+ textXOffset = 0;
+ }
+ imageXOffset = -indicatorSpace;
+ }
break;
}
case COMPOUND_RIGHT: {