Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Qt Creator 4.7.0 released (qt.io)
146 points by ScottWRobinson on July 18, 2018 | hide | past | favorite | 38 comments


Qt Creator is a fantastic editor and IDE. If you're doing cross-platform GUI development, Qt is a good choice (especially compared to something grotesque and unseemly like Electron), and for Qt development, Qt Creator is as good as it gets. But it turns out that it works really well for generic C and C++ development too, even with obscure C like the Linux kernel, thanks to the Clang code model. I use Qt Creator sometimes when working on WireGuard (in addition to the usual typical vim/cli flow).


Yep, if you can even compare Electron to Qt. Electron is just a buggy ill-conceived hack to wrap a browser with nodejs to make webpages. All it provides is a blank window with no customisation and a huge size and memory overhead.


I hate the slowness and bloat and entire ideology behind electron, BUT...electron apps do a pretty decent job of feeling native on the platform. Something I've never seen a Qt app do.

Would love a counter-example, if you've got one. I'm on a mac.


I can't think of a Qt app that looked odd on macOS. I've developed quite a few pieces of software in Qt for the mac, and they all perfectly use the OS's styles and colors.


Is any of the software publically available? I will critique it.


I know Viber is written in QT, it does not look native on macOS.


What Electron applications feel native on any platform? I use Discord and it feels and looks like a web-page, not a Windows application.


I feel like slack is decent. It definitely feels like a webpage, but the embedded UI elements are good -- the text boxes support all the MacOS shortcuts, you can insert special characters using the character viewer, text selection works properly, the menus aren't weird.

I guess maybe I'm just so used to web stuff now that that codes as "native enough" to me?


interestingly, it looks and feels like an electron web-page. They're all following their own little paradigm now..


It's only a problem on Mac.

Windows native apps all look different anyway and Qt is native on Linux.


I wouldn't know, dont have a mac. But VLC is my best guess at polished software that should look good on mac. If it doesnt... ;/


I don't think VLC is using Qt!


Yessss it is. The gui is written in Qt c++ and all the processing backend is C.

https://github.com/videolan/vlc/tree/master/modules/gui/qt


Only for nix -- for the Mac, it's using native widgets, if I'm not mistaken:

https://github.com/videolan/vlc/tree/master/modules/gui/maco...

(Which is pretty damning -- they already had a Qt implementation, but would rather do real native!)


Ouch. Mac for Qt is definitely the weakest point. Theres some experimental work being done to allow developers to wrap native Mac controls. http://blog.qt.io/blog/2017/02/06/native-look-feel/


This would help a lot, I think. Still a going concern, or a dormant experiment?


Its targeted for Qt6, which is not coming anytime soon, but it gives me hope that Qt always has smart options to move on.


VSCode, Figma.


I've never heard of Figma, but the reason VSCode is as good as it is now is because it's has had increasing parts of it being re-written in C or C++ along with other extensive performance modifications to the electron runtime by the vscode team.


> the reason VSCode is as good as it is now is because it's has had increasing parts of it being re-written in C or C++

Is that true? I've heard that said before but I've also heard that's not true. I haven't been able to find anything indicating any parts of it are written in C/C++ either. The GitHub repo for VScode doesn't have any C in it; infact it doesn't have much but JS/TS:

https://github.com/Microsoft/vscode


I do not know vscode but Atom's C++ parts are in a separate repo https://github.com/atom/superstring


I agree. Afaik the core of the editor logic in VsCode is all typescript.

There are some native parts, like obviously electron. And I think the find-in-files function uses ripgrep, which is written in rust. But that's a far stretch from "increasing parts of it being re-written in C or C++".


not always true, sometimes they use better data structures

https://code.visualstudio.com/blogs/2018/03/23/text-buffer-r...


That's a really interesting link; thanks.


Some people even prefer Qt Creator to CLion.


These guys continue to do a great job. If you're looking for a nice cross-platform C++ IDE that supports multiple build systems this is it. I'm looking forward to upcoming meson integration (GSoC project IIRC).


It's also got a quite usable Vim mode.


Second this. Fakevim in Qt Creator is one of the better Vim emulation implementations. Not perfect, but it's at least 90% of the way there. Probably 100% if you don't use lots of crazy ex commands like I do


Fakevim doesn't support :wqal or even some basic movements and range specifiers. It may be usable but it's hardly an elegant implementation that only misses "crazy ex commands".


Anyone have a good way to run Qt Creator locally on their desktop, but edit, build, and debug code running on a remote, headless server?

I love Qt Creator, but this use-case has led me to settle for Vim+gdb over ssh.

[edit] Clarification: X-over-SSH isn't a good solution because of the lag.


TL;DR: Just set up the "Build" toolchain (configuration) in Qt Creator and point Qt Creator at your target (with the correct ssh user login) for when you click "Run" or "Debug".

http://wiki.qt.io/Raspberry_Pi_Beginners_Guide http://wiki.qt.io/RaspberryPi2EGLFS

These two tutorials use slightly different setups, so don't get confused on details, but both are great to glean tips from.

I've successfully used Qt Creator on both a Linux VM (desktop Intel) and a Windows desktop to build originally-desktop-based Qt projects for embedded Linux on ARM. The projects are not headless, but also do not use X to run the Qt GUI. Instead they use EGLFS.

Even if your software doesn't have a GUI, you can still do remote debugging with Qt Creator... or Eclipse, or Visual Studio , or anything that has the proper hooks.

I don't think any sane developer would want to use a remote X server to get to an instance of an IDE.

As long as you have the proper cross toolchain (some cost $) set up correctly in Qt, and your target code is all included properly (libraries and headers for your target, NOT your dev machine), you should be able to do exactly what you want for any desktop+remote target pair.

Additionally you don't even have to work in Linux to target Embedded Linux:

https://wiki.qt.io/Visual_Studio_Add-in https://blogs.msdn.microsoft.com/vcblog/2016/03/30/visual-c-...


Specifically, I think the tip to make an exact copy of the target's sysroot structure (libraries, headers, etc) on your dev machine using rsync (and remember to fix the symbolic links!) is very valuable.

Then make sure your project is (only) aware of those headers and libraries.


Are you looking for something like Emacs' Tramp mode (https://www.emacswiki.org/emacs/TrampMode)?

We've been working on an equivalent that can work with IDEs like QtCreator.

Send me a note to the email in my profile, lets see if we can help out.


have you tried sshfs?


That's just going to do remote file management, and introduce small lockups when you hit ^S if your latency is unideal.

I'm not sure if distcc is the answer here - I've never tried it - but it probably would be some people's default/first response.


This is the IDE I use with pleasure. Very intuitive and fast.


I'd like to mention that the IDE has a scxml editor which I've been abusing for generating business logic lately.


C# C# C# one day?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: