Back: BLOX.BEventTarget-intercepting events Up: BLOX package Forward: BLOX.BExtended-accessing   Top: GNU Smalltalk Library Reference Contents: Table of Contents Index: Class index About: About this document

1.20 BLOX.BExtended

Defined in namespace BLOX
Superclass: BLOX.BWidget
Category: Graphics-Windows
Just like Gui, I serve as a base for complex objects which expose an individual protocol but internally use a Blox widget for creating their user interface. Unlike Gui, however, the instances of my subclasses understand the standard widget protocol. Just override my newPrimitive method to return another widget, and you'll get a class which interacts with the user like that widget (a list box, a text box, or even a label) but exposes a different protocol.

1.20.1 BLOX.BExtended: accessing  (instance)
1.20.2 BLOX.BExtended: customization  (instance)


1.20.1 BLOX.BExtended: accessing

asPrimitiveWidget
Answer the primitive widget that implements the receiver.


1.20.2 BLOX.BExtended: customization

create
After this method is called (the call is made automatically) the receiver will be attached to a `primitive' widget (which can be in turn another extended widget). This method is public not because you can call it, but because it can be useful to override it, not forgetting the call to super (which only calls #newPrimitive and saves the result), to perform some initialization on the primitive widget just created; overriding #create is in fact more generic than overriding #newPrimitive. For an example of this, see the implementation of BButtonLike.

newPrimitive
Create and answer a new widget on which the implementation of the receiver will be based. You should not call this method directly; instead you must override it in BExtended's subclasses.



Back: BLOX.BExtended-accessing Up: BLOX.BExtended Forward: BLOX.BForm   Top: GNU Smalltalk Library Reference Contents: Table of Contents Index: Class index About: About this document


This document was generated on August, 19 2010 using texi2html