Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!sdd.hp.com!elroy.jpl.nasa.gov!decwrl!deccrl!bloom-beacon!eru!hagbard!sunic!mcsun!ukc!pyrltd!root44!praxis!cged!cathy From: cathy@cged.co.uk (Cathy Evans) Newsgroups: comp.windows.x.motif Subject: labelInsensitivePixmap problem Message-ID: <1991Apr10.111948.26461@cged.co.uk> Date: 10 Apr 91 11:19:48 GMT Sender: cathy@cged.co.uk (Cathy Evans) Organization: Computer General Electronic Design, Bath, U.K. Lines: 67 I am using Motif 1.1. I am trying to use the labelPixmap and labelInsensitivePixmap resources of an XmLabel to toggle an icon between two states. Setting labelPixmap works okay, but the bitmap I specify using labelInsensitivePixmap never appears. Am I doing something wrong? I don't have the Motif source, so I can't do any more investigations. I am using WCL and the Mri resource file below demonstrates my problem - I include the bitmaps I'm using for completeness, but any two bitmaps will do. However, the problem is not confined to WCL - I have tried using the labelInsensitivePixmap resource with a standard Motif C program with the same result. =========================================================================== # Resource file for use with Mri # buttonOn sets the label to sensitive displaying the 'on' bitmap, # buttonOff to insensitive and should display the 'off' bitmap (it doesn't) # on.h and off.h are both produced using `bitmap' and are in the # current working directory. Mri.wcChildren: rc Mri.title: Test *rc.wcClassName: XmRowColumn *rc.wcChildren: label, buttonOn, buttonOff, quit *label.wcClassName: XmLabel *label.labelType: PIXMAP *label.labelPixmap: on.h *label.labelInsensitivePixmap: off.h *buttonOn.wcClassName: XmPushButton *buttonOn.labelString: On *buttonOn.activateCallback: WcSetSensitiveCB(*label) *buttonOff.wcClassName: XmPushButton *buttonOff.labelString: Off *buttonOff.activateCallback: WcSetInsensitiveCB(*label) *quit.wcClassName: XmPushButton *quit.activateCallback: WcExitCB =========================================================================== Bitmap file on.h: =========================================================================== #define on_width 16 #define on_height 16 static char on_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x00, 0x84, 0x00, 0x84, 0x26, 0x84, 0x26, 0x84, 0x26, 0x78, 0x2a, 0x00, 0x32, 0x00, 0x32, 0x00, 0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; =========================================================================== Bitmap file off.h: =========================================================================== #define off_width 16 #define off_height 16 static char off_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0xa2, 0x07, 0xa2, 0x00, 0xa2, 0x38, 0x9c, 0x0b, 0x80, 0x08, 0x80, 0x38, 0x80, 0x08, 0x40, 0x08, 0x00, 0x08, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00}; =========================================================================== Cathy Evans Computer General ED, Bath BA1 1JR, UK cathy@cged.co.uk