From 83a4db64d2318a842523a44c585aeed2ed6e3fbb Mon Sep 17 00:00:00 2001 From: Ali Date: Wed, 7 Sep 2016 12:52:39 -0400 Subject: [PATCH] Minor language fixes --- README.md | 80 +++++++++++++++++++++++++++---------------------------- 1 file changed, 40 insertions(+), 40 deletions(-) diff --git a/README.md b/README.md index 2c33500..165521b 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ # QR-Code -* **update**: add an **exe** version - [myqr.exe in qrcode_win](https://github.com/sylnsfar/qrcode_win) +* **update**: added an **exe** version - [myqr.exe in qrcode_win](https://github.com/sylnsfar/qrcode_win) ​ @@ -10,15 +10,15 @@ **Python 二维码生成器** -​ +​ -It can generate common qr-code, artistic qr-code (black&white or colorized), animated qr-code (black&white or colorized). +It can generate common qr-code, artistic qr-code (black & white or colorized), animated qr-code (black & white or colorized). -可以生成普通二维码带图片的艺术二维码(黑白与彩色)动态二维码(黑白与彩色)。 +可以生成普通二维码带图片的艺术二维码(黑白与彩色)动态二维码(黑白与彩色)。 -​ +​ -​ +​ ### Contents 目录 @@ -35,11 +35,11 @@ It can generate common qr-code, artistic qr-code (black&white or colo -​ +​ -​ +​ -​ +​ ## Example 示例 @@ -53,7 +53,7 @@ It can generate common qr-code, artistic qr-code (black&white or colo ![](https://github.com/sylnsfar/qrcode/blob/master/example/zootopia_qrcode.gif)![](https://github.com/sylnsfar/qrcode/blob/master/example/daftpunktocat-guy_qrcode0.gif) -​ +​ ## Usage 用法 @@ -62,9 +62,9 @@ It can generate common qr-code, artistic qr-code (black&white or colo ![](https://github.com/sylnsfar/qrcode/blob/master/example/0.png) ``` -python myqr.py [-h] - [-v {1,2,3,...,40}] - [-l {L,M,Q,H}] +python myqr.py [-h] + [-v {1,2,3,...,40}] + [-l {L,M,Q,H}] Words ``` @@ -95,24 +95,24 @@ python myqr.py https://github.com -v 10 -l Q 默认边长是取决于你输入的信息的长度,而默认纠错等级是最高级的H。 -* **Customize size**: If you want to control the length and the error-correction-level, use the `-v` and `-l` arguments. The `-v` representing the length is from 1 to 40 that 1 means minimum and 40 means maximum. The `-l` representing the level is one of L, M, Q and H that L means lowest and H means highest. +* **Customize size**: If you want to control the length and the error-correction-level, use the `-v` and `-l` arguments. The `-v` representing the length is from a minimum of 1 to a maximum of 40. The `-l` representing the error correction level is one of L, M, Q and H, where L is the lowest level and H is the highest. **自定义尺寸**:如果想要控制边长和纠错水平就使用 `-v` 和 `-l` 参数。使用 `-v` 来控制边长,范围是1至40,数字越大边长越大;使用 `-l` 来控制纠错水平,范围是L、M、Q、H,从左到右依次升高。 - ​ + ​ ### Artistic QR-Code 艺术QR二维码 ![](https://github.com/sylnsfar/qrcode/blob/master/example/1.png)![](https://github.com/sylnsfar/qrcode/blob/master/example/2.png) - python myqr.py [-h] - [-v {1,2,3,...,40}] - [-l {L,M,Q,H}] - [-p picture_file] - [-c] - [-con contrast] - [-bri birghtness] + python myqr.py [-h] + [-v {1,2,3,...,40}] + [-l {L,M,Q,H}] + [-p picture_file] + [-c] + [-con contrast] + [-bri brightness] Words * arguments `-h`, `-v` and `-l` is as mentioned above. @@ -127,11 +127,11 @@ python myqr.py https://github.com -v 10 -l Q python myqr.py https://github.com -p github.jpg ``` -* The `-p` is to combine the QR-Code with the following picture which is at the same directory as the program. The resulting picture is **black and white** by default. +* The `-p` is to combine the QR-Code with the following picture which is in the same directory as the program. The resulting picture is **black and white** by default. 参数`-p` 用来将QR二维码图像与一张同目录下的图片相结合,产生一张**黑白**图片。 - ​ + ​ @@ -154,29 +154,29 @@ python myqr.py https://github.com -p github.jpg -c python myqr.py https://github.com -p github.jpg [-c] -con 1.5 -bri 1.6 ``` -* The `-con` changes the contrast of the picture that 1.0 means original image, lower values mean less contrast and higher mean more. Default: 1.0. +* The `-con` flag changes the contrast of the picture - a low number corresponds to low contrast and a high number to high contrast. Default: 1.0. 参数`-con` 用以调节图片的对比度,1.0 表示原始图片,更小的值表示更低对比度,更大反之。默认为1.0。 -* The `-bri` changes the brightness and the value is just like `-con`'s. +* The `-bri` flag changes the brightness and the parameter values work the same as those for `-con`. Default: 1.0. 参数 `-bri` 用来调节图片的亮度,其余用法和取值与 `-con` 相同。 -​ +​ -### Animated GIF QR-Code 动态二维码 +### Animated GIF QR-Code 动态二维码 ![](https://github.com/sylnsfar/qrcode/blob/master/example/daftpunktocat-guy_qrcode.gif)![](https://github.com/sylnsfar/qrcode/blob/master/example/daftpunktocat-guy_qrcode0.gif) -The only one difference from Artistic QR-Code mentioned above is that you should input a image file in the format `.gif`. The you can get your black-and-white or colorful qr-code. +The only difference from Artistic QR-Code mentioned above is that you should input an image file in the `.gif` format. The you can get your black-and-white or colorful qr-code. 动态二维码与上述的带图片的二维码的生成方法没什么区别,你只要采用 `.gif` 格式的图片即可黑白或者彩色的动态二维码。 -​ +​ ## Tips 提示 @@ -188,16 +188,16 @@ The only one difference from Artistic QR-Code mentioned above is that you should 建议在图片尺寸大的时候使用 `-v` 的值也应该适当变大。 -* If part of picture is transparent, the qr code will be like: ![](https://github.com/sylnsfar/qrcode/blob/master/example/aa.png) +* If part of the picture is transparent, the qr code will look like: ![](https://github.com/sylnsfar/qrcode/blob/master/example/aa.png) - You can change it into white, then be like: ![](https://github.com/sylnsfar/qrcode/blob/master/example/a0.png) + You can change the transparent layer to white, and then it will look like: ![](https://github.com/sylnsfar/qrcode/blob/master/example/a0.png) 如果图片有透明无色部分,最终效果是:![](https://github.com/sylnsfar/qrcode/blob/master/example/aa.png) 你可以将透明部分修改成白色,最终效果会变成![](https://github.com/sylnsfar/qrcode/blob/master/example/a0.png) -​ +​ ## Supported Characters 可用字符 @@ -218,24 +218,24 @@ The only one difference from Artistic QR-Code mentioned above is that you should ``` -​ +​ -## Dependences 依赖库 +## Dependencies 依赖库 -* pillow -* numpy +* [pillow](https://python-pillow.org/) +* [numpy](http://www.numpy.org/) * [imageio](https://pypi.python.org/pypi/imageio) -You can use command `pip install -r requirements.txt` for all dependences. +You can use `pip install -r requirements.txt` to ensure you have all dependencies. 可以使用命令`pip install -r requirements.txt` 来安装所有依赖的库。 -​ +​ ## Environment 运行环境 * Linux, Python 3 -* Windows, Python 3 \ No newline at end of file +* Windows, Python 3