Table of contents

DSLayoutAxis

The DSLayoutAxis class provides configuration for a single axis in layout analysis.

Definition

Assembly: DynamsoftCaptureVisionBundle.xcframework

  • Objective-C
  • Swift
  1. NS_SWIFT_NAME(LayoutAxis)
    @interface DSLayoutAxis : NSObject
    
  2. class LayoutAxis : NSObject
    

Attributes

Attribute Type Description
elementCount NSInteger Expected number of elements along this axis. Use -1 for auto-detection.
isStaggered BOOL Whether the layout uses an offset/staggered pattern.
angle NSInteger Target angle [0, 180]. Use -1 for auto-detection.
isEqualSpacing BOOL Force equal gaps between elements. When false, spacing is ignored.
spacing NSInteger Spacing between elements along this axis. Use -1 for auto-detection.
spacingUnit DSMeasureUnit Interpretation mode for the spacing value.

elementCount

Expected number of elements along this axis. Use -1 for auto-detection.

  • Objective-C
  • Swift
  1. @property (nonatomic, assign) NSInteger elementCount;
    
  2. var elementCount: Int { get set }
    

isStaggered

Whether the layout uses an offset/staggered pattern.

  • Objective-C
  • Swift
  1. @property (nonatomic, assign) BOOL isStaggered;
    
  2. var isStaggered: Bool { get set }
    

angle

Target angle [0, 180]. Use -1 for auto-detection.

  • Objective-C
  • Swift
  1. @property (nonatomic, assign) NSInteger angle;
    
  2. var angle: Int { get set }
    

isEqualSpacing

Force equal gaps between elements. When false, spacing is ignored.

  • Objective-C
  • Swift
  1. @property (nonatomic, assign) BOOL isEqualSpacing;
    
  2. var isEqualSpacing: Bool { get set }
    

spacing

Spacing between elements along this axis. Use -1 for auto-detection.

  • Objective-C
  • Swift
  1. @property (nonatomic, assign) NSInteger spacing;
    
  2. var spacing: Int { get set }
    

spacingUnit

Interpretation mode for the spacing value.

  • Objective-C
  • Swift
  1. @property (nonatomic, assign) DSMeasureUnit spacingUnit;
    
  2. var spacingUnit: MeasureUnit { get set }
    

This page is compatible for: