Qt Creator hangs in Ubuntu Virtualbox - qt

I have a very weird problem. Ive got a an Ubuntu 14.04 running on VirtualBox 4.3.20 r96997. I installed QT Creator a while back and was working with it fine until today. Now when I try to start it, the screen is completely unresponsive, and it endes up freezing (just the QT Creator screen, ubuntu keeps working fine)
I have read in a couple of places that this could be because the welcome mode doesnt play nice with virtualbox 3d hardware acceleration:
Why does Qt Creator 3.0.0 Welcome Mode not work in VM?
http://qt-project.org/forums/viewthread/37412
But im starting ubuntu with the 3d hardware acceleration disabled, and Ive also tried starting it direcly from the terminal by going to the install folder and doing:
./qtcreator -noload Welcome -noload QmlDesigner -noload QmlProfiler
But it also freezes. And the weird thing is that it worked yesterday, and I havent installed any updates or changed the system, it just appears to have stopped working.
Any suggestions?

In the ~/.config/QtProject folder is a lock file (QtCreator.ini.lock). This is the reason why QtCreator freezes. By removing only this file QtCreator will not freeze any more and all the configurations / settings are still there.

Posting my comment as an answer, since OP confirmed it works.
Delete the configuration directory for QtCreator - it's somewhere in ~/.config/

Related

Qt application crash on Wayland

I've recently installed Ubuntu 22.04 LTS on my development laptop. Previously I was running 18.04 so this is my first experience of Wayland. I did a clean installation on a new disc. I had relatively few problems reinstalling gitkraken and cloning the repository of my source code from github but when I came to install the Qt libraries this is where my problems started. The on-line installer from the Qt website simply wouldn't run. It just exited silently. I eventually found an old version of the on-line installer executable in a backup of my downloads folder from Ubuntu 18.04 and was able to use this to download and install the same version of the Qt libraries that I was using previously (5.15.0). This is also the same version that I use on my other development machine which runs Windows 10. Keeping the two in step is useful and upgrading too many things at the same time seemed like asking for trouble. I installed the latest versions of Qt Creator (7.0.1) and g++ (11.2.0).
I was then able to build my application and, after a brief search of stack overflow I added "-platform wayland" to the command line arguments setting in Qt Creator but the application crashed almost immediately on start-up with the error "The Wayland connection experienced a fatal error: Protocol error".
Several things made me think this might be a bug in the Qt libraries rather than my application (none of them definitive!):
At the point of application exit, apart from main() there is none of my application code in the call-stack (see below)
My application has been stable for a long time and has survived several operating system, compiler and Qt version changes across two OS families
The fact that the latest Qt on-line installer (itself almost certainly a Qt application) wouldn't run
I downloaded Qt 5.15.12 (the latest Qt 5 version available) and rebuilt my application against that but the result was the same.
The next step is obviously to strip my application right down to something minimal that still shows the problem but before I do I was wondering whether this is something other people have come across when migrating a Qt5 application to Wayland and whether I need to take the bigger step of upgrading to Qt6? The Qt Wiki describes Qt 5.11 as being "stable" with Wayland.
The call stack at the time of the error looks like this:
qt_message_fatal
QMessageLogger::fatal
QtWaylandClient::QWaylandDisplay::checkError
QtWaylandClient::QWaylandDisplay::flushRequests
doActive
QMetaObject::activate
QSocketNotifier::activated
QSocketNotifier::event
QApplicationPrivate::notify_helper
QApplication::notify
QCoreApplication::notifyInternal2
QCoreApplication::sendEvent
socketNotifierSourceDispatch
g_main_context_dispatch
??
g_main_context_iteration
QEventDispatcherGlib::processEvents
QEventLoop::exec
QCoreApplication::exec
main
Many thanks.
It's something to do with QDialog::setMaximumSize. The call to setMaximumSize itself does not crash but if I remove all calls to it the application works fine. Some controls do subjectively seem bigger on Wayland so I wonder if Qt 5 on Wayland crashes if the size of the QDialog contents exceeds the maximum size specified. This certainly doesn't cause a crash in Qt 5 on Windows and didn't in Qt 5 on Ubuntu prior to the switch to Wayland. I think this is a Qt bug but of course it may well be fixed in a later version of Qt and there's an easy enough work-around now I know the cause.
I was using setMaximumSize to allow the dialog to expand dynamically as widgets were added but to prevent the user from making the window any bigger than it needed to be. layout()->setSizeConstraint(QLayout::SetFixedSize); achieves the same thing.

