comp.lang.ada
 help / color / mirror / Atom feed
From: newman@Leo.UUCP
Subject: Re: X and Ada?
Date: Sat, 12-Sep-87 18:13:17 EDT	[thread overview]
Date: Sat Sep 12 18:13:17 1987
Message-ID: <1415@bloom-beacon.MIT.EDU> (raw)
In-Reply-To: 64@kvasir.esosun.UUCP

In article <64@kvasir.esosun.UUCP> hyland@kvasir.UUCP (Steve Hyland) writes:
>In article <249@sandia.UUCP> pjatter@sandia.UUCP (Paul Attermeier) writes:
>

>>From what little I've seen of the X toolkits, it appears that
>>X makes 'callbacks' to the application program. If X is in C
>>(which would be acceptable in our 'Ada' system) and the application
>>is in Ada, it looks like we still have the same problem.
>
>Yes, the current X toolkit allows the user to include a call-back
>routine in the argument list. Since this would violate the spirit of
>Ada, we will not allow this. We have a similar problem in the intrinsics,
>with the use of event handlers in widgets. The answer ? Its not completely
>obvious to me at this point.
>

Is there some obvious reason that you can't pass an Ada function
as a parameter to the toolkit's C functions?  How does this violate
the "spirit of Ada"?

*Any* toolkit is going to depend on the use of call-back functions.
If the toolkit is going to dispatch each event to the appropriate
widget, it needs to have a mapping of {Window ID, Function-To-Call}.
This mapping be a linked list, an array, a hash table, or whatever, but
whatever it is, it can only get filled by having someone pass
a callback function as an argument.  If Ada can't handle that, maybe
Ada needs to be extended.

/Ron Newman

  reply	other threads:[~1987-09-12 22:13 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1987-09-07 15:24 X and Ada? pjatter
1987-09-10 22:22 ` Steve Hyland
1987-09-12 22:13   ` newman [this message]
1987-09-15 23:36     ` Bruce Karsh
1987-09-18 14:15     ` lamy
  -- strict thread matches above, loose matches on Subject: below --
1987-09-08 16:25 Steve Hyland
replies disabled

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