Murray Cumming said the following at 11/02/2011 10:30 AM : > On Wed, 2011-11-02 at 09:22 -0600, D. R. Evans wrote: >> Murray Cumming said the following at 11/02/2011 08:21 AM : >>> On Wed, 2011-11-02 at 08:10 -0600, D. R. Evans wrote: >>>> So can anyone suggest a gtkmm-based library that does know about the >>>> Z-order of overlapping widgets? >>> >>> I think you can put widgets in a GooCanvas. GooCanvas has z ordering. I >>> have no idea how well that works. I don't personally think that there's >>> much point in widgets in a regular UI overlapping. I can see the point >>> of them overlapping in a very custom canvas-based UI. >>> >> >> Well if you don't see the point then perhaps I'm missing something. In a >> system without Z ordering how would you deal with the following situation: >> >> I have a multi-container widget and a bunch of widgets are visible. Now the >> user presses a particular key combination and a previously-invisible widget >> needs to appear "in front of" an area of the container. > > Widgets can never be anything but "in front" of their container. You can I understand that they are "in front of" their container, but that's not what I'm having a problem with. It's getting some widgets to be temporarily "in front of" other widgets in the same container. Let me try to be very specific. Perhaps (probably) I am going about this all wrong. For background, I am starting from an ncurses program and simply trying to get something that behaves the same way. So I start with a grid container: +---------------------+ | | | | | | | | | | | | | | | | +---------------------+ Now I put some widgets in it. I'll number the cells to indicate which widget is occupying that cell: +---------------------+ | 00011112223333333333| | 00011112223333333333| | 00011112224444444444| | 55511112226667888888| | 55511112226667888888| | 55511112226667888888| | 55511112226667888888| | 99999999999999999999| +---------------------+ Now, the user presses some key combination which means that I need to display a pre-existing but undisplayed widget A "in front": +---------------------+ | 00011112223333333333| | 00011112223333333333| | 00011AAAAAAAA4444444| | 55511AAAAAAAA7888888| | 55511AAAAAAAA7888888| | 55511AAAAAAAA7888888| | 55511112226667888888| | 99999999999999999999| +---------------------+ Widget A receives keystrokes for a while and then receives a keystroke that tells it to disappear (although it continues to exist and will be logically updated, although the results of such updates are no longer visible on the physical screen until the next time it is displayed), so that the situation returns to: +---------------------+ | 00011112223333333333| | 00011112223333333333| | 00011112224444444444| | 55511112226667888888| | 55511112226667888888| | 55511112226667888888| | 55511112226667888888| | 99999999999999999999| +---------------------+ All dead simple, basic ncurses stuff using panels. So what is the right way to do this in gtkmm? I won't bore you with all the failed attempts I've made to try to get this to work. Doc -- Web: http://www.sff.net/people/N7DR
Attachment:
signature.asc
Description: OpenPGP digital signature