File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Swing / AWT / SWT and the fly likes Alignment problem in JTextPane Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Alignment problem in JTextPane" Watch "Alignment problem in JTextPane" New topic
Author

Alignment problem in JTextPane

Nagurva Reddy
Greenhorn

Joined: Jul 10, 2001
Posts: 7
Hai all...
StyleContext.NamedStyle styleMap = styleContext.new NamedStyle();
StyleConstants.setAlignment(styleMap,StyleConstants.ALIGN_JUSTIFIED);
textPane.setParagraphAttributes(styleMap, true);

Here i am setting Justification for my text pane,but it is not working ,it is working like ALIGN_CENTER.

Thanks
Nagu
------------------
Nagurva


Nagurva
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Alignment problem in JTextPane