rendering hints

R

Roedy Green

Was 1.3 the first version of Java that let you do this?

protected void paintComponent(Graphics g) {
Graphics2D g2d = (Graphics2D)g;
g2d.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING,
RenderingHints.VALUE_TEXT_ANTIALIAS_ON);
g2d.setRenderingHint(RenderingHints.KEY_RENDERING,
RenderingHints.VALUE_RENDER_QUALITY);
super.paintComponent(g2);


Is there an easier way now in 1.5?


--
Bush crime family lost/embezzled $3 trillion from Pentagon.
Complicit Bush-friendly media keeps mum. Rumsfeld confesses on video.
http://www.infowars.com/articles/us/mckinney_grills_rumsfeld.htm

Canadian Mind Products, Roedy Green.
See http://mindprod.com/iraq.html photos of Bush's war crimes
 
T

Thomas Weidenfeller

Roedy said:
Was 1.3 the first version of Java that let you do this?

No, should these keys/values should have been already in 1.2.
Is there an easier way now in 1.5?

See Q9.2 of a current version of the comp.lang.java.gui FAQ. There is a
property now. However, antialiasing everything might give much worse
results than not antialiasing anything.


/Thomas
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

java.jdk and java.jre system properties 5
extending enum 18
Cloneable 7
sleep or beep 10
ConcurrentModificationException, please help 3
AccessControlException 11
ColorChooser for AWT 3
missing system properties 1

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,060
Latest member
BuyKetozenseACV

Latest Threads

Top