MAMP icon unresponsive, unable to open

I have just installed MAMP in Windows 10 alongside my class so that we can begin to work with Wordpress. However, the installed icon, and the app itself within my 'start' search function is unresponsive. I always get this popup: "To run this application, you must install .NET Core." The Popup has MAMP.exe in the corner. I did the recommended download at x64, and got confirmation that it was installed, but I got no result. Any time I try to click on the MAMP icon on my desktop, I get that message. I made sure my Skype was off, I checked if I had multiple Apache installations (I saw none except a years-old one in an archived folder) and I restarted my computer but to no avail. I wonder if there is an issue with the path or the browser -- .NET Core was done with Edge, MAMP was done with Chrome. This is mysterious. If anyone has advice on what to try, much appreciated.
I found the answer! Download x86 version of .NET Core and then install it afterward no matter how old your computer is. I did that and it works perfectly now.

Disable TortoiseSVN project Monitor

I installed TortoiseSVN on my work laptop (win 7 Ent.) and tried to integrate Tortoise with R-Studio. But because of some known issues (see here), I did not take it further and disabled subversioning on R-Studio. Since then, when I start R-Studio client, the Tortoise Project Monitor opens up automatically and takes R-Studio into initialization stage until it crashes and I have to kill R-Studio client.
After playing around for few hours, I learnt that I have to open two instances of R-Studio to be able to run it. So, now, I open R-Studio and let it go into initialization stage and then in the meantime, I open another R-Studio and the 2nd one works fine; then I kill first one. But, it is kind of annoying as the trick does not work sometimes.
I uninstalled R-Studio and reinstalled it again and no change. I am afraid if I uninstall TortoiseSVN and then cannot install it again- as it is an open source and there is no support team to help in case of any trouble.
Wondering if anyone has any idea on how to disable project monitoring at all. I don't really need it at all.
Project Monitor can be disabled in Project Monitor Options.

Qt Creator crashes when attempting to open .ui forms editor

Since a week ago, everytime I try to edit a form .ui in my Qt Creator project, the program crashes and closes. This segmentation fault error details are displayed in the image below:
What I already tried
Even if I try to start over a new project, the problem remains.
I tried also to operate Qt Creator with full admin permissions, and
still it fails.
I uninstalled and reinstalled Qt. The same thing happens.
Conditions
I run Qt Creator in a Xubuntu OS (version 14.04).
The Qt version is in the image above.
Has this happened already to you? Any idea what this could be? Any troubleshooting suggestions?
Thank you!
Well, I managed to find a solution that worked.
I opened a terminal and wrote sudo apt-get purge qtcreator* (instead of remove). This way I managed to remove all dependencies.
Then I installed Qt directly from the site: http://www.qt.io/download/
This way worked fine.

Can't edit/drag-and-drop widgets in QtCreator

I am having a slightly bizarre problem and am not sure what is happening so maybe someone else has seen it and could throw some light on the issue.
I have Qt 4.6.1 installed in Ubuntu 12.04 LTS x64 that is running as a virtual guest (VirtualBox) in Windows 7 x32.
Anyway... I have created a new widget and it won't let me edit it or drag widgets onto it. It is almost like it is read-only. The icon when I drag is a circle with a line through it. I have seen mention of a drag-drop problem with Windows 7 but I have tried that fix and it doesn't change anything.
Everything builds and runs, just cannot use the designer at all.
Hopefully this will help someone else who may have the problem as I have found a solution, although not an ideal one.
Basically it seems there might be an issue with the new Unity shell and Qt. I needed to change the shell to gnome and it works now.
In terminal:
sudo apt-get install gnome-shell
Then logged out and switched to Gnome shell and now dragging-and-dropping works. I don't know if the issue is within Virtualbox, Ubuntu 12.04 or Qt

Resources