MLKitTextRecognition Framework Reference

TextBlock

class TextBlock : NSObject

A text block recognized in an image that consists of an array of text lines.

  • String representation of the text block that was recognized.

    Declaration

    Swift

    var text: String { get }
  • An array of text lines that make up the block.

    Declaration

    Swift

    var lines: [MLKTextLine] { get }
  • The rectangle that contains the text block relative to the image in the default coordinate space.

    Declaration

    Swift

    var frame: CGRect { get }
  • An array of recognized Latin-based languages in the text block. If no languages were recognized, the array is empty.

    Declaration

    Swift

    var recognizedLanguages: [MLKTextRecognizedLanguage] { get }
  • The four corner points of the text block in clockwise order starting with the top left point relative to the image in the default coordinate space. The NSValue objects are CGPoints.

    Declaration

    Swift

    var cornerPoints: [NSValue] { get }
  • Unavailable.