I'm adding some menus in the library manager to get an SVN plug-in (based on some scripts from Poojan Wagh) and everything's going fine apart for the display of the pop-up forms. They appear where the mouse is clicked but always behind the Library Manager... quite unpractical!
I've made some trials and it seems the form pops-up in foreground but LibMgr refreshes right after.
So in the cdsLibMgr.il, adding the menu looks like this
lmgrCreateMenuItem("Menu_svnStLib" "simple" '(("label" "SVN Status") ("callback" ("svnStLib" "updateIf")); ("callback" ("svnStLib" "noOpts" )) ))lmgrAddMenuItems("designCascade" "L" '("Menu_svnStLib"))
and in the procedure itself (buttons defined in the 1st "..."):
procedure(svnStLib(reason Lib Cell View file cat)
...svnStLibForm = hiCreateAppForm( ?name `svnStLibForm ?fields list(newLibField newStTypeButton newAdexlButton newbrowser) ?formTitle "Status Library" ?callback "svnStLibFormCB( svnStLibForm )" ?dontBlock t ) ...hiDisplayForm( svnStLibForm '(-1 -1) ); svnStLibForm->refresh) ; end of procedure
svnStLibForm = hiCreateAppForm( ?name `svnStLibForm ?fields list(newLibField newStTypeButton newAdexlButton newbrowser) ?formTitle "Status Library" ?callback "svnStLibFormCB( svnStLibForm )" ?dontBlock t )
hiDisplayForm( svnStLibForm '(-1 -1) ); svnStLibForm->refresh) ; end of procedure
Now, I've tried with and without the refresh; with it, I get directly my form behind the LibMgr and without I get a pop-up for a refresh and when clicking ok, then my form appears in foreground... thus I think that the refresh (which has to happen at the end of the procedure) may be the cause for this...
I've also tried to put "noOpts" instead of "updateIf" in the createMenuItem of the cdsLibMgr.il; then I don't need any refresh in the procedure anymore, but my form still appears in the background instead of the foreground. Last point, when copying several times (3x) the line with hiDisplayForm(), I get the form still in background but with focus (i.e. I can change the fields directly from keyboard eventhough I don't see the whole form).
I admit I'm a bit lost about this Display behavior. Is anybody familiar with this?
Thanks in advance,Matthieu
My guess is that this is something to do with the "focus stealing prevention" behaviour of your window manager (don't know whether you're using KDE or Gnome or something else) - that's a common cause of popup forms not appearing at the front. It's not really Virtuoso's fault.
If you use Gnome:From a terminal open the gconf editor%> gconf-editorThere goto ‘apps -> metacity -> general’.Look for the option ‘new_windows_always_on_top’ and set it to ‘true’.From:http://support.cadence.com/wps/mypoc/cos?uri=deeplinkmin:ViewSolution;solutionNumber=11612426
If you use KDE:
Control Center -> Desktop -> Window Behavior
Choose the Advanced Tab and set "Focus stealing prevention level:" to None.
Hi Andrew, Bernd, Derek,
Thanks for your answers. I indeed modified my Gnome (v2.16.0) settings and it works fine now!
Thanks a lot,Cheers,Matthieu