UAInAppMessageTextInfoBuilder

Objective-C


@interface UAInAppMessageTextInfoBuilder : NSObject

Swift

class InAppMessageTextInfoBuilder : NSObject

Builder class for UAInAppMessageTextInfo.

  • Text content.

    Required.

    Declaration

    Objective-C

    @property (nonatomic, copy, nullable) NSString *text;

    Swift

    var text: String? { get set }
  • Text color.

    Optional. Defaults to black.

    Declaration

    Objective-C

    @property (nonatomic, strong) UIColor *_Nonnull color;

    Swift

    var color: UIColor { get set }
  • Text size.

    Optional. Defaults to 14sp.

    Declaration

    Objective-C

    @property (nonatomic) CGFloat sizePoints;

    Swift

    var sizePoints: CGFloat { get set }
  • Text alignment.

    Optional. Defaults to UAInAppMessageTextInfoAlignmentNone.

    Declaration

    Objective-C

    @property (nonatomic) UAInAppMessageTextInfoAlignmentType alignment;

    Swift

    var alignment: InAppMessageTextInfoAlignmentType { get set }
  • Text styles.

    Optional. Defaults to no style (UAInAppMessageTextInfoStyleNormal).

    Declaration

    Objective-C

    @property (nonatomic) UAInAppMessageTextInfoStyleType style;

    Swift

    var style: InAppMessageTextInfoStyleType { get set }
  • Font families - first valid font name in collection is used.

    Optional

    Declaration

    Objective-C

    @property (nonatomic, copy, nullable) NSArray<NSString *> *fontFamilies;

    Swift

    var fontFamilies: [String]? { get set }
  • Checks if the builder is valid and will produce a text info instance.

    Declaration

    Objective-C

    - (BOOL)isValid;

    Swift

    func isValid() -> Bool

    Return Value

    YES if the builder is valid (requires text), otherwise NO.