Real Software Forums

The forum for Real Studio and other Real Software products.
[ REAL Software Website | Board Index ]
It is currently Sat Dec 16, 2017 12:35 am
xojo

All times are UTC - 5 hours




Post new topic Reply to topic  [ 6 posts ] 
Author Message
 Post subject: keep object (canvas/placard) on top
PostPosted: Fri Mar 08, 2013 10:29 am 
Offline

Joined: Wed Jan 09, 2013 5:53 am
Posts: 25
FIrstly...

I did search for this but no answer seemed forthcoming!!. If the answer is elsewhere please just point me in the right direction and accept my apologies.

Secondly...the issue

I have created a contextual menu in a listbox and everything is hunky dory except one thing. I am using celltag to "tag" the listbox entry. So imagine you click on a cell in the list box and the contextual menu gives you say 5 choices. You pick one and off you go to the next bit. However I want the user to be able to click the cell (with the choice already there) and a new menu will be shown asking if these are mutliples of the same choice. e.g.
Listbox cell empty - right click
enter package 1 (for example) as choice from 5 packages.
Package1 appears in cell
Right click again and contextual menu asks if this is package 1a, 1b, 1c etc....

This does have a real life situation. In a lab if an instrument is used for many tests then the tests need to be assigned to Instrument 1 (say) but if instrument 1 is "full to capacity" then the lab need two instruments 1s so the same instrument but occuring twice and used for different things.

(hope that's clear)

So when right clciking the second time I have build a "pop up " box using canvas, placard or groupbox (none are working onthis for me). My idea is to have the placard (say) visible with option for the user to input and ok and cancel buttons. I am using a textfield for input so on ok action it fills the celltag of the listbox cell with the relevant occurance. But each time the placard/canvas/groupbox appears (no problem until user clicks the input textfield) and I click textfield to make the choice the original listbox (which was in the background) comes back to the top (except the textfield) and obscures the canvas/placard/etc... I have tried looking at the focussing but to no available it always seems that the original listbox resurfaces to the top. I have "grouped" all the controls to the canvas so have assumed that if the canvas is on top then the control will be as well...does not seem to be the base

I cannot get the canvas/placard (with it's controls) to "stay on top" until made invisible. happens with scrollbars (in the background) in particular.

ANy help on this? I am sure it's simple and I am expecting a homer simpson moment!?

Thanks a million guys/girls

Nick


Top
 Profile  
Reply with quote  
 Post subject: Re: keep object (canvas/placard) on top
PostPosted: Fri Mar 08, 2013 10:58 am 
Offline

Joined: Mon Oct 13, 2008 4:26 am
Posts: 63
Why not have your contextual menu contain submenus?

Instrument 1
> 1a
1b
1c

Instrument 2
> 2a
2b
2c

or have your first contextual menu appear if the cell is empty and have a conditional menu appear if the cell is populated with a 1st choice selection.


Top
 Profile  
Reply with quote  
 Post subject: Re: keep object (canvas/placard) on top
PostPosted: Fri Mar 08, 2013 1:18 pm 
Offline

Joined: Wed Jan 09, 2013 5:53 am
Posts: 25
pfargo wrote:
Why not have your contextual menu contain submenus?

Instrument 1
> 1a
1b
1c

Instrument 2
> 2a
2b
2c

or have your first contextual menu appear if the cell is empty and have a conditional menu appear if the cell is populated with a 1st choice selection.



Hi

Many thanks for the suggestion and, of course, you're correct. The opening of the placard(or whatever) is from the submenu which I should have been clearer about. Your suggestions have given me some food for thought though. However the issue still remains as to how to keep the placard on top. Essentially the placard is acting like a window (or rather, supposed to). I could open another window but chose this way and found the problem which I cannot solve, so it's a challenge I guess for me to get the answer

Thank you though

Nick


Top
 Profile  
Reply with quote  
 Post subject: Re: keep object (canvas/placard) on top
PostPosted: Fri Mar 08, 2013 2:33 pm 
Offline

Joined: Fri Jan 06, 2006 3:21 pm
Posts: 12388
Location: Portland, OR USA
The placard does not act like a window, and that's your problem. What you have is overlapping controls and that's a recipe for disaster, as either one may need to redraw itself and obscure the other, regardless of Z order.


Top
 Profile  
Reply with quote  
 Post subject: Re: keep object (canvas/placard) on top
PostPosted: Fri Mar 08, 2013 3:03 pm 
Offline

Joined: Wed Jan 09, 2013 5:53 am
Posts: 25
timhare wrote:
The placard does not act like a window, and that's your problem. What you have is overlapping controls and that's a recipe for disaster, as either one may need to redraw itself and obscure the other, regardless of Z order.


Thanks for the clarification on that Tim. So, my understanding is, then there is no real way to do this simply other than pull up a new window?. And, therefore, what is the point of the placard if it is susceptible to what you mention?. Just trying to understand rather than criticize.

Thanks again

Nick


Top
 Profile  
Reply with quote  
 Post subject: Re: keep object (canvas/placard) on top
PostPosted: Fri Mar 08, 2013 6:33 pm 
Offline

Joined: Fri Jan 06, 2006 3:21 pm
Posts: 12388
Location: Portland, OR USA
It's for ornamentation.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 6 posts ] 

All times are UTC - 5 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group