comp.lang.ada
 help / color / mirror / Atom feed
From: Thomas <fantome.forums.tDeContes@free.fr.invalid>
Subject: Re: Gtk.Image.Gtk_Image
Date: Fri, 25 Mar 2022 02:53:00 +0100	[thread overview]
Message-ID: <fantome.forums.tDeContes-0CD0D9.02525725032022@news.free.fr> (raw)
In-Reply-To: t1ikj3$18ak$1@gioia.aioe.org

In article <t1ikj3$18ak$1@gioia.aioe.org>,
 "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> wrote:

> On 2022-03-24 19:40, Thomas wrote:
> > In article <t1i3qd$oud$1@gioia.aioe.org>,
> >   "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> wrote:
> 
> >> If you need a button with image just put an image into it. Gtk_Button is
> >> already a container.
> > 
> > yes, it works fine :-)
> > 
> >> Put Gtk_Box into it. Put Gtk_Image into Gtk_Box.
> >> That's would be all.
> > 
> > do you mean that (for a simple image, not a button) i should use a
> > Gtk_Box as intermediate container, instead of a Gtk_Event_Box?
> 
> Gtk_Box is handy as you can place many children into it, e.g. labels, 
> use alignment etc.

at this step i need not to be able to place many children into it or to 
manage layout,
because i want to implement this interface, which contains only 2 
procedures - Create and Set_Image:

http://svn.savannah.gnu.org/viewvc/rapid/branches/gtkada-2.24/src/tki/mcc
_tki/mcc-tki-widget-picture.ads?view=markup&pathrev=257
( https://urlpetite.fr/olk )


RAPID is mostly "glue code", but sometimes there is sth to handle :

for example:
RAPID interface tells that an image (called a picture label) can have 
its content replaced,
and Gtk makes it easy for a Gtk_Button containing an image, but not for 
a Gtk_Image.



> normal 
> containers already do the work. If you use Gtk_Event_Box you would have 
> to handle necessary signals to make everything work as it would with 
> Gtk_Box out of the box (no pun intended).

i would like to be able to use a Gtk_Bin, to access to Gtk.Bin.Get_Child 
which seems to be a lot easier to use than Gtk.Container.Children.


but first, since you seem to be sure that Gtk_Box is the right container 
to use, i tested it ...
it doesn't work !

i don't understand why.

it is put in a Gtk_Fixed, can that have an influence?

the case where it works are :
- Gtk_Pixmap instead of Gtk_Image
- Gtk_Image without container
- Gtk_Button set with a Gtk_Image


any idea of what i should try, now?

-- 
RAPID maintainer
http://savannah.nongnu.org/projects/rapid/

  reply	other threads:[~2022-03-25  1:53 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-24 12:55 Gtk.Image.Gtk_Image Thomas
2022-03-24 13:35 ` Gtk.Image.Gtk_Image Dmitry A. Kazakov
2022-03-24 15:14   ` Gtk.Image.Gtk_Image Thomas
2022-03-24 15:47     ` Gtk.Image.Gtk_Image Dmitry A. Kazakov
2022-03-24 18:40       ` Gtk.Image.Gtk_Image Thomas
2022-03-24 20:33         ` Gtk.Image.Gtk_Image Dmitry A. Kazakov
2022-03-25  1:53           ` Thomas [this message]
2022-03-25  7:29             ` Gtk.Image.Gtk_Image Dmitry A. Kazakov
2022-03-25 19:37               ` Gtk.Image.Gtk_Image Thomas
2022-03-25 20:34                 ` Gtk.Image.Gtk_Image Dmitry A. Kazakov
2022-03-26  1:38                   ` Gtk.Image.Gtk_Image Thomas
2022-03-26  8:59                     ` Gtk.Image.Gtk_Image Dmitry A. Kazakov
2022-03-26 17:32                       ` Gtk.Image.Gtk_Image Thomas
2022-03-27  9:33                         ` Gtk.Image.Gtk_Image Dmitry A. Kazakov
2022-03-27 16:41                           ` Gtk.Image.Gtk_Image Thomas
2022-03-27 17:34                             ` Gtk.Image.Gtk_Image Dmitry A. Kazakov
2022-03-30  2:58                               ` Gtk.Image.Gtk_Image Thomas
2022-03-30 12:46                                 ` Gtk.Image.Gtk_Image Dmitry A. Kazakov
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox