Package io.scanbot.sdk.generictext.ui
Class WordboxPreviewView
-
- All Implemented Interfaces:
-
android.graphics.drawable.Drawable.Callback
,android.view.KeyEvent.Callback
,android.view.accessibility.AccessibilityEventSource
,io.scanbot.sdk.ui.BasePolygonView
public final class WordboxPreviewView extends View implements BasePolygonView
Allows to highlight the words which were recognized by io.scanbot.sdk.generictext.GenericTextRecognizer
-
-
Field Summary
Fields Modifier and Type Field Description private Integer
frameWidth
private Integer
frameHeight
private Integer
frameOrientation
-
Constructor Summary
Constructors Constructor Description WordboxPreviewView(Context context)
WordboxPreviewView(Context context, AttributeSet attrs)
-
Method Summary
Modifier and Type Method Description final Integer
getFrameWidth()
final Unit
setFrameWidth(Integer frameWidth)
final Integer
getFrameHeight()
final Unit
setFrameHeight(Integer frameHeight)
final Integer
getFrameOrientation()
final Unit
setFrameOrientation(Integer frameOrientation)
final Unit
setColor(Integer strokeColor)
Changes stroke color of the polygon. final Unit
updateCharacters(List<GenericTextWordBox> list)
Sets the list of words to highlight -
-
Constructor Detail
-
WordboxPreviewView
WordboxPreviewView(Context context)
-
WordboxPreviewView
WordboxPreviewView(Context context, AttributeSet attrs)
-
-
Method Detail
-
getFrameWidth
final Integer getFrameWidth()
-
setFrameWidth
final Unit setFrameWidth(Integer frameWidth)
-
getFrameHeight
final Integer getFrameHeight()
-
setFrameHeight
final Unit setFrameHeight(Integer frameHeight)
-
getFrameOrientation
final Integer getFrameOrientation()
-
setFrameOrientation
final Unit setFrameOrientation(Integer frameOrientation)
-
setColor
final Unit setColor(Integer strokeColor)
Changes stroke color of the polygon.
- Parameters:
strokeColor
- color (not resource!) to draw lines with.
-
updateCharacters
final Unit updateCharacters(List<GenericTextWordBox> list)
Sets the list of words to highlight
- Parameters:
list
- of words
-
-
-
-