From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.3 required=5.0 tests=BAYES_00,FREEMAIL_FROM, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,6f3798af21a89421 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-11-11 20:02:18 PST Path: archiver1.google.com!news2.google.com!news.maxwell.syr.edu!sn-xit-03!sn-xit-04!sn-xit-06!sn-post-01!supernews.com!corp.supernews.com!not-for-mail From: "J Cusick" Newsgroups: comp.lang.ada Subject: Re: GtkAda / Ada Newbie Question Date: Tue, 11 Nov 2003 23:00:18 -0500 Organization: Smoke Incorporated Message-Id: User-Agent: Pan/0.13.4 (She had eyes like strange sins.) References: Reply-To: JoeSmoke at hotmail dot com X-Dont-Bother: Replying Directly To Me MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Complaints-To: abuse@supernews.com Xref: archiver1.google.com comp.lang.ada:2393 Date: 2003-11-11T23:00:18-05:00 List-Id: On Wed, 12 Nov 2003 02:10:14 +0100, Ludovic Brenta wrote: > "J Cusick" writes: > >> I'm new to both Ada and GtkAda and have a question regarding my first >> basic hello world program. >> >> These are the lines in question: >> >> procedure Simple is >> S_Window : Gtk.Window; >> S_Button : Gtk.Button; >> >> and this is the error I get when attempting gnatmake: >> >> simple.adb:8:18: subtype mark required in this context >> every place that S_Window or S_Button shows up. ... >> I have absolutely no clue what this error is telling me. What is a >> "subtype mark" and how do I supply one? ... > Loosely speaking, a subtype mark is the name of a type or subtype. If you > need a formal definition of this or other terms, see the Ada Reference > Manual but this is not for the faint of heart. Here, you supplied the > names of two packages instead of names of types or subtypes. You should > have said: > > S_Window : Gtk.Window.Gtk_Window_Record; S_Button : > Gtk.Button.Gtk_Button_Record; > >> As I have mentioned, I'm just starting to climb the learning curve for >> both Ada and GtkAda, so any help or pointers are greatly >> appreciated.Thanks for any answers regarding this question. ... > Here are a few hints: > > 1) Use glade2 to build your user interface using a point-and-click > interface, then use gate2 to generate Ada code from the .glade file. > Then, study how the generated Ada code works. There are also several > examples that come with GtkAda, one of which is hello world. > > 2) Go to http://libre.act-europe.fr/GtkAda and subscribe to the > mailing lists there. Questions specific to GtkAda are best answered > there. > > 3) Study the *.ads files provided with GtkAda. They include a wealth > of documentation in comments. For example, the file "gtk-window.ads" > contains the specification for the package Gtk.Window. > > HTH Ludovic, Thanks for the excellent pointers. This helps a great deal. The ADA Ref. Man. is indeed not for the feint of heart :-), I tried there first. However, the other pointers are a good start for me. Regards, and thanks again... John C.