From: Daniel A. S. <st...@ic...> - 2001-09-14 17:04:21
|
At 9:50 -0700 on 14/9/01, Jim Ingham wrote: >The only problem here how to identify the presence of the MacOS >specific code in Tcl, like the resource manager code. I think it >would also be really nice to add some interface to the >NSFindStuffInBundles API's, since this would be very useful to >reimplement the D&D Tclets stuff for MacOS X. We can't use Darwin >for this, since any of this that depends on Foundation or Carbon >won't be present on Darwin, only on true MacOS X... yes that's a good point. would you want put this sort of osx specific feature into the MacTcl package below or into a separate package (MacOSXTcl ?) >I think that for the Mac code in Tcl I am going to solve this >differently, moving all that code (like the resource manager stuff) >out to a separate package. This is because I don't want to have to >link the base Tcl library to Carbon. I would be happier with doing >a package require for this. So you can test for whether you have >these capabilities by doing: > >if {[catch {package require MacTcl}]} { >... >} > >or something like that. I haven't done this yet, but it should not >be too hard to separate out most of this stuff. excellent, I was very much thinking along the same lines. I've carbonized some of the mac only commands already for AlphaX, notably 'beep' is in VoSe, in osxMacTcl.c I assume the goal would be that [package require MacTcl] would succeed on platform==macintosh as well? (but possibly with less features?) Cheers, Daniel -- ** Daniel A. Steffen ** "And now to something completely ** Department of Mathematics ** different" Monty Python ** Macquarie University ** <mailto:st...@ma...> ** NSW 2109 Australia ** <http://www.maths.mq.edu.au/~steffen/> |