Chapter 32.  Language Extensions

The REALbasic language and application framework allow the programmer to write, with relative ease, a standard, well-behaved application. But there’s a compromise lurking secretly within this fact. Writing an application with REALbasic is easy, because an application written with REALbasic is standard. Or, looking at it the other way round, REALbasic frames a standard type of application and then makes it easy for you to write within that framework. But what if you’d like to step outside that framework?

REALbasic’s capacities, though manifold, are necessarily circumscribed. Normally, this is good thing. After all, if you wanted to be able to program the computer to do absolutely anything at all, through direct calls to its system-level routines (its Toolbox ), you wouldn’t be using REALbasic in the first place. REALbasic’s whole purpose is to shield you from the intricacies of programming at the Toolbox level; of course, REALbasic itself must call the Toolbox, because that’s how applications work, but the access that it gives you to the Toolbox is indirect, and involves only the subset of Toolbox functionality that accords with REALbasic’s own scheme of how an application is organized and what it does.

But REALbasic can’t anticipate everything you might like your application to be able to do. Sometimes, you want to go further than REALbasic’s language and classes and methods can take you. Perhaps you want to call a Toolbox routine ...

Get REALBasic: TDG, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.