java - displaying several lines of two-word strings on a JTextComponent with Justified alignment -


as picture below shows, i'm trying display text 1 in table of contents. "items" start @ same position. doesn't matter me wether "values" end @ same position, start @ same position, or centered in right-column of textpane. also, don't strictly need use jtextpane - if it's possible achieve effect using jtextpane, i'd most. i'd different font types items , values.

i add item/value pairs calling textpane.append("\nitem1: value1"); can change too. have tried experimenting justified alignment, can't make work in desirable way.

enter image description here


Comments

Popular posts from this blog

Change the color of an oval at click in Java AWT -

c# - Unity IoC Lifetime per HttpRequest for UserStore -

I am trying to solve the error message 'incompatible ranks 0 and 1 in assignment' in a fortran 95 program. -