Groups | Search | Server Info | Login | Register


Groups > comp.lang.ada > #49497

Re: GtkAda callback and event

From "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Newsgroups comp.lang.ada
Subject Re: GtkAda callback and event
Date 2021-09-12 15:57 +0200
Organization Aioe.org NNTP Server
Message-ID <shl112$1ma1$1@gioia.aioe.org> (permalink)
References (18 earlier) <shggst$nv$1@gioia.aioe.org> <613cca39$0$29491$426a34cc@news.free.fr> <e23f19ef-5f39-4260-b625-f49176cb8f70n@googlegroups.com> <shkf4i$1lj1$1@gioia.aioe.org> <613dfa06$0$5001$426a74cc@news.free.fr>

Show all headers | View raw


On 2021-09-12 15:00, DrPi wrote:
> Le 12/09/2021 à 10:52, Dmitry A. Kazakov a écrit :
>> On 2021-09-12 09:08, AdaMagica wrote:
>>> DrPi schrieb am Samstag, 11. September 2021 um 17:24:45 UTC+2:
>>>> Even if I just started using GtkAda, I find it very powerful.
>>>> The big problem is documentation. Of course, there are the reference
>>>> manual and the (small) user guide but I miss a document explaining the
>>>> use of all these functionalities.
>>>
>>> A good introduction into GtkAda is direly needed. Trial and error 
>>> cost me
>>> enormously much time.
>>> The GtkAda UG and RM are a bad joke.
>>
>> I think you rather mean GTK introduction because GtkAda follows GTK to 
>> the letter. 
> I don't fully agree with you.
> I already found Gtk examples I've not been able to use directly with 
> GtkAda because of Ada implementation. Or at least, it was not the best 
> way to do things.

Well, you are supposed to use GValues in GTK. GtkAda just makes life 
much easier for you by adding a typed layer to connect and handle the 
events. How it works is well explained in the documentation. E.g.

    https://docs.adacore.com/live/wave/gtkada/html/gtkada_ug/signals.html

The problem is that you started with that, skipped reading for later 
because it was too much reading. If you had started the GTK's way first, 
namely with GValues, then after pulling much hairs, read the stuff more 
carefully, then you would rather say, "Aha, that is a much better way to 
do this. Thanks."

> Mostly due to the GtkAda OO implementation. Events and 
> customized widgets are good examples.

Right, because when you begin with GtkAda with no prior knowledge of 
GTK, you are at a complete loss.

Luckily, you do not yet understand how deep is the abyss! (:-))

> I also loose big amount of time searching for how to do things.

Because GTK is a mess. Nobody ever knows how to do this or that in GTK. 
I keep the GTK sources at hand to consult to just to understand what is 
going on. [ It was a lot easier a decade ago, when Google was a search 
engine and GTK topics were not spammed into oblivion by Python and C# 
garbage sites. ]

> I think the the tutorial I've found is a good one to start.
> It starts from scratch which is not as easy as one could think it is : a 
> basic application never ends. The main window closes but the exe never 
> stops. Quite disturbing.

Then the tutorial is broken. If you look at GtkAda samples and tests 
they all contain the basic GTK frame with On_Delete_Event and On_Destroy.

-- 
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de

Back to comp.lang.ada | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

GtkAda callback and event DrPi <314@drpi.fr> - 2021-09-04 23:39 +0200
  Re: GtkAda callback and event "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> - 2021-09-05 00:29 +0200
    Re: GtkAda callback and event DrPi <314@drpi.fr> - 2021-09-05 15:50 +0200
      Re: GtkAda callback and event "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> - 2021-09-05 16:48 +0200
        Re: GtkAda callback and event DrPi <314@drpi.fr> - 2021-09-05 16:58 +0200
          Re: GtkAda callback and event DrPi <314@drpi.fr> - 2021-09-05 17:04 +0200
            Re: GtkAda callback and event "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> - 2021-09-05 17:12 +0200
              Re: GtkAda callback and event DrPi <314@drpi.fr> - 2021-09-05 17:20 +0200
                Re: GtkAda callback and event "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> - 2021-09-05 17:53 +0200
                Re: GtkAda callback and event DrPi <314@drpi.fr> - 2021-09-05 22:49 +0200
                Re: GtkAda callback and event Emmanuel Briot <briot.emmanuel@gmail.com> - 2021-09-08 23:56 -0700
                Re: GtkAda callback and event DrPi <314@drpi.fr> - 2021-09-09 09:57 +0200
                Re: GtkAda callback and event Jere <jhb.chat@gmail.com> - 2021-09-09 11:41 -0700
                Re: GtkAda callback and event "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> - 2021-09-09 21:58 +0200
                Re: GtkAda callback and event Jere <jhb.chat@gmail.com> - 2021-09-09 14:01 -0700
                Re: GtkAda callback and event "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> - 2021-09-10 08:38 +0200
                Re: GtkAda callback and event Emmanuel Briot <briot.emmanuel@gmail.com> - 2021-09-09 23:56 -0700
                Re: GtkAda callback and event DrPi <314@drpi.fr> - 2021-09-10 22:42 +0200
                Re: GtkAda callback and event "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> - 2021-09-10 22:58 +0200
                Re: GtkAda callback and event Emmanuel Briot <briot.emmanuel@gmail.com> - 2021-09-11 00:38 -0700
                Re: GtkAda callback and event DrPi <314@drpi.fr> - 2021-09-11 17:24 +0200
                Re: GtkAda callback and event "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> - 2021-09-11 17:56 +0200
                Re: GtkAda callback and event AdaMagica <christ-usch.grein@t-online.de> - 2021-09-12 00:08 -0700
                Re: GtkAda callback and event "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> - 2021-09-12 10:52 +0200
                Re: GtkAda callback and event DrPi <314@drpi.fr> - 2021-09-12 15:00 +0200
                Re: GtkAda callback and event "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> - 2021-09-12 15:57 +0200
                Re: GtkAda callback and event "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> - 2021-09-10 22:46 +0200
                Re: GtkAda callback and event Emmanuel Briot <briot.emmanuel@gmail.com> - 2021-09-11 00:36 -0700

csiph-web