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

Home » Public Forums » archive » Two widget questions
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: Two widget questions [message #17773 is a reply to message #17714] Wed, 10 November 1999 00:00 Go to previous message
pln is currently offline  pln
Messages: 10
Registered: September 1991
Junior Member
David Fanning (davidf@dfanning.com) wrote:
: Patrick L. Nolan (pln@egret1.stanford.edu) writes:
:
: > 1. Is it possible to have exclusive button under a menu bar?
:
: No, it is not possible.
:
: Exactly. About the best you can do is have some
: visual way of indicating the menu item is selected.
: For example, you can put an asterisk in front of
: selected items. Here is a small example of how to
: do something like this:
:
<example omitted>

This is a good idea. It's easy to implement and it gives a pretty good
visual impression of the current state.

: ************************************************************ ************
:
: > 2. My base window contains a menu bar, a scrolling list, and a draw
: > widget. I want to handle resize events properly.
: > Is there some general way to deal with this?
:
: Here is what I would do. Just before I realize the TLB
: I would find out what size it is:
:
: tlb_geom = Widget_Info(tlb, /Geometry)
:
: I would use the screen X and Y sizes here. What I want to know
: is how much space in my top-level base is NOT composed of the
: draw widget.
:
: draw_geom = Widget_Info(drawID, /Geometry)
: extraXpixels = tlb_geom.scr_xsize - draw_geom.scr_xsize
: extraYpixels = tlb_geom.scr_ysize - draw_geom.scr_ysize
:
: Now, I would save these numbers in my info structure so that
: when I do the resize I can do something like this:
:
: Widget_Control, info.drawID, Draw_XSize=event.x - info.extraXpixels $
: Draw_YSize=event.y - info.extraYpixels
:
: Sadly, you sometimes still need a "fudge" factor on various platforms,
: since the reporting of sizes is not totally consistent from one platform
: to another. Test it on all the computers you expect to run on. Something
: like this usually works OK.
:
I'm running this on Solaris. By experiment I find that the extraYpixels
is always low by 33 pixels. I suppose that must be the size of the menu
bar.
[Message index]
 
Read Message
Read Message
Previous Topic: contour path info
Next Topic: Re: Object Widgets

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

Current Time: Wed Oct 08 19:25:09 PDT 2025

Total time taken to generate the page: 0.00418 seconds