-
Notifications
You must be signed in to change notification settings - Fork 4
/
RapidOCR.b4j
49 lines (46 loc) · 1.27 KB
/
RapidOCR.b4j
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
AppType=JavaFX
Build1=Default,org.xulihang.imagetrans
Group=Default Group
Library1=javaobject
Library10=xmlbuilder
Library11=jsql
Library2=jcore
Library3=jfx
Library4=jokhttputils2
Library5=jshell
Library6=json
Library7=jstringutils
Library8=jxmlsax
Library9=jxui
Module1=Localizator
Module2=RapidOCRPlugin
NumberOfFiles=0
NumberOfLibraries=11
NumberOfModules=2
Version=8.9
@EndOfDesignText@
#Region Project Attributes
#MainFormWidth: 600
#MainFormHeight: 600
#End Region
Sub Process_Globals
Private fx As JFX
Public MainForm As Form
End Sub
Sub AppStart (Form1 As Form, Args() As String)
MainForm = Form1
'MainForm.RootPane.LoadLayout("Layout1") 'Load the layout file.
MainForm.Show
Dim n As RapidOCRPlugin
n.Initialize
wait for (n.GetText(fx.LoadImage(File.DirApp,"capture001.jpg"),"ko")) Complete (text As String)
wait for (n.GetTextWithLocation(fx.LoadImage(File.DirApp,"capture001.jpg"),"ko")) Complete (result As List)
Log(text)
Log(result)
'wait for (n.translate("Hello","en","zh")) complete (result As String)
'Log(result)
End Sub
'Return true to allow the default exceptions handler to handle the uncaught exception.
Sub Application_Error (Error As Exception, StackTrace As String) As Boolean
Return True
End Sub