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=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,c32fe290813aec20 X-Google-Attributes: gid103376,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news1.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!wns13feed!worldnet.att.net!164.128.36.58!news.ip-plus.net!newsfeed.ip-plus.net!news.post.ch!not-for-mail From: Martin Krischik Newsgroups: comp.lang.ada Subject: Re: New Ada portable GUI Library? Date: Wed, 16 Jan 2008 09:28:29 +0100 Organization: Swisscom IP+ (post doesn't reflect views of Swisscom) Message-ID: <478dc02d$1@news.post.ch> References: <6d63c543-0a35-4c39-a330-98c63a24f64d@i3g2000hsf.googlegroups.com> <478c6c2d$1@news.post.ch> <478c8d4a$1@news.post.ch> <4744d0de-5739-4e6c-a338-a8f95217be14@l1g2000hsa.googlegroups.com> <478cd9d8$1@news.post.ch> NNTP-Posting-Host: 194.41.146.1 Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Trace: atlas.ip-plus.net 1200472112 24354 194.41.146.1 (16 Jan 2008 08:28:32 GMT) X-Complaints-To: abuse@ip-plus.net NNTP-Posting-Date: Wed, 16 Jan 2008 08:28:32 +0000 (UTC) User-Agent: Thunderbird 2.0.0.9 (Windows/20071031) In-Reply-To: X-Original-NNTP-Posting-Host: w03duo.pnet.ch X-Original-Trace: 16 Jan 2008 09:28:29 +0100, w03duo.pnet.ch Xref: g2news1.google.com comp.lang.ada:19429 Date: 2008-01-16T09:28:29+01:00 List-Id: Ludovic Brenta schrieb: > Martin Krischik wrote: >> Ludovic Brenta schrieb: >> >>> Martin Krischik wrote: >>>> Ludovic Brenta schrieb: >>>> >>>>> Martin Krischik wrote: >>>>>> I have another suggestion: A GUI Library based on OpenStep [1]. >>>>> [...] >>>>>> [1] http://en.wikipedia.org/wiki/OpenStep >>>>> Do you mean a reimplementation of the OpenStep specification in Ada, >>>>> or an Ada binding to GNUstep (http://www.gnustep.org) ? >>>> The later. AFAIK GNUStep uses only a small message based dynamically >>>> typed API with a plain C specification. Qt and Gtk+ use huge OO API's in >>>> C++ or some kind of strange OO-C. > I agree that a static mapping doesn't make sense; that's why I was > thinking about a binding generator. A preprocessor that takes Ada > sources with directives and produces Ada sources wouldn't cut it > because one would have to write the input files manually. The only > sensible input is the Objective-C specification files. I see what you mean - and probably we would need both. I might aim high but I believe full integration should be the aim. And that means that class B written in Objective-Ada inherits from Class A written in Objective-C and Class C written in Objective-C++ inherits from Class B. Now I believe neither GtkAda nor QtAda currently offer that kind of support. >>> The stumbling blocks would be to implement Objective-C's reflection, >>> dynamic typing and garbage collection in Ada. In particular, >>> reflection and dynamic typing are alien to Ada's philosophy. >> You don't - you use the objc runtime which should provide all those via >> plain C functions. > No, because you must export callbacks from Ada so the Objective-C > libraries can call them using dynamic typing and reflection. But Ada > does not have dynamic typing or reflection. That's the problem. Neither had C or C++ - that is all done by the (now build in) preprocessor. >> But it will solve the biggest problem: the endless amount of methods. A >> GUI lib easily got 100 classes. Defining 100 classes is doable - but >> each class will have what about 20 methods. Yes 20 is realistic for GUI >> lib. That would be 2000 pragma imports - endless work. > > That's the job of the generator. Yes - which might use reflection to get the data needed. >>>>> would require both the Ada and Objective-C runtime libraries... >>>> Indeed - but that is not different from Gtk+ and Qt approach. And bare >>>> metal is only feasible for Windows but not for X11. >>> OK, Qt requires a C++ runtime like GNUstep requires an Objective-C >>> runtime. However, GTK+ only requires the C runtime >> That might have been the original idea, but soon they needed Glib2 - to >> make things easier. And then a few more: ATK, Cairo, Fontconfig, >> FreeType, Pango, Poppler, libPNG, libXML, libiconv, librsvg, pkg-config >> as of my last counting: >> >> http://gnuada.sourceforge.net/pmwiki.php/Main/PartnerProjects > > But that is also true of the GNUstep libraries. They call them > "frameworks" and there are several of them. Yep. I guess all of them, Gtk+, Qt, GNUstep and indeed Win32 are Runtimes of there own. Either we use one of those - or we create our very own all in Ada - which brings us very quickly to AdaOS ;-) . Martin -- mailto://krischik@users.sourceforge.net Ada programming at: http://ada.krischik.com