i need a java code which by mouse click make a thin line to a thick line?

thanks