Solved

How to ....

Posted on 2006-11-06
4
215 Views
Last Modified: 2010-03-31
Hi,

just enquiring how do i do the following:

1. Change font size of a JList
2. Change font size of a JTable
3. set the Text in JButton such that it can wrap. E.g. instead of
|-------------|
|                |
|My Button  |
|                |
|-------------|

the text is set to:

|-------------|
|                |
|      My      |
|   Button    |
|-------------|

0
Comment
Question by:amai
  • 2
  • 2
4 Comments
 
LVL 86

Accepted Solution

by:
CEHJ earned 50 total points
ID: 17882026
1 & 2 x.setFont(newFont)

3 button.setText("<html>My<br>Button</html>");


0
 

Author Comment

by:amai
ID: 17882138
Hi, thanks for the quick response.. I tried x.setFont(new Font) for my jList, but it didn't work. It's being placed on a pane, and the pane actually setViewportView with this jlist. Does this impact?
0
 

Author Comment

by:amai
ID: 17882437
oops, i know where's the fault... thanks for the response. You are correct :)
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 17882502
:-)
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Java 1603 Error 2 42
pairs challenge 5 44
eclipse compiler vs Installed JREs option 3 39
github account with ecipse 1 16
For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
The viewer will learn how to implement Singleton Design Pattern in Java.
This video teaches viewers about errors in exception handling.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now