OSX Fullscreen QWidget over MenuBar and Dock



  • Qt5.6, OS X El Capitan. I need to select an area on the screen to take a screenshot, but the menu bar and dock are always on my window.

    My code:

    QScreen *screen = QGuiApplication::primaryScreen();
    QRect desktop = screen->virtualGeometry();
    
    region = new SelectRegion;
    
    region->setGeometry(desktop);
    region->show();
    region->focusWidget();
    region->activateWindow();
    region->raise();
    

    Screenshot


  • Lifetime Qt Champion

    Hi and welcome to devnet,

    From your screenshot, it looks like you are trying to take a screenshot with OS X tools but not from a fullscreen application. So what exactly are you doing ?


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.