[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y ] [Home]
4chanarchives logo
Name a better C++ framework.
Images are sometimes not shown due to bandwidth/network limitations. Refreshing the page usually helps.

You are currently reading a thread in /g/ - Technology

Thread replies: 77
Thread images: 3
File: Qt_1.jpg (15 KB, 400x400) Image search: [Google]
Qt_1.jpg
15 KB, 400x400
Name a better C++ framework.
>>
GTK

/thread
>>
>>55115720
>works on nothing other than the big 3
>>
>>55115673
there's none. it's the only reason to ever use C++
>>
>>55115673
>Doesn't have microsecond-based event system
Complete and utter garbage
>>
>>55115673
I would, but I can't. It's just fucking good. Simple as that.
>>
>>55115720
OP said better, not worse.
>>
>>55115673
>moc
>>
>>55117258
this, and loading qml and icon/imageformat plugins at runtime is kinda annoying too

There is verdigris though, by the author of moc, that makes it unnecessary

Also 5.6.0 had a few cosmetic bugs that impacted my commercial application, rolled back to 5.5.1 until 5.6.1 came out and fixed them
>>
>>55116409
Wut? You mean one that prevents the CPU from sleeping, draining the battery?
>>
>>55115720
>>55115751
>>55117255
You three are idiots, GTK isn't even C++, it's C.
>>
Despite the huge and disgusting build system, Qt is still the best choice.
>>
File: 1464016298663.jpg (365 KB, 750x725) Image search: [Google]
1464016298663.jpg
365 KB, 750x725
>>55115673
Windows API.

QT is trash desu baka senpai.
>>
What is this? How is it different than an IDE? Why use this over an IDE?

Not shit posting, I actually don't know what you guys are talking about a lot of the time but want to learn more. I read the QT entry on wiki, and it just sounds like an IDE for the purpose of making programs with GUI.
>>
>>55115673
The C++ standard library.
>>
>>55119897
>I actually don't know what you guys are talking about

It shows. Qt is a framework, QtCreator is an IDE.
>>
>>55119897
Qt is a library that has everything and a kitchen sink for you to use when you write your program in C++. Mainly UI related stuff.

Qt does not require an IDE. It can also be used with Visual Studio as IDE and also with Qt Creator - a veruy good IDE created specifically for Qt.
>>
>>55115673
Boost.
>>
>>55119931
Thanks.
>>
>>55119936
but it's 2016 and we have a standardized thread library now
>>
anyone here knows where can i get a general overview of qt?, the documentation only shows specific classes
>>
>>55119967
http://doc.qt.io/qt-5/qt5-intro.html
>>
>>55119954
There is so much more.
I hate the naming madness though.
Looks like Java.
>>
>>55115673
C++11 standard library wait shit >>55119918 beat me to it

>>55119789
But it works in C++ too
>>
I was creating this application where I wanted to make it visual for people to see what was going on.
I put a msleep in the thread so the user could decide the playback speed.
Without thinking more about it, I just let people set a value between 0 and 1000, thinking 0 would be without delay.
But for some reason, msleep(0) puts the thread to sleep and then wakes it up again immediately.
Why would you ever want to do that?
I just made a wrapper to not call msleep if it is zero, but who the hell would implement it like this?
>>
>>55120103
>but who the hell would implement it like this?
someone who wouldn't want to call a function for no reason
>>
>>55119789
gtkmm
>>
>>55120103
>I just made a wrapper to not call msleep if it is zero, but who the hell would implement it like this?

People who figure that the programmer would want the thread to sleep if someone called the sleep function. If the programmer doesn't want it to sleep all he has to do is ... not call the sleep function. This lets you sleep for less than 1ms.
>>
>>55120177
That was what I ended doing.
https://doc.qt.io/qt-4.8/qthread.html#msleep
>Forces the current thread to sleep for msecs milliseconds.
I nearly ripped out the multi threading for this reason, it was a nice setup, but it was slow as hell.
>>
>>55119918
>>55120058
There's a GUI standard library in c++ now?
>>
>>55120543
Read the OP, now read my post.

Now read yours.
>>
>>55120601
Read all of them.
Qt allows you to create UI.
Standard c++ library does not.
Standard c++ library can't be better than Qt.
Hope this helps!
>>
>>55120633
I think you are confused.

We aren't only talking about UI frameworks
>>
>>55120698
Oh, yes. We are finding one that is the best of them all. and those that can't do UI are simply not even qualified to participate.
>>
>>55120726
the standard library allows you to make text user interfaces.

>UI is everything
>>
>>55120785
UI is not everything - just a requirement for a framework that wants to claim the title of the best.
>>
>>55120794
and the standard library meets that requirement
>>
>>55120802
What you consider to be UI is actually not in the eyes of the general public.
>>
>>55120818
are we talking about the best framework for the general public, or are we talking about the best framework for a programmer?

OP's question was vague
>>
>>55120835
Best framework for all those groups combined.
>>
>>55119967
Find some sample code and build from there. The documentation of actually excellent
>>
>>55115751

It barely works at all on anything that isn't Gnome. And where it works, it doesn't play nice with the environment. It's a Gnome-only tool and will hopefully follow that shitty DE into irrelevance.
>>
>>55120844
you're triggering my autism
>>
>>55120911
My apologies.
>>
>>55120914
Can't you make something visually appealing by using standard libraries to resemble what Qt offers?

