Created
February 8, 2016 09:22
-
-
Save codenameone/3bfd03a497bc09700128 to your computer and use it in GitHub Desktop.
Label icon/text alignment in Codename One
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Label left = new Label("Left", icon); | |
left.setTextPosition(Component.LEFT); | |
Label right = new Label("Right", icon); | |
right.setTextPosition(Component.RIGHT); | |
Label bottom = new Label("Bottom", icon); | |
bottom.setTextPosition(Component.BOTTOM); | |
Label top = new Label("Top", icon); | |
top.setTextPosition(Component.TOP); | |
hi.add(left).add(right).add(bottom).add(top); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Sample usage code for Label
From the Codename One project