1
0
mirror of https://github.com/whvcse/EasyCaptcha.git synced 2024-11-23 01:59:19 +08:00

优化验证码效果

This commit is contained in:
synchronized 2018-07-30 13:36:52 +08:00
parent a20a239db8
commit 7defc7e727

View File

@ -32,17 +32,17 @@ public class CaptchaTest {
@Test @Test
public void testHan() throws Exception { public void testHan() throws Exception {
ChineseCaptcha chineseCaptcha = new ChineseCaptcha(); // ChineseCaptcha chineseCaptcha = new ChineseCaptcha();
//chineseCaptcha.setFont(new Font("微软雅黑", Font.PLAIN, 25)); //chineseCaptcha.setFont(new Font("微软雅黑", Font.PLAIN, 25));
System.out.println(chineseCaptcha.text()); // System.out.println(chineseCaptcha.text());
//chineseCaptcha.out(new FileOutputStream(new File("D:/Java/aa.png"))); //chineseCaptcha.out(new FileOutputStream(new File("D:/Java/aa.png")));
} }
@Test @Test
public void testGifHan() throws Exception { public void testGifHan() throws Exception {
ChineseGifCaptcha chineseGifCaptcha = new ChineseGifCaptcha(); // ChineseGifCaptcha chineseGifCaptcha = new ChineseGifCaptcha();
//chineseGifCaptcha.setFont(new Font("微软雅黑", Font.PLAIN, 30)); //chineseGifCaptcha.setFont(new Font("微软雅黑", Font.PLAIN, 30));
System.out.println(chineseGifCaptcha.text()); // System.out.println(chineseGifCaptcha.text());
//chineseGifCaptcha.out(new FileOutputStream(new File("D:/Java/aa.gif"))); //chineseGifCaptcha.out(new FileOutputStream(new File("D:/Java/aa.gif")));
} }