Of course it is all done in Qt but you can build visual things like buttons and shit by yourself without frameworks.
>>
>>55120934
No, of course not. You only have stdout and stderr to work with - text streams. To draw elements yourself without a dedicated framework you still have to use native API for the platform you're writing for.
>>
>>55120950
I see, can you name some of those platform dependant APIs?
Obviously I am noob in this area, I just wanted to catch some useful info from more knowledgeable anons.
>>
>>55120934
>Can't you make something visually appealing by using standard libraries to resemble what Qt offers?
lol
>>55120965
https://en.wikipedia.org/wiki/List_of_widget_toolkits#OS_dependent
They're all shit, especially MFC.
>>
>>55120965
Win32 API:
http://www.winprog.org/tutorial/simple_window.html

For linux, it's not Linux native API but rather API of X server, a program that hogs the monitor all to itself on a computer running Linux:
https://rosettacode.org/wiki/Window_creation/X11
https://www.x.org/releases/X11R7.6/doc/libxcb/tutorial/index.html

No idea about OSX.
>>
>>55121016
>>55121028
Thank you both. Appreciate it.
>>
>>55119846
i'm using loonix can i learn winAPi inside virtual machine? or it is better to install dualboot?
>>
>>55121879
Wine actually has all of the WinAPI implemented, so you can learn with that.

Just use something like Ollydbg and WinASM and then you're set.
>>
>>55115673

ncurses
>>
File: qt.png (103 KB, 1340x908) Image search: [Google]
qt.png
103 KB, 1340x908
>>
>>55121879
he's trolling, retard. winAPI is an abomination.
>>
>>55115673
Hey, I heard that Qt has some problems with HiDPI scaling. Is that true?
>>
Let's implement a good file picker and HiDPI support. It can't be so hard when we can print with various DPIs since like roughly 30 years
>>
>>55115673
Tcl.
>>
>>55121028
>No idea about OSX.
I'm assuming it would be Cocoa, the previous versions had a different name if I remember correctly.

I'm starting to wonder if it's better to just bite the bullet and always write native UI code, focusing on ease of integration in your common base. Honestly it seems like no matter what you do with UI development you're going to have a bad time or end up with an ugly program.
>>
Which framework provides HTML based GUIs?
And in what language can the code be written in in?

I like HTML because it is so easily understandable and also completely platform independant.
>>
>>55124297
Electon, electron? Something like that. I'm not endorsing it. Why not just use some other structured format like XML, JSON, etc. or have a webui using html in the browser?
>>
>>55120058
>C++11 standard library
even if we disregard the GUI stuff, the parts of Qt that correspond to the standard lib are much better than it
>>
>>55122316
this, 100000 times.
>>
>>55115673
Embarcadero's VCL.
>>
>>55115720
>/threading your own post
>>
>>55126211
dubs confirm
>>
WinAPI.
Literally can't complete with that.
Qt is just overbloated bullshit.
>>
>>55115673

>a better C++ framework
>C++ framework
>C++

Oh boy, here we go..
>>
>>55127547
Unless, of course, you want your program to run on other platforms.

Though then one could argue that'd it'd be better to write native front ends for other platforms (Cocoa/GTK+/whatever).
>>
It's still in the early stages and it's plain C, not C++, but it shows real promise: https://github.com/andlabs/libui

It's a single C-based UI library that compiles to WPF, Cocoa, GTK+, and Qt (your choice) so no matter where you're running, the UI will be truly native (can even make both GNOMEfags and KDEfags happy at the same time) all with a single codebase. It's sanely designed and fills in gaps in functionality between platforms instead of taking the crappy lowest common denominator approach, and has bindings for an increasing number of languages (since it's easy to create bindings to C libraries).

Development has been quite rapid so far and if that continues it'll quickly become one of the better options for cross-platform UI development.
>>
>>55115751
it works on other unix-like OSs
>>
>>55123459
GTK supports HiDPI
>>
>>55123672
used to be carbon i think

>>55124297
electron, you can write in HTML, CSS, and JS
http://electron.atom.io/
>>
>>55127547
>WinAPI

It's an absolute shit. Takes 2000 lines of allocating and filling structs to do anything.
>>
>>55115673
Is there any point to using this framework if you aren't make a GUI app?
>>
>>55128099
>>55124376
Nice, thank you. But coding the logic solely in JS is not really what I am looking for for my idea.

>>55128082
I knew that already, but I like the fact that Qt is crossplatform, I'm tempted to try a project in Qt. I already made the move from iTunes on OS X to Clementine and I haven't looked back since, because now I use Windows, Linux and OS X all at once and do not have to switch my music players anymore. It's always the same. Same goes for FF. Cross platform apps are ultimate killer programs. They make OSs a thing of less importance.
>>
>>55119760
>placing priority on laptops/smartphones over desktops
Complete and utter garbage
Thread replies: 77
Thread images: 3

banner
banner
[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y] [Home]

All trademarks and copyrights on this page are owned by their respective parties. Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
If a post contains personal/copyrighted/illegal content you can contact me at [email protected] with that post and thread number and it will be removed as soon as possible.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com, send takedown notices to them.
This is a 4chan archive - all of the content originated from them. If you need IP information for a Poster - you need to contact them. This website shows only archived content.