B4J Code Snippet Multiline Labels Text Alignment

Discussion in 'B4J Code Snippets' started by Erel, Jul 26, 2018.

  1. Erel

    Erel Administrator Staff Member Licensed User

    The standard Alignment property does not work properly with multiline labels. It aligns the content based on the first line.

    You can use this code instead:
    Code:
    Dim jo As JavaObject = Label1
    jo.RunMethod(
    "setTextAlignment"Array("CENTER"))
     
    embedded, fredo, Mashiane and 3 others like this.
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice