Android Question How to Generate Text Image with BCTextEngine

xulihang

Well-Known Member
Licensed User
Longtime User
Hi,

I only need to get the text image using BCTextEngine and do not need to display it in BBCodeView. Is there a way to do this?
 

xulihang

Well-Known Member
Licensed User
Longtime User
B4X:
    For Each n As B4XView In BBCodeView1.mBase.GetAllViewsRecursive
        'Log(n)
        If n Is ImageView Then
            Log(n)
            Dim iv As ImageView = n
            If iv.GetImage.IsInitialized Then
                ImageView1.SetImage(iv.GetImage)
            End If
        End If
    Next

I try to get the text image from the image view (B4J here). The image contains empty pixels and the text is cut a bit.

test.png
 
Upvote 0
Top