Thread overview
Gtkd and Gtk4
Jan 02
RSY
Jan 02
RSY
Jan 03
Mike Wey
January 01
GTK-4.0 was released a few weeks ago and new projects will start using it instead of GTK3 and a lot of older project will also be ported to GTK4.

GtkD is one of my favorite toolkits when it comes to GUI programming and I have been developing lots of personal projects with it this year. But it seems like there isn't much activity in GtkD development and there are no plans to support GTK4 which makes me sad.

I hope GtkD catches up, and I thank everyone who spent their time and effort to make it possible.
January 02
On Friday, 1 January 2021 at 08:25:49 UTC, Alireza SN wrote:
> GTK-4.0 was released a few weeks ago and new projects will start using it instead of GTK3 and a lot of older project will also be ported to GTK4.
>
> GtkD is one of my favorite toolkits when it comes to GUI programming and I have been developing lots of personal projects with it this year. But it seems like there isn't much activity in GtkD development and there are no plans to support GTK4 which makes me sad.
>
> I hope GtkD catches up, and I thank everyone who spent their time and effort to make it possible.

D binding seems to be already generated

Have you tried to just rerun the generator with gtk4 source?
January 02
On Saturday, 2 January 2021 at 04:54:15 UTC, RSY wrote:
> D binding seems to be already generated
>
> Have you tried to just rerun the generator with gtk4 source?

There are only GTK3 bindings in 'generated' folder. I tried changing lookup files to generate GTK4 bindings, but it shows a ton of errors. I spent a couple of days debugging it, but I had no success at all.

There is also a pull request, but it's one year old and a lot of stuff has changed since. I tried that too, didn't work.
January 02
On Saturday, 2 January 2021 at 06:36:48 UTC, Alireza SN wrote:
> On Saturday, 2 January 2021 at 04:54:15 UTC, RSY wrote:
>> D binding seems to be already generated
>>
>> Have you tried to just rerun the generator with gtk4 source?
>
> There are only GTK3 bindings in 'generated' folder. I tried changing lookup files to generate GTK4 bindings, but it shows a ton of errors. I spent a couple of days debugging it, but I had no success at all.
>
> There is also a pull request, but it's one year old and a lot of stuff has changed since. I tried that too, didn't work.

so the generator needs to be updated, i'll take a look later today

https://github.com/gtkd-developers/gir-to-d/
January 03
On 02-01-2021 09:19, RSY wrote:
> On Saturday, 2 January 2021 at 06:36:48 UTC, Alireza SN wrote:
>> On Saturday, 2 January 2021 at 04:54:15 UTC, RSY wrote:
>>> D binding seems to be already generated
>>>
>>> Have you tried to just rerun the generator with gtk4 source?
>>
>> There are only GTK3 bindings in 'generated' folder. I tried changing
>> lookup files to generate GTK4 bindings, but it shows a ton of errors.
>> I spent a couple of days debugging it, but I had no success at all.
>>
>> There is also a pull request, but it's one year old and a lot of stuff
>> has changed since. I tried that too, didn't work.
>
> so the generator needs to be updated, i'll take a look later today
>
> https://github.com/gtkd-developers/gir-to-d/

I'm a bit to busy with work, but i definetly want to get gtk4 in gtkD.

Whit the current HEAD of gir-to-d the following runs without error, but i haven't checked the generated code:

```
girtod -i Gtk-4.0.gir
girtod -i Gsk-4.0.gir
girtod -i Gdk-4.0.gir
```

That would get you a generated binding in ./out for the  libraries that make up Gtk4 without it's dependencies so you would need the rest of GtkD to compile it.

-- 
Mike Wey
January 03
On Sunday, 3 January 2021 at 10:48:45 UTC, Mike Wey wrote:
> I'm a bit to busy with work, but i definetly want to get gtk4 in gtkD.
>
> Whit the current HEAD of gir-to-d the following runs without error, but i haven't checked the generated code:
>
> ```
> girtod -i Gtk-4.0.gir
> girtod -i Gsk-4.0.gir
> girtod -i Gdk-4.0.gir
> ```
>
> That would get you a generated binding in ./out for the  libraries that make up Gtk4 without it's dependencies so you would need the rest of GtkD to compile it.

Thanks.

I was able to generate the bindings. After adding them to other GtkD bindings and trying to build a simple app, it showed a lot of errors again. So I spent a couple of hours commenting and changing the generated code to finally make it compile. Then I faced a linker error with LDC. I switched to DMD, and it compiled and linked the code without any errors. But now running the code results in a SIGSEGV error :)

It was a good start. 👍