10
submitted 2 days ago* (last edited 2 days ago) by Adniem@thelemmy.club to c/asklemmy@lemmy.world

well here is the brief concept:

it is a markup language for APP (NOT WEB) GUI's, for Linux

but:

1: it does not have to depend on a single GUI Toolkit (GTK Or QT)

2: it depends on external Programs called "Translators" which translate the Markup language calls and whatever onto something your GUI Toolkit understands

3: it does not manage any form of functionality whatsoever, you have to depend on a another language to do that

what it aims to do:

sometimes a GTK app on a QT Desktop Environment

just does not match the theme

which that idea aims to solve

how would you fix it

all 29 comments
sorted by: hot top new old
[-] whaleross@lemmy.world 23 points 2 days ago

Congratulations. You have invented HTML.

[-] one_old_coder@piefed.social 6 points 2 days ago

Or any DSL with most of the functions removed (like Tk since 1991 but I'm sure there is older stuff).

[-] Adniem@thelemmy.club 2 points 2 days ago* (last edited 2 days ago)

maybe like html in being markup

but my concept does not aim for the web but for normal apps

[-] one_old_coder@piefed.social 6 points 2 days ago

You can use HTML for any kind of application, it has a lot of widgets. Even Qt widgets can be themed with HTML.

[-] Adniem@thelemmy.club 2 points 2 days ago

but i definitely think that html was not designed for this

and i think that this may have severe limitations

[-] one_old_coder@piefed.social 7 points 2 days ago

You're right, but in the end you can generalize HTML to XML, and XML to any other simplified DSL.

The missing link is the library that can detect the desktop framework, and create the proper widgets. Here is what you would need to support: https://en.wikipedia.org/wiki/Comparison_of_X_Window_System_desktop_environments#Desktop_comparison_information

It's a long list and I don't think anyone has tried to do that properly, and it's more complex because some environments use a global "application" object (Qt) while others have some kind of event loop (maybe Gtk, and Win32). It's a pain in the ass I guess.

[-] flamingos@feddit.uk 5 points 2 days ago

What are you aiming to fix with this? I'm not sure I understand why this would be desirable.

[-] Adniem@thelemmy.club 3 points 2 days ago

well it is that if you use a GTK app on QT you get a non consistent look

so it is for fixing that

[-] flamingos@feddit.uk 3 points 2 days ago

How would a markup language help with that? A markup language defines structure; is your idea that the app would look mostly the same but just use the toolkits widgets? Because that won't mean an app looks consistent with the desktop, eg having a GTK app with a menubar will not look right on GNOME.

[-] TootSweet@lemmy.world 4 points 2 days ago

Not sure I'm fully understanding you, but it kinda sounds like QML, except that QML is QT-specific.

Are you looking to create something, or are you looking for something existing?

[-] Adniem@thelemmy.club 1 points 2 days ago

well imagine it as a HTML like

but designed for app GUI's on linux

but instead of being specific to QT or GTK it can work on both and still look normal

and the actual turning the language into something that GTK or QT understands, is done by a "Translator", something that turns the code onto something that your DE or Toolkit understands (like a interpreter but instead of machine code its the thing that QT or GTK understand)

and i am not looking for something like it

[-] TootSweet@lemmy.world 2 points 2 days ago

I'm still not fully understanding you, but if you're building something, I'd like to suggest that you don't make it yet another abstraction layer on top of things like QT or GTK. QT and GTK are really heavy and bloated already. Adding something on top will just compound the issue.

I dunno. I personally don't care enough about interface/look-and-feel consistency to think it warrants more computational complexity. I'm a big fan of applications that depend directly on things like XCB. I don't know if there's an equivalent to XCB for Wayland. I think mostly the Wayland people themselves recommend that people write client applicatons with QT or GTK or whatever, but if I found apps written directly against libwayland, I'd be inclined to prefer those over a QT or GTK alternative.

[-] balsoft@lemmy.ml 2 points 2 days ago

Wayland just gives you a buffer to write to, it doesn't give you drawing primitives in the way XCB does. It's kinda the point, and makes implementing display servers/compositors a lot simpler and easier, and most apps will be using some kind of non-XCB toolkit anyways.

So if you're making an app you do kinda need a toolkit, but it can be a very simple and lightweight one.

[-] TootSweet@lemmy.world 1 points 2 days ago

most apps will be using some kind of non-XCB toolkit anyways.

Not my favorites. I'm mostly thinking of the Suckless sort of tools. dmenu, st, dwm, etc.

But yeah. If a toolkit is necessary for Wayland, then I'd love some extremely minimal options. Or better yet, exactly one minimal option so good that nobody ever feels the need for an alternative. (But that's not going to happen. Heh.)

I've poked a little bit at the Go GUI toolkit "Fyne". It appears to use OpenGL/GLFW, which is kinda neat, I think. Looks like GLFW's dependencies are indeed quite minimal.

[-] balsoft@lemmy.ml 2 points 2 days ago

You can of course just write to the compositor socket directly without relying on any third-party dependency. But it will be very tedious and you will basically end up making your own toolkit (which is coincidentally kinda how GTK started).

