Sender | Message | Time |
---|---|---|
29 Mar 2024 | ||
xionbox joined the room. | 02:06:05 | |
xionbox | Hi there. I'm brand new to GUI development (I'm mostly a high fidelity simulation software engineer and quite proficient in Rust). Would Relm be able to be a good visualization tool for a 3D globe? I'm looking to build something to visualize spacecraft trajectories | 02:07:34 |
chfkch | In reply to @xionbox:matrix.orgI think you might want to look at something like bevy engine for that. | 07:13:14 |
1 Apr 2024 | ||
chfkch | Do `SimpleAsyncComponents` notĀ have a `self` available in the `view!` macro? I struggle to move data out of this piece of code here https://codeberg.org/Chfkch/bitritter/src/commit/5e239e7e10a8c3d9f0daa9a75db4622d97d1c2c4/src/main.rs#L691 Also i think i got a workaround for things that can implement `Copy` by moving it into the `connect_clicked`, but i have Strings there mostly. What is the preferred approach here? Lifetime &str? | 14:08:13 |
chfkch | Seems there is a markdown problem when posting on my phone, sorry. | 14:18:52 |
Aaron Erhardt | Components generally don't have | 17:46:23 |
chfkch | In reply to @aaron:matrix.aaron-erhardt.deAh, makes sense. I had only worked with factories until somedays and those have it š | 18:17:57 |
chfkch | I think my problem about moving/cloning the string is more of a rust issue than relm. | 18:19:27 |
5 Apr 2024 | ||
chfkch | @Aaron Erhardt I have seen that libadwaita has introduced adw::Dialog recently. IsĀ that planned to be adapted in relm soon? Or should i use gtk::Dialog for now? | 16:19:16 |
chfkch | Btw is there an chance to provide help to the project by donations or work? | 16:31:09 |
Andy joined the room. | 16:52:23 | |
Andy | hello. this is day 1 of relm, gtk-rs and gtk. I'm going to work on a cross-platform desktop app. should I use libadwaita at all? should I care one way or another? | 17:19:44 |
Andy | In reply to @xionbox:matrix.orgI think these guys https://www.fslabs.ca/ use bevy + egui, for what it's worth | 17:22:07 |
Aaron Erhardt | In reply to @airstrike:private.coffeeGTK works on all major Desktop OS platforms, but shipping binaries for Windows is not simple. I think Libadwaita supports the same platforms, but might make the build process even more complicated on non-Linux platforms. | 22:11:37 |
Aaron Erhardt | In reply to @chfkch:matrix.orgRelm4 doesn't force usage of Libadwaita, so gtk::Dialog will always be supported. If you want, you can help by improving support for adw::Dialog . | 22:14:30 |
Andy | In reply to @aaron:matrix.aaron-erhardt.dethanks. I'm struggling to find the right "stack" for building a cross-platform Rust GUI application that is as fast as humanly possible. I was going down the Tauri route first, but I don't find it very ergonomic overall and a bit of a Frankenstein monster... it didn't feel as snappy as I wanted it to either. think I might try iced next, then | 22:20:52 |
Aaron Erhardt | Pure Rust GUI frameworks are great for speed indeed. GTK still is much more complete though, so I recommend checking whether Iced or similar libraries cover your use-case. That can safe you a lot of time (in my own experience). | 22:26:00 |
6 Apr 2024 | ||
chfkch | In reply to @aaron:matrix.aaron-erhardt.deUsually stuff is implemented in relm when it is in gtk-rs right? so i don't have to read C code, becauseĀ i am a noob at that. Have to check if that is true for adwaita aswell. Guess i will have a closer look at relm sources then haha. | 19:38:11 |
7 Apr 2024 | ||
Aaron Erhardt | Yes, everything in Relm4 uses gtk-rs and except for the component and factory runtimes the code is usually quite simple. | 06:00:40 |
chfkch | Ok so do i understand correctly that relm does not provide things like gtk::Label etc. itself but only reexports them? So in case of adw::Dialog i have to first get it upstream here? https://gitlab.gnome.org/World/Rust/libadwaita-rs | 07:01:38 |
Aaron Erhardt | Yes, the entire gtk4 crate is re-exported and even the view macro mostly uses "vanilla" gtk-rs methods with a tiny bit of extension traits. The C bindings for GTK and Libadwaita on the other hand are mostly auto-generated with some manual code on top, so you should not have to add adw::Dialog yourself. I think the type already exists in libadwaita-rs on git. The only change needed for Relm4 is to pull the dependencies from git then to unlock the new features. | 17:41:52 |
8 Apr 2024 | ||
chfkch | Ok i have no idea how that works. Meanwhile i have implemented a gtk::Dialog in my app, but i found itĀ irritating that the examples have a button controller which is a dialog controller basically. i have just implemented the dialog controller in my app model and it looks easier. Am i missing something here? I can push the code later this day for reference. | 09:54:57 |
chfkch | Otherwise it is working as expected (even a warning about the transient stuff is gone), when omitting the extra button component. | 09:55:47 |
Aaron Erhardt | Sure. Honestly, I don't quite understand what you need exactly, so maybe the code would help me understand your use-case. | 11:03:10 |
QuARC joined the room. | 22:15:57 | |
QuARC | (my homeserver may be extremely slow, apologies in advance) so I want to use TypedColumnView and I took a look at examples/typed_column_view.rs in the repo I see that Label1Column, Label2Column and ButtonColumn are all separate struct but let's say I want to reuse Label1Column for multiple columns, is that possible Like can I have another Label1Column that shows a different value without writing a whole new struct| | 22:24:13 |
QuARC | I wanna do something like this
where I'll have an unknown number of groups and... some data structure to make it work- | 22:27:06 |
QuARC | * I wanna do something like this
where I'll have an unknown number of groups and... some data structure to make it work | 22:27:10 |
QuARC | * I wanna do something like this
where I'll have an unknown number of things and groups and... some data structure to make it work | 22:27:36 |
QuARC | I guess I could do it manually with factories or something, but that seems annoying | 22:28:18 |