In QT application on LXDE resize() does not work as expected - desktop

I create a QT application by QT 4.8.2 under Gnome environment. After I changed my desktop environment from Gnome to LXDE, I can not run it. The interface is changed. I can not see the button and toolbar in it. I deleted resize(maximumSize()), then it works well. Anyone can interpret it?
Thanks.

Related

No output from heob in a Qt application using Qt Creator

I would like to use heob to check my app for memory leaks. This is what i tried: I opened the project "analogclock" from the examples collection in qtcreator. After that i have chosen "Analyze" and "Heob" from the drop down menu. After choosing the heob path and a click on the ok button, the application starts and a console window "heob32" is displayed. But now nothing happens. Just the word "kill" is displayed in the console window. I can´t see any output and if i close the analogclock app i get the message: "heob: cannot create target process". Can anyone help me further to get useful output from heob?
What OS are you using and what heob did you install?
You need to download and install heob separately from Creator. Creator just installs a link without heob itself. Have you done this? Are you really running on a 32-bit system (there is a heob64 in case you are using a modern OS).
Did you configure your heob installation in Qt Creator correctly?
Can you run heob from the commandline with reasonable behaviour?

QStrings not showing when debugging with Qt Creator on Windows

I'm debugging a Qt 5.5 application with Qt Creator on Windows 10 using MSVC 2013 compiler.
CDB Debugger is set up in Qt Creator and I can start the debug session. However variable contents of Qt objects (QStrings...) can not be inspected, I just get the memory location, size etc.
I expect I'm missing for debugging helpers or the debugger extension mentioned here.
Any clues what to do?
I temporarily deleted qtcreatorcdbext.dll, started debugger (forcing to diplay an error) and moved the dll back. Now everything works.
It seems there was a problem with the setup procedure, maybe because debugging tools were installed after Qt Creator.
I had to update qtcreatorcdbext.dll in /lib/qtcreatorcdbext32 folder. My Qt creator installed separatly from the Qt pack so I copied the dll from the Qt installation/tools/qtcreator/lib/qtcreatorcdbext32 to the separatly installed qtcreator

Qt Ctrl++ (Control Plus Plus) Shortcut Not Working in Qt 5.5

I've noticed in Qt 5.5.0 and in Qt Creator 3.4.2 (built on Qt 5.5.0), that Actions attempting to use Ctrl++ are not working. Note that the shortcut works correctly in older versions (for example, Qt Creator 2.7.0 built on Qt 5.0.2).
For example, if I try to increase the font size in QtCreator using Ctrl++, nothing happens. The same is true for the ImageViewer example. (Ctrl++ in the ImageViewer increases the image size, but in 5.5.0, it does not work.)
If I bind increasing the font size to another shortcut in QtCreator (via Tools->Options->Environment->Keyboard), such as Ctrl+Z, it works fine.
I did a little debug by overriding keyPressEvent, and it appears that Ctrl++ is being sucked up earlier in the dispatch, but I am having trouble figuring out exactly where.
My questions are:
Is this a bug?
If not, does anyone have any advice on how to see how the key is being dispatched?
This is a confirmed bug in Qt 5.5.0 and appears to be fixed in the latest builds.
There is more information here:
https://bugreports.qt.io/browse/QTBUG-47701

Cannot Connect to QML Emluation Layer (QML Puppet)

I just made the fresh QT installation and when I create empty QT Quick project or open any of existing QT Quick examples, my QML designer doesn't work. It shows "Cannot Connect to QML Emluation Layer (QML Puppet)" error.
I tried to reinstall QT, reboot, installed additional QT kit versions and tried to switch between 32bit/64bit default/opengl versions of the kit and nothing seems to work for me. I was able to successfully run the designer ONCE, and after I closed it and tried to re-open the file it stopped working again. I also tried to search, but didn't find any solution. I also tried to ask on QT forums, but didn't receive any answer.
My system is Windows 7, with Visual Studio 2013 installed. Thanks for your help!
Do this:
Go to QT Creator Preferences (Menu Bar | Tools > Options)
Select QT Quick Option (Options headings - left side).
Click the QT Quick Designer tab.
Under QML Emulation Layer grouping, select "Use QML Emulation Layer that is built with selected QT".
No need to choose a path,
And click OK.
It will rebuild your designer view.
Worked for me.
Possibly related to this bug. Just try this workaround: in the Options
dialog go to “Qt Quick / Qt Quick Designer / QML Emulation Layer” and
disable the checkbox “Always use the QML emulation layer prived by Qt
Creator”. That will cause a rebuild of the emulation layer with the
used Qt version in the current project. That layer does not crash.
This workaround only works with Desktop Kits. – BaCaRoZzo Mar 30
This worked for me on Ubuntu 14.04.
Go to Tools->Options->Qt Quick.
In QML Emulation Layer, make sure
the path is correct for "Use fallback QML emulation layer".
Since I was reinstalling Qt, the new installation had the old path of Qt which gave rise to this issue.
If failed anyway, use "Qt Design studio" instead and build it again, it worked for me.
I recommend to uninstall Qt first and then reinstall it with "Qt Design Studio" box checked.
On Ubuntu 20 LTS, you can run it on: /home/Qt/Tools/QtDesignStudio/bin/qtdesignstudio
Good luck.

Qt Application showing back content

I'm developing an Qt Quick Application with C++ and QML.
The mainwindow doesn't show the content, and shows part of the back window content(the QT IDE)
The problem is when running the project in Debug/Release(both) mode. Running the binary from the project folder works. But I need to test it from debug mode.
I'm using Ubuntu 14.04 (Xfce).
How can I solve it?