46 release(this->control);
69 $(self,
bind, inlets, dictionary);
120 self->
control = retain(control);
135 release(self->
label);
137 self->
label = retain(label);
190#pragma mark - Class lifecycle
197 ((ObjectInterface *) clazz->interface)->dealloc =
dealloc;
200 ((ViewInterface *) clazz->interface)->init =
init;
203 ((InputInterface *) clazz->interface)->setControl =
setControl;
204 ((InputInterface *) clazz->interface)->setLabel =
setLabel;
205 ((InputInterface *) clazz->interface)->setOrientation =
setOrientation;
217 clazz = _initialize(&(
const ClassDef) {
220 .instanceSize =
sizeof(
Input),
221 .interfaceOffset = offsetof(
Input, interface),
222 .interfaceSize =
sizeof(InputInterface),
@ StackViewAxisHorizontal
#define MakeInlets(...)
Creates a null-termianted array of Inlets.
#define MakeInlet(name, type, dest, data)
Creates an Inlet with the specified parameters.
@ ViewAlignmentMiddleCenter
@ ViewAlignmentMiddleRight
@ ViewAlignmentMiddleLeft
Box * initWithFrame(Box *self, const SDL_Rect *frame)
Initializes this Box with the given frame.
CollectionView * initWithFrame(CollectionView *self, const SDL_Rect *frame)
CollectionView * init(CollectionView *self, const SDL_Rect *frame)
Initializes this CollectionView with the specified frame and style.
Controls are Views which capture events and dispatch Actions.
Inlets enable inbound data binding of View attributes through JSON.
Labels provide a configurable container for Text.
Label * initWithText(Label *self, const char *text, Font *font)
Initializes this Label with the given text and Font.
StackViews are containers that manage the arrangement of their subviews.
StackViewAxis axis
The axis.
Class * _StackView(void)
The StackView archetype.
Views are the fundamental building blocks of ObjectivelyMVC user interfaces.
_Bool bind(View *self, const Inlet *inlets, const Dictionary *dictionary)
Performs data binding for the Inlets described in dictionary.
ViewAlignment alignment
The alignment.
void addSubview(View *self, View *subview)
Adds a subview to this view, to be drawn above its siblings.
void addClassName(View *self, const char *className)
Adds the given class name to this View.
void removeFromSuperview(View *self)
Removes this View from its superview.
void awakeWithDictionary(View *self, const Dictionary *dictionary)
Wakes this View with the specified Dictionary.
void removeSubview(View *self, View *subview)
Removes the given subview from this View.