Results 1 to 3 of 3

Thread: How to get multi-screen count?? (for static libs)

  1. #1
    Join Date
    Jan 2013
    Posts
    1
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default How to get multi-screen count?? (for static libs)

    Platform :
    1-LCD: 1024 × 600
    2-LCD: 1024 × 768
    Qt Creator 2.5.2 Based on Qt 4.8.2 (32bit)
    OS: ubuntu 12.10

    If I use the Qt default dynamic linked (compiler) call
    QApplication :: desktop () -> screenCount (); Ans: 2
    QApplication :: desktop () -> isVirtualDesktop () Ans: true
    QApplication :: desktop () -> screenGeometry (0) Ans: x = 0 y = 0 width = 1024 height = 600
    QApplication :: desktop () -> screenGeometry (1) Ans: x = 1024 y = 0 width = 1024 height = 768

    Qt statically linked (compiler) call
    QApplication :: desktop () -> screenCount (); Ans: 1
    QApplication :: desktop () -> isVirtualDesktop () Ans: false
    QApplication :: desktop () -> screenGeometry (0) Ans: x = 0 y = 0 width = 2048 height = 768
    QApplication :: desktop () -> screenGeometry (1) Ans: x = 0 y = 0 width = 2048 height = 768

    Why statically linked(compiler) information is wrong??
    I hope to get the results of the dynamic linked.
    I build a statically linked less what information (packages).
    I refer to the following message, but no effect
    http://qt-project.org/doc/qt-4.8/install-x11.html

    Does anyone know statically linked wrong?

    Following instruction for the building of static links
    . / configure-release-developer-build-static-platform linux-g + + -32-x11-qt-zlib-qt-libpng-qt-libmng-qt-libjpeg-qt-libtiff-prefix / usr / local / Trolltech / Qt -4.8.2_static

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,373
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Thanks
    4
    Thanked 5,019 Times in 4,795 Posts
    Wiki edits
    10

    Default Re: How to get multi-screen count?? (for static libs)

    You probably forgot to pass some magic switch to configure like -xinerama or something similar.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  3. #3
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts

    Default Re: How to get multi-screen count?? (for static libs)

    Or the dynamic build loads a QPA plugin and the static one included a different one.

    Statically linking Qt is usually a bad idea due to the loss of plugin support.

    Cheers,
    _

Similar Threads

  1. Linking Qt-libs static
    By Simo in forum Qt Programming
    Replies: 1
    Last Post: 5th December 2011, 12:06
  2. building a static lib with links to other static libs
    By hubipet in forum Installation and Deployment
    Replies: 0
    Last Post: 20th October 2011, 19:13
  3. Replies: 3
    Last Post: 25th January 2011, 14:36
  4. Replies: 0
    Last Post: 19th January 2011, 04:29
  5. Using static libs (*.a) in pro file
    By lechoo in forum Installation and Deployment
    Replies: 1
    Last Post: 30th September 2010, 14:59

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.