File tree Expand file tree Collapse file tree 1 file changed +79
-3
lines changed
packages/mlkit-text-recognition Expand file tree Collapse file tree 1 file changed +79
-3
lines changed Original file line number Diff line number Diff line change 11# @nativescript/mlkit-text-recognition
22
3- ``` javascript
3+ A plugin used with [ @nativescript/mlkit-core ] ( ../mlkit-core ) to enable Text Recognition in your app and provide [ TextResult] ( #textresult ) type for the text recognition event data.
4+
5+ ## Contents
6+ * [ Installation] ( #installation )
7+ * [ Use @nativescript/mlkit-text-recognition ] ( #use-nativescriptmlkit-text-recognition )
8+ * [ API] ( #api )
9+ * [ TextResult] ( #textresult )
10+ * [ License] ( #license )
11+
12+ ## Installation
13+
14+ ``` cli
415npm install @nativescript/mlkit-text-recognition
516```
617
7- ## Usage
18+ ## Use @nativescript/mlkit-text-recognition
19+
20+ For an example, read [ Use @nativescript/mlkit-core ] ( ../mlkit-core#use-nativescriptmlkit-core ) and [ Text Recognition] ( ../mlkit-core#text-recognition ) .
21+
22+ ## API
23+
24+ ### TextResult
25+
26+ The Text Recognition event data type.
27+
28+ ``` ts
29+ interface TextResult {
30+ text? : string
31+ bounds: Bounds
32+ lines: TextLine []
33+ points: Point []
34+ }
35+ ```
36+ ---
37+ #### Point
38+
39+ ``` ts
40+ interface Point {
41+ x: number ;
42+ y: number ;
43+ }
44+ ```
45+ ---
46+ #### Bounds
47+ ``` ts
48+ interface Bounds {
49+ origin: Origin ;
50+ size: Size ;
51+ }
52+ ```
53+ #### Origin
54+ ``` ts
55+ interface Origin {
56+ x: number ;
57+ y: number ;
58+ }
59+ ```
860
9- See [ @nativescript/mlkit-core ] ( /packages/mlkit-core/README.md ) Usage
61+ #### Size
62+ ``` ts
63+ interface Size {
64+ width: number ;
65+ height: number ;
66+ }
67+ ```
68+ ---
69+ #### TextLine
70+ ``` ts
71+ interface TextLine {
72+ text? : string
73+ bounds: Bounds
74+ elements: TextElement []
75+ points? : Point []
76+ }
77+ ```
78+ #### TextElement
79+ ``` ts
80+ interface TextElement {
81+ text? : string
82+ bounds: Bounds
83+ }
84+ ```
85+ ---
1086## License
1187
1288Apache License Version 2.0
You can’t perform that action at this time.
0 commit comments