Sign up

Pages: 1 2

Examples in GtkD/demos

It seems that some of the demos use the new Gtk-3 structure of creating an Application and then running that. However some of the demos still seem to be in the old structure of setting up objects and then running the mainloop explicitly. Or am I missing something?

Re: Examples in GtkD/demos

On 05/26/2017 02:37 PM, Russel Winder wrote:

It seems that some of the demos use the new Gtk-3 structure of creating an Application and then running that. However some of the demos still seem to be in the old structure of setting up objects and then running the mainloop explicitly. Or am I missing something?

No, the others still need to be converted.

Re: Examples in GtkD/demos

Maybe I can do a few. Do you want to give me a (short) list of "low hanging fruit" and I'll see what I can do.

Re: Examples in GtkD/demos

On 05/29/2017 11:51 PM, Russel Winder wrote:

Maybe I can do a few. Do you want to give me a (short) list of "low hanging fruit" and I'll see what I can do.

The demos for pango, sourceView and possibly builder would be the 'low
hanging fruit', demos that don't implement a MainWindow could use the
same approach as the cairo demos.

The other remaining demos, probably need more work, for the gsstreamer
demos i still need to lookup if the call to Gstreamer.Init is still
necessary so those might be simple. But the 2 OpenGL demos also need to
be rewritten to use gtk.GLArea instead of the gtlglext binding, as the
gtkglext3 library is unmaintained and not available in most of the
repositories of the different distributions.

Re: Examples in GtkD/demos

I am now in a position to start looking at these things, so expect pull requests.

Is there a "rule book" for style, tests, etc.?

Re: Examples in GtkD/demos

On Tue, 30 May 2017 20:26:58 +0200, Mike Wey wrote:

On 05/29/2017 11:51 PM, Russel Winder wrote:

Maybe I can do a few. Do you want to give me a (short) list of "low hanging fruit" and I'll see what I can do.

The demos for pango, sourceView and possibly builder would be the 'low
hanging fruit', demos that don't implement a MainWindow could use the
same approach as the cairo demos.

The other remaining demos, probably need more work, for the gsstreamer
demos i still need to lookup if the call to Gstreamer.Init is still
necessary so those might be simple. But the 2 OpenGL demos also need to
be rewritten to use gtk.GLArea instead of the gtlglext binding, as the
gtkglext3 library is unmaintained and not available in most of the
repositories of the different distributions.

GStreamer does have to be initialised.

The GL bits in GStreamer have been stable for a while now so I guess that means the Gtk stuff is stable as well. I will take a look at those.

Re: Examples in GtkD/demos

For the GStreamer applications did you want to show building a pipeline explicitly? These days most people just use a PlayBin and let it decode the incoming data stream and build the appropriate pipeline.

Re: Examples in GtkD/demos

On 06/16/2017 08:52 AM, Russel Winder wrote:

I am now in a position to start looking at these things, so expect pull requests.

Is there a "rule book" for style, tests, etc.?

I would say, the same style as the other demos. But i just checked, and
currently there doesn't seem to de a consistent style that is used
across the different demos.

Re: Examples in GtkD/demos

On 06/16/2017 10:10 AM, Russel Winder wrote:

For the GStreamer applications did you want to show building a pipeline explicitly? These days most people just use a PlayBin and let it decode the incoming data stream and build the appropriate pipeline.

The hello world demo was based on this c demo:
https://cgit.freedesktop.org/gstreamer/gstreamer/tree/tests/examples/helloworld/helloworld.c

It was updated to just using the PlayBin about six years ago, so we
should do the same.

Re: Examples in GtkD/demos

On Fri, 16 Jun 2017 23:47:18 +0200, Mike Wey wrote:
[…]

I would say, the same style as the other demos. But i just checked, and
currently there doesn't seem to de a consistent style that is used
across the different demos.

I will continue to submit updates in my preferred style if that's OK?

I guess the alternative is to do the Go thing and have a "one true style" enforced via a tool, or the Python thing and have a style checker for the "one true style"? I'm easy with it as long as there is tool support. It's just that I can't really cope with the Phobos style, I prefer the more compact style.

Pages: 1 2