beezdul 56 Share Posted March 4, 2016 This is a little snippet that lets you draw text with a drop-shadow (it makes it stand out and look 2x better) ​Here's the method private void drawShadowString(Graphics2D g, String s, int x, int y, Color face, Color shadow) { g.setColor(shadow); g.drawString(s, x+1,y+1); g.setColor(face); g.drawString(s,x,y); } ​ ​And here's how to use it (called from onPaint()) drawShadowString(g, "This is some test text", 100, 200, Color.WHITE, Color.BLACK); ​ Link to comment Share on other sites More sharing options...
7804364 230 Share Posted March 4, 2016 im going to try this in my paint Link to comment Share on other sites More sharing options...
beezdul 56 Author Share Posted March 4, 2016 im going to try this in my paintPlease post results! Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.