g.setColor(darkGray); g.drawString(s, textX + thickness, textY + thickness); g.drawString(s, textX, textY + thickness); g.drawString(s, textX - thickness, textY + thickness); g.drawString(s, textX + thickness, textY); g.drawString(s, textX, textY); g.drawString(s, textX - thickness, textY); g.drawString(s, textX + thickness, textY - thickness); g.drawString(s, textX, textY - thickness); g.drawString(s, textX - thickness, textY - thickness);
if (thickness > 10) { thickness = 10; }  if (thickness > 0) { g.setColor(getDarkGray(thickness));  for (int i = -thickness; i <= thickness; i++) { for (int j = -thickness; j <= thickness; j++) { if (i != 0 || j != 0) { g.drawString(s, textX + i, textY + j); } } } }
	public static void paintOutline(Graphics g, String s, int textX, int textY, int thickness) {		g.setColor(darkGray);		g.drawString(s, textX + thickness, textY + thickness);		g.drawString(s, textX, textY + thickness);		g.drawString(s, textX - thickness, textY + thickness);		g.drawString(s, textX + thickness, textY);		g.drawString(s, textX, textY);		g.drawString(s, textX - thickness, textY);		g.drawString(s, textX + thickness, textY - thickness);		g.drawString(s, textX, textY - thickness);		g.drawString(s, textX - thickness, textY - thickness);		g.setColor(Color.white);		g.drawString(s, textX, textY);	}