Juce is another interesting UI lib https://www.juce.com/ Works with Windows, Mac OS, Linux, iOS and Android. Strangely, juce seems to have a revamped website that has no pictures or screenshots of the juce user interface and its widgets. Weird. Not sure how effective that marketing is...
Libui: GUI library in C
51–60 of 186 posts
Re: Libui: GUI library in C
#52I was recently thinking that operating systems should ditch their custom desktops in favor of a browser based UI. Microsoft tried this idea out and it didn't work a few years back but it still seems to me that a browser based OS UI would be far more effective than things like Gnome and KDE and all that stuff. Edit: well I guess Google had the same idea long ago and called it ChromeOS - browser as OS interface.
> I was recently thinking that operating systems should ditch their custom desktops in favor of a browser based UI. Why? > it still seems to me that a browser based OS UI would be far more effective than things like Gnome and KDE and all that stuff. How so? My needs haven't changed. I still need a UI that provides a searchable launch menu, some quick-launch buttons, window management, etc. Rendering a bunch of things…
Because somehow websites end up (can end up) looking great, but all those Linux desktops look shit. Things don't line up, the margins and spacing are wrong. It looks like it's made from a set of ill fitting phony knockoff lego bits that don't fit together.
If web browsers make it possible to design slick interfaces then the Linux desktop folks should get onto that quick smart.
Having said that, I guess that's what ChromeOS is eh?
Re: Libui: GUI library in C
#53> that uses the native GUI technologies of each platform it supports. WPF is native on Windows, Win32/WinForms is also native on Windows. I'm assuming it uses Win32, although a third party FFI to WPF would be very, very nice.
If you only have a button and a text field and want to make stuff happen when the button is clicked, then I doubt there is any difference in whether it uses Win32 or WPF.
Re: Libui: GUI library in C
#54Finally. I'm hoping that a native UI toolkit that can be used via FFI from nearly any language might take a chunk out of the Web-as-application-delivery-platform mindset. I don't blame anyone for making non-native apps with Electron and HTML5, because it's so difficult to make them work on every platform. But here's to hoping someone finally got it right, and that native applications can take back some ground. Death…
What's old is eventually new again.
Re: Libui: GUI library in C
#55> that uses the native GUI technologies of each platform it supports. WPF is native on Windows, Win32/WinForms is also native on Windows. I'm assuming it uses Win32, although a third party FFI to WPF would be very, very nice.
WinForms/Win32 is the first UI platform that Windows supported. It's getting less used because of the new UI platforms.
I don't really understand how do they define WPF, UWP, XAML and DirectUI now or how do they compare. XAML was the language used behind WPF but it seems they have changed the terms.
The start menu in Windows 10 was created in XAML: https://news.ycombinator.com/item?id=9968679
Edit: Found this: https://news.ycombinator.com/item?id=11498366
Re: Libui: GUI library in C
#56Very interesting indeed. It supports MacOS X which is a nice addition to my other favorite, the IUP. http://webserver2.tecgraf.puc-rio.br/iup/
Re: Libui: GUI library in C
#57Re: Libui: GUI library in C
#58These APIs are notoriously hard to get right and coherent, and releasing at such an early stage will make it hard to change anything when building up on this. That said I do not know of any cross platform library in C, so this does seem to fill a niche.
Re: Libui: GUI library in C
#59As far as I understand from the source code, libui is a thin C wrapper that makes calls to each platform native ui framework. For instance, to create a window on OSX it calls the corresponding Cocoa function, for Linux the corresponding GTK function, etc. So, unlike Qt and GTK which are heavy cross-platform libraries because they can "draw" their own widgets themselves, this library seems to just call other functions. In that sense, the resulting widgets are as native as they can be!
Qt, Gtk and others are from those old days when everyone wanted alternatives to native frameworks that could "draw" their own widgets. That is why Qt and GTK are/were useful to build the native desktop frameworks of Linuxes.. In these modern times that everyone has moved to Web, things on the desktop-land are far more stable and it is common agreement that Cocoa is perfectly fine for Mac, Win32 is perfectly fine for Windows and GTK is perfectly fine for Linux. This is great news, so now it is the best time to make thin wrappers around these stable things so that we can all go make useful software..
As for the why C and not anything else, is just that all these UI native frameworks can be easily called from C, and C is the common denominator of other higher level languages. So, in theory, each programming language that can interface with C (99.9% of them can) can call the functions of this libui. This means that, in theory, we can all start building 100% native desktop applications in our favorite languages with a lightweight library.. Now I'm off to start pylibui.. ;)
Re: Libui: GUI library in C
#60Why would anyone write a GUI app in C? Almost every alternative is better for the job.
- huge binaries (or dependencies)
- slow compiles
- slow runtime
- garbage collection
- non-portability
- C++ (I just don't like it)
...pretty much every popular language other than C falls into one or more of the above.
Yeah, I know I'm fussy.