×

Discussion Board

Results 1 to 8 of 8
  1. #1
    Registered User
    Join Date
    Nov 2006
    Posts
    45

    Errors in QtStyle when running an app through Scratchbox/Xephyr

    I'm attempting to test the graphical library OpenCV using Scratchbox Harmattan target and the Xephyr local X server emulation.

    I immediately get an error and the program exits as soon as the library attempts to create a window. Here is the output:

    1: >>> from cv2 import cv
    2: >>> cv.NamedWindow('foo')
    3: Loading meegotouch-qt-style for plain qt app.
    4: meegotouch-qt-style loading success.
    5: init done
    6: PlainQt Style: virtual QRect QtMaemo6Style::subElementRect(QStyle::SubElement, const QStyleOption*, const QWidget*) const entered before initialization of MComponentData
    7: PlainQt Style: virtual QRect QtMaemo6Style::subElementRect(QStyle::SubElement, const QStyleOption*, const QWidget*) const entered before initialization of MComponentData
    8: PlainQt Style: virtual QRect QtMaemo6Style::subElementRect(QStyle::SubElement, const QStyleOption*, const QWidget*) const entered before initialization of MComponentData
    9: PlainQt Style: Qt Maemo 6 Style init
    10: MApplicationService: registerService() registering failed
    11: MApplicationService: Calling launch() in other application with service : "com.nokia."

    Is there something obviously wrong that I'm doing?

  2. #2
    Super Contributor
    Join Date
    Mar 2009
    Posts
    1,024

    Re: Errors in QtStyle when running an app through Scratchbox/Xephyr

    Have you initialized the Harmattan environment by using "meego-sb-session start" before to run your application?

  3. #3
    Registered User
    Join Date
    Nov 2006
    Posts
    45

    Re: Errors in QtStyle when running an app through Scratchbox/Xephyr

    Yes. I have started Xephyr, and then start the meego environment with that very command, so I have a few icons up on the Xephyr window already such as Mail, Accounts, Settings etc.

  4. #4
    Super Contributor
    Join Date
    Mar 2009
    Posts
    1,024

    Re: Errors in QtStyle when running an app through Scratchbox/Xephyr

    Most of warning messages you got seems to come from the Maemo6 QWidget style.
    You can safely remove it with apt-get install meegotouch-qt-style or you can just start your application with ./myapp -style windows overriding the maemo6 one.
    If it keeps on crashing than it worths to debug your app.

  5. #5
    Registered User
    Join Date
    Nov 2006
    Posts
    45

    Re: Errors in QtStyle when running an app through Scratchbox/Xephyr

    OK, I can see what you are saying but I'm not sure how it applies in this situation exactly.

    Python itself has not been compiled with Qt built in directly as that functionality is in a module. Likewise, OpenCV has been compiled against Qt but my use of it is just as a python module. Therefore I can't use the (presumably Qt-specific) -style parameter to the python binary.

    What I'm not sure about is where the Qt libraries are pulled in and if I'm missing any supporting libraries. I would think having OpenCV built with Qt would be enough for its Python module to work immediately, or would I need to also have (and load) python-qt4 as well? Something tells me "no", as the same problems did not happen for GTK+.

  6. #6
    Registered User
    Join Date
    Nov 2006
    Posts
    45

    Re: Errors in QtStyle when running an app through Scratchbox/Xephyr

    The simple answer was "removing meegotouch-qt-style fixes the problem". My question now is: why? And more importantly, if this is a package that I can expect to be installed on devices by default how will I be able to workaround the issue?

  7. #7
    Super Contributor
    Join Date
    Mar 2009
    Posts
    1,024

    Re: Errors in QtStyle when running an app through Scratchbox/Xephyr

    Why? Because it's not on the device [1]. I know it's in the x86 target, but no idea why it has not been removed from there.

    [1] https://bugreports.qt.nokia.com/browse/QTBUG-20617

  8. #8
    Registered User
    Join Date
    Nov 2006
    Posts
    45

    Re: Errors in QtStyle when running an app through Scratchbox/Xephyr

    OK, fantastic. Thanks for your help!

Similar Threads

  1. gSOAP running standalone server errors
    By amit_tare1 in forum Open C/C++
    Replies: 0
    Last Post: 2010-07-27, 12:51
  2. Replies: 1
    Last Post: 2010-06-01, 07:32
  3. Xephyr server Error
    By dougcn in forum Nokia N9
    Replies: 1
    Last Post: 2009-10-30, 09:45
  4. Errors trying to connect to server running SSL ( 443 )
    By Nokia_Archive in forum WAP Servers
    Replies: 1
    Last Post: 2002-05-16, 18:30

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×