java - JLabel with multiple lines and alignment to the right -
i searched through many posts , figured out jlabel
supports html. can
jlabel search = new jlabel("<html>search<br/> by:</html>");
to multiple lines. above code result in
search by:
however, want
search by:
adding spaces before "by:" work when window not resizable(and silly lol). can tell me how modify code make work wanted?
slightly simpler html seen in @madprogrammer's answer:
new jlabel("<html><body style='text-align: right'>search<br>by:");