CKStaticLayoutComponent Class Reference

Inherits from CKLayoutComponent : CKComponent
Declared in CKStaticLayoutComponent.h

Overview

@uidocs https://fburl.com/CKStaticLayoutComponent:0a97

A component that positions children at fixed positions.

Computes a size that is the union of all childrens' frames.

+ newWithView:size:children:

Passed to the super class initializer.

+ (instancetype)newWithView:(const CKComponentViewConfiguration &)view size:(const CKComponentSize &)size children:(CKContainerWrapper<std::vector<CKStaticLayoutComponentChild> > & &)children

Parameters

view

Passed to the super class initializer.

children

Children to be positioned at fixed positions.

Declared In

CKStaticLayoutComponent.h

+ newWithChildren:

Convenience that does not have a view or size.

+ (instancetype)newWithChildren:(CKContainerWrapper<std::vector<CKStaticLayoutComponentChild> > & &)children

Declared In

CKStaticLayoutComponent.h

+ newWithView:size:

A struct describing the view for this component. Pass {} to specify that no view should be created.

+ (instancetype)newWithView:(const CKComponentViewConfiguration &)view size:(const CKComponentSize &)size

Parameters

view

A struct describing the view for this component. Pass {} to specify that no view should be created.

size

A size constraint that should apply to this component. Pass {} to specify no size constraint.

@example A component that renders a red square: [CKComponent newWithView:{[UIView class], {{@selector(setBackgroundColor:), [UIColor redColor]}}} size:{100, 100}]

Declared In

CKComponent.h