| Author |
Displaying Text Vertically
|
Raghuveer Rawat
Ranch Hand
Joined: Apr 03, 2003
Posts: 102
|
|
hi all In my application, In each JFrame I have set BorderLayout Manager. In the West of these BorderLayout I want to set Company Name in Vertical Text. Can anyone tell me how I can do it.
|
Raghuveer Rawat<br />SCJP2
|
 |
Dorothy Finkel-Laverty
Ranch Hand
Joined: Nov 24, 2001
Posts: 51
|
|
Just did this today with my class - you can set it up as a label, with the html tags : like this - - JLabel right = new JLabel("<html>This <br>is<br> the<br> East<br> panel</html>"); Or any other HTML tags that make sense.
|
 |
Frank Slade
Greenhorn
Joined: Jul 07, 2003
Posts: 1
|
|
You can use the method as suggested in the reply posted earlier or you can create a UI class that can be used to draw text vertically. subclass BasicLabelUI and write your text vertically over there. Each Letter at a time. Like this. C I S C O public void paint(Graphics g, JComponent c) { //do your text writing here } This solution works for Swing JLabel etc, you can over ride the paint method for your AWT component.
|
 |
 |
|
|
subject: Displaying Text Vertically
|
|
|