[-] balsoft@lemmy.ml 1 points 2 days ago

Knowing some stuff about the APIs of Qt and GTK, it would be a mighty difficult task to do properly. Qt and GTK don't really "understand" anything, while they both have a declarative markup language (QML for Qt, GtkBuilder XML for Gtk) those are kinda just bolted-on to the imperative/object-oriented cores; that is to say, the abstractions they provide depend on a internal details and external libraries, and it would be a massive pain to design a single language around the constraints and idiosyncrasies of those two.

So, instead of translating to those existing declarative languages, you're probably better off just reimplementing your language in terms of the framework-native approach (imperative widget creation and a mainloop for GTK, OOP&signals for Qt). But this is also a lot of work to get right, even if you limit the available functionality.

An LLM can probably vomit out a prototype for this in an hour, but I feel it will not be very useful to actually make apps.

In short, you're probably better off just reading https://wiki.archlinux.org/title/Uniform_look_for_Qt_and_GTK_applications and setting QT_QPA_PLATFORMTHEME=gtk3 or smth.

[-] Ephera@lemmy.ml 4 points 2 days ago

Markdown was built to be easily translatable to HTML, so a simple web rendering engine like Servo is probably your best bet.

pandoc can be used to convert Markdown to HTML, for example.

[-] Adniem@thelemmy.club 3 points 2 days ago

i may have to edit my post to clearly reflect it that it is for desktop apps not A Website

[-] Ephera@lemmy.ml 7 points 2 days ago

Oh no, I did understand, I just don't think it's worth reinventing the wheel in this regard. HTML is also just a way to instruct a UI renderer what to render. And for the simple stuff that Markdown allows, going through the HTML rendering pipeline is not much overhead.

[-] gridlock@lemmy.blahaj.zone 3 points 2 days ago

Look into tcl/tk

[-] Toes@ani.social 3 points 2 days ago* (last edited 2 days ago)

Sounds like you're describing Flutter?

https://docs.flutter.dev/ui (I know it's web but there isn't a unified standard on drawing the screen outside something like ncurses)

[-] Adniem@thelemmy.club 3 points 2 days ago

the differences from flutter:

1: it is not for the WEB it is for normal desktop apps

2: it isn't for all screens but for making that you don't have to choose qt or gtk

[-] Toes@ani.social 5 points 2 days ago* (last edited 2 days ago)

Flutter is commonly used for cross-platform applications on Linux, Android and iOS. (And probably the other systems too)

You're getting into gnome vs KDE with Qt vs GTK. Some app developers publish versions for both.

Rust has some options that might interest you.

[-] Adniem@thelemmy.club 2 points 2 days ago

but flutter only is, cross toolkit

because it doesn't try to follow the themes set in a GTK or QT desktop

[-] darklamer@feddit.org 2 points 2 days ago
[-] Adniem@thelemmy.club 2 points 2 days ago

but it was made to make apps work greatly on both GTK and QT

not a library implementing one of them

[-] darklamer@feddit.org 2 points 2 days ago

two of them not similar great

this post was submitted on 18 Nov 2026
10 points (77.8% liked)

Ask Lemmy

42471 readers
1443 users here now

A Fediverse community for open-ended, thought provoking questions


Rules: (interactive)


1) Be nice and; have funDoxxing, trolling, sealioning, racism, toxicity and dog-whistling are not welcomed in AskLemmy. Remember what your mother said: if you can't say something nice, don't say anything at all. In addition, the site-wide Lemmy.world terms of service also apply here. Please familiarize yourself with them


2) All posts must end with a '?'This is sort of like Jeopardy. Please phrase all post titles in the form of a proper question ending with ?


3) No spamPlease do not flood the community with nonsense. Actual suspected spammers will be banned on site. No astroturfing.


4) NSFW is okay, within reasonJust remember to tag posts with either a content warning or a [NSFW] tag. Overtly sexual posts are not allowed, please direct them to either !asklemmyafterdark@lemmy.world or !asklemmynsfw@lemmynsfw.com. NSFW comments should be restricted to posts tagged [NSFW].


5) This is not a support community.
It is not a place for 'how do I?', type questions. If you have any questions regarding the site itself or would like to report a community, please direct them to Lemmy.world Support or email info@lemmy.world. For other questions check our partnered communities list, or use the search function.


6) No US Politics.
Please don't post about current US Politics. If you need to do this, try !politicaldiscussion@lemmy.world or !uspolitics@lemmy.world


7) No Hit-and-Run questions.
Please don't delete your post for no apparent reason. If you plan on deleting a question later, say so in the post, or if you feel that you have a good reason to remove it, message a mod beforehand. It's not fair to the ones who took their time to answer, and it's not in the spirit of the community.


8) No Bots.
Posts or comments from bots, LLM's, AIs, Neural Networks, Transformers, or Marvin the Paranoid Android are not welcome in AskLemmy. Real humans only please.


Reminder: The terms of service apply here too.

Partnered Communities:

Tech Support

No Stupid Questions

You Should Know

Reddit

Jokes

Ask Ouija


Logo design credit goes to: tubbadu


founded 3 years ago
MODERATORS