If you ever wanted to write a #QuickSetting or #LockScreen plugin for #phosh but didn't fancy #GObject C: Here's an example in #vala : https://gitlab.gnome.org/World/Phosh/phosh/-/merge_requests/1727
If you ever wanted to write a #QuickSetting or #LockScreen plugin for #phosh but didn't fancy #GObject C: Here's an example in #vala : https://gitlab.gnome.org/World/Phosh/phosh/-/merge_requests/1727
What kind of worries me is the observation that many #GObject / #GNOME projects are in a somewhat abondoned state since the overwhelming use of mobile apps and web services around 2012 to 2014. There are some great exemptions like the #Evolution support by #RedHat and all the tools by @linuxmint.
Same is to apply to the #ObjC ecosystem which has seen few new projects since 2015 or so.
So the conclusion is: If I want to improve what I'm using, I need to get my hands dirty and learn to write and fix that kind of software written in #GObject #C.
I'm happy there is @objfw as well which makes facing C less of a pain.
#ObjGTK probably will never be "finished", but it already helps using #GTK without me needing to learn #Rust, which I won't be able to achieve in my spare hours.
It's not that I'm a great fan of the #GObject type system and its way to build object-oriented code in C. I know some of the maintainers aren't as well, which I don't consider a surprise given the age and origin of that GObject ecosystem. So I absolutely understand #Canonical considered switching to #Qt for #Unity8, now #Lomiri.
But that's only one part of the story. The other part is I'm now using #GTK based desktop environments almost full time (only some occasions I turn on my old Mac).
presence
schickt. Den roster
abfragt und einfach Nachrichten (type chat
) senden und empfangen kann.Loading Client Manager...Anwendungsdesign muss ich mir noch mal genauer überlegen. Der ersten Entwurf beinhaltet einen CM (Connection Manager). Der Connection Manager soll alle Accounts und Connections verwalten. Die Connection ist eine funktionale Sicht auf die XMPP Verbindung, währen der XMPP Wrapper die technische Implementierung via #libstrophe bereitstellt.
XMPP> connect
XMPP Connect - JID> demo@domain.tld
XMPP Connect - PWD> 123456
XMPP> Client has been connected with XMPP Server
XMPP> presence
XMPP> message
XMPP Message - JID> stefan@domain.tld
XMPP Message - Text> Hallo! Das ist ein Test :)
XMPP> Message from stefan@domain.tld/Coffein: Hallo. Die Nachricht ist angekommen.
g_signal_connect_object(connection, "connected",Ausblick für den nächsten Meilenstein
G_CALLBACK(cxmpp_connected), connection,
G_CONNECT_SWAPPED);
g_signal_connect_object(connection, "new-contact",
G_CALLBACK(new_contact), connection,
G_CONNECT_SWAPPED);
g_signal_connect_object(connection, "new-chat-message",
G_CALLBACK(new_chat_message), connection,
G_CONNECT_SWAPPED);
g_signal_new("xmpp-new-contact", G_TYPE_FROM_CLASS(klass), G_SIGNAL_RUN_LAST, 0, NULL, NULL, NULL, G_TYPE_POINTER, 1, G_TYPE_POINTER);
g_signal_emit_by_name(userdata, "xmpp-new-contact", 1, buddy);
struct
buddy_t
) an das Signal übergeben.static void xmpp_new_contact(XmppConnection *self, int n, ... ) {Das ist aber wohl nicht ganz richtig,....
va_list args;
va_start(args, n);
for (int i = 0; i < n; i++) {
buddy_t* buddy = va_arg(args, buddy_t* );
g_log(G_LOG_DOMAIN, G_LOG_LEVEL_MESSAGE, "Contact: %s", buddy->jid);
}
va_end(args);
}
I have not blogged or talked about the follow-up work to my "GType Next" blog post that I've been doing in my spare time, mainly because it is happening *in my spare time*, and I don't want to give false impressions to people; the other reason is that the time consuming bit is not writing a bunch of code, but it's planning ahead, because the goal is to avoid breaking stuff at all costs…
i still dislike the way you have to write a lot of boilerplate code every time you want to write a new class in #GObject, but given that it's basically an OOP framework bolted on top of C, i understand why
i tried using #Vala to solve the problem, but encountered different, less solvable problems there
either way, things go on, now i'm trying to figure out how signals work
#RayLib + #Vala bindings + #OOP #GObject wrapper library written in #Vala = the *best* #gamedev experience of all time!!??
Well, we are working on it! :D At least @halfmexican is one of them!
Check out the vapi and WIP wrapper library, for example look at this beautiful `RaylibOOP.Color` class: https://github.com/Charadon/raylib-vapi/blob/main/src/lib/Color.vala
Also this library can of course be used by *all* other GObject language bindings.
And this sample is just the first, more are coming! For direct updates join our discord server!
Write your own Wayland Desktop!
The "Astal" framework, which is written in Vala, makes it super-simple! (you can use it with any gobject-introspection language though)
https://aylur.github.io/astal/
Here a WIP project from our community. So far a custom status bar, quick settings, MPRIS, etc. Together with the Hyprland window manager. Built with #GTK4, #Blueprint, #Libadwaita and of course #Vala!
https://github.com/ARKye03/morghulis
@shriramk meanwhile C developers: What's the problem? ;)