B4J Question Zoom Webview

tufanv

Expert
Licensed User
Longtime User
Hello

I searched the b4j forum but couldnt find an answer. is it possible to set zoom level for the webview?

Thanks
 

tufanv

Expert
Licensed User
Longtime User
Reason I am asking it , I used tesserract ocr offline successfuly but when the charachters are small with the webview's screenshot i am having problem. I tried manually zooming the screenshot and worked well. So I need to zoom to webview1 before taking the screenshot for the ocr process.
 
Upvote 0

tufanv

Expert
Licensed User
Longtime User
B4X:
Sub SetZoom(wv As WebView, Factor As Double)
Dim jo As JavaObject = wv
jo.RunMethod("setZoom", Array (Factor))
End Sub

It will be added to jFX library in the next update.

Default value is 1.

Thanks.

by the way is it possible to drag the view inside the webview ? Because when i zoom it it zoom to center of the webview and i cant see the right side of the view.
 
Upvote 0
Top