Home > Community > Forums > Custom IC SKILL > How to get a pop-up in foreground (when LibMgr refreshes)

Email

* Required Fields

Recipients email * (separate multiple addresses with commas)

Your name *

Your email *

Message *

Contact Us

* Required Fields
First Name *

Last Name *

Email *

Company / Institution *

Comments: *

 How to get a pop-up in foreground (when LibMgr refreshes) 

Last post Thu, Jan 3 2013 12:34 AM by Matth83. 4 replies.
Started by Matth83 24 Sep 2012 05:44 AM. Topic has 4 replies and 1449 views
Page 1 of 1 (5 items)
Sort Posts:
  • Mon, Sep 24 2012 5:44 AM

    • Matth83
    • Not Ranked
    • Joined on Mon, Sep 24 2012
    • Posts 13
    • Points 185
    How to get a pop-up in foreground (when LibMgr refreshes) Reply

     Hello,

     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

    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

    • Post Points: 20
  • Wed, Jan 2 2013 5:34 AM

    Re: How to get a pop-up in foreground (when LibMgr refreshes) Reply

    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.

    Andrew.

    • Post Points: 20
  • Wed, Jan 2 2013 7:06 AM

    • berndfi
    • Top 100 Contributor
    • Joined on Tue, Sep 11 2012
    • Neubiberg, Bavaria
    • Posts 66
    • Points 1,250
    Re: How to get a pop-up in foreground (when LibMgr refreshes) Reply

    If you use Gnome:
    From a terminal open the gconf editor
    %> gconf-editor
    There 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

    Bernd
    • Post Points: 20
  • Wed, Jan 2 2013 7:58 AM

    • dmay
    • Top 25 Contributor
    • Joined on Thu, Jul 17 2008
    • Allen, TX
    • Posts 393
    • Points 7,415
    Re: How to get a pop-up in foreground (when LibMgr refreshes) Reply

    If you use KDE:

    Control Center -> Desktop -> Window Behavior

    Choose the Advanced Tab and set "Focus stealing prevention level:" to None.

    Derek

    • Post Points: 20
  • Thu, Jan 3 2013 12:34 AM

    • Matth83
    • Not Ranked
    • Joined on Mon, Sep 24 2012
    • Posts 13
    • Points 185
    Re: How to get a pop-up in foreground (when LibMgr refreshes) Reply

    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

    • Post Points: 5
Page 1 of 1 (5 items)
Sort Posts:
Started by Matth83 at 24 Sep 2012 05:44 AM. Topic has 4 replies.