comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Keeping Button Pressed In?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Keeping Button Pressed In? [message #46044 is a reply to message #45951] Mon, 24 October 2005 17:05 Go to previous messageGo to previous message
JD Smith is currently offline  JD Smith
Messages: 850
Registered: December 1999
Senior Member
On Mon, 24 Oct 2005 10:41:40 -0700, JD Smith wrote:

> On Mon, 24 Oct 2005 17:08:43 +0000, Dick Jackson wrote:
>
>> Hi again,
>>
>> I've improved this routine a bit, it should be even more useful now!
>>
>> "Dick Jackson" <dick@d-jackson.com> wrote in message
>> news:tAZ6f.274433$oW2.56864@pd7tw1no...
>>> Hi Benjamin:
>>>
>>> "Benjamin Hornberger" <benjamin.hornberger@stonybrook.edu> wrote in
>>> message news:43592bf7$1_1@marge.ic.sunysb.edu...
>>>>
>>>> Interesting. I find it inconsistent though that bitmap buttons behave
>>>> like that, while buttons with a text value (label) turn into radio
>>>> buttons in an exclusive base. What if I want a "depressed" button with a
>>>> text value?
>>>>
>>>> Benjamin
>>>
>>> I've found this to work pretty well, a function that takes the text value
>>> as a string and converts it to the RGB byte array for your Widget_Button.
>>> I realize it's not perfect about aligning one button with no descenders
>>> (e.g., 'GJPY') and another with descenders (e.g., 'gjpy'), but I don't
>>> have time to make that very doable fix right now.
>>
>> That is now fixed, and I'd like to hear how the result looks on a Unix
>> system. Comments are welcome!
>
>
> I think you need to temporarily turn on decomposed color to get the
> button background color correct. The bummer of Motif is that you
> can't get depressed buttons in Exclusive/Non-exclusive bases, so this
> routine helps us little. Instead, you always get a little diamond
> next to the button, be it text or bitmap, to indicate selection
> status. I've worked around this by simulating my own exclusivity and
> changing the button value bitmap to look different when selected.
> It's not ideal. I'm not sure if this is a Motif limitation or an IDL
> limitation (buttons *do* depress when you click them).

I've looked a bit deeper, noticing that iTools on Unix does indeed
have depressed bitmap buttons, and found that the magic keyword
required under Unix (and not Windows) is /TOOLBAR (added with v5.6).
This will dispense with the radio button, and space the buttons close
together, indicating selection status by "depressing" them. Interesting
disparity between Windows/Motif, but I guess the Motif version is a bit
more consistent.

JD
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: random integers between 0 and 1,000,000
Next Topic: Reading UUID from JPEG2000 file

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Sun Oct 12 08:42:59 PDT 2025

Total time taken to generate the page: 2.95836 seconds