comp.lang.ada
 help / color / mirror / Atom feed
From: Preben Randhol <randhol+abuse@pvv.org>
Subject: Re: Gtkada-Prob
Date: Wed, 21 Nov 2001 11:53:05 +0000 (UTC)
Date: 2001-11-21T11:53:05+00:00	[thread overview]
Message-ID: <slrn9vn596.3bu.randhol+abuse@kiuk0156.chembio.ntnu.no> (raw)
In-Reply-To: 20011121.115713.706043324.1437@web.de

On Wed, 21 Nov 2001 11:57:13 +0100, Lars Heppler wrote:
> Hi!
>> Can you show a bit more how you tried this?
> yep,
>    -- this is in the window_pkg made with glade
>    Gtk_New (Window1.Checkbutton2, -"Disable Extra-Paranoia");
>    Set_Active (Window1.Checkbutton2, True);
>    Pack_Start (Window1.Vbox1, Window1.Checkbutton2, False, False, 5);
> 
>    Gtk_New (Window1.Radiobutton1, Vbox1_Group, -"WAV");
>    Vbox1_Group := Group (Window1.Radiobutton1);
>    Set_Active (Window1.Radiobutton1, True);
>    Pack_Start (Window1.Vbox1, Window1.Radiobutton1, False, False, 5);
> 
>    -- this is how i want to check it and want to do...
> 
> if Get_Active (Window1.Checkbutton1) = True then
> rip_args(1) := new String'("-Z");
> elsif
> Get_Active (Window1.Checkbutton2) = True then
> rip_args(2) := new String'("-Y");
> elsif
> Get_Active (Window1.Radiobutton1) = True then
> rip_args(4) := new String'("-w");
> 
> I hope this is enough...

Assuming that you put the above test in the callback of a OK/Apply
button and this callback is in a child package of windows_pkg I cannot
see that it shouldn't work. However if you put it in a different package
I suggest you make a procedure in window_pkg like this:

procedure Get_Arguments is
begin
    if Get_Active (Window1.Checkbutton1) = True then
    rip_args(1) := new String'("-Z");
    elsif
    Get_Active (Window1.Checkbutton2) = True then
    rip_args(2) := new String'("-Y");
    elsif
    Get_Active (Window1.Radiobutton1) = True then
    rip_args(4) := new String'("-w");
end Get_Arguments;

and just call this when you need the arguments.

Preben
-- 
 ()   Join the worldwide campaign to protect fundamental human rights.
'||}
{||'                                           http://www.amnesty.org/



  reply	other threads:[~2001-11-21 11:53 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-11-21  4:35 Gtkada-Prob Lars Heppler
2001-11-21  9:37 ` Gtkada-Prob Adrian Knoth
2001-11-21 18:52   ` Gtkada-Prob Preben Randhol
2001-11-21  9:38 ` Gtkada-Prob Preben Randhol
2001-11-21 10:02   ` Gtkada-Prob Count Zero
2001-11-21 17:06   ` Understanding Booleans Jeffrey Carter
2001-11-21 17:19     ` Jean-Marc Bourguet
2001-11-21 17:29     ` Preben Randhol
2001-11-21 20:05       ` Stephen Leake
2001-11-21 21:33         ` Florian Weimer
2001-11-22  4:23     ` Robert Dewar
2001-11-22 10:39       ` Preben Randhol
2001-11-22 15:51       ` Rod Chapman
2001-11-23  3:51         ` Robert Dewar
2001-11-24 20:09     ` Richard Riehle
2001-11-25  9:08       ` Pascal Obry
2001-11-25 15:06         ` Florian Weimer
2001-11-27  9:46           ` AG
2001-11-25 21:44       ` Jeffrey Carter
2001-11-21 10:19 ` Gtkada-Prob Florian Weimer
2001-11-21 10:36   ` Gtkada-Prob Preben Randhol
2001-11-21 10:39   ` Gtkada-Prob Count Zero
2001-11-21 10:50     ` Gtkada-Prob Preben Randhol
2001-11-21 10:57       ` Gtkada-Prob Lars Heppler
2001-11-21 11:53         ` Preben Randhol [this message]
2001-11-21 12:24           ` Gtkada-Prob Florian Weimer
2001-11-21 12:57             ` Gtkada-Prob Preben Randhol
2001-11-21 17:33     ` Gtkada-Prob Adrian Knoth
2001-11-22 10:32       ` Gtkada-Prob Preben Randhol
2001-11-22 16:36         ` Gtkada-Prob Adrian Knoth
2001-11-22 21:13         ` Gtkada-Prob Jeffrey Carter
2001-11-23 10:17           ` Gtkada-Prob Preben Randhol
2001-11-26  6:47             ` Use of use, was Gtkada-Prob Anders Wirzenius
2001-11-26  9:25               ` Preben Randhol
2001-11-27  6:28                 ` Anders Wirzenius
2001-11-27 14:06                   ` Stephen Leake
2001-11-23 17:26 ` Gtkada-Prob Arnaud Charlet
replies disabled

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