# ximage **Repository Path**: a358003542/ximage ## Basic Information - **Project Name**: ximage - **Description**: a simple image process tool. - **Primary Language**: Python - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2021-08-27 - **Last Updated**: 2021-08-27 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # ximage a simple image process tools. 一个简单的命令行处理图片工具。 ``` pip install ximage ``` ## USEAGE the `INPUTIMGS` means you can input as many image files as you like. ### resize image ``` Usage: ximage resize [OPTIONS] INPUTIMGS... resize your image, width height you must give one default is zero. Options: -V, --verbose print verbose info --width INTEGER the output image width --height INTEGER the output image height --outputdir TEXT the image output dir --outputname TEXT the image output name --help Show this message and exit. ``` ### convert image format you may need install the inkscape software for svg convertation. ``` Usage: ximage convert [OPTIONS] INPUTIMGS... support image format: - pillow : png <-> jpg <-> gif <-> eps <-> tiff <-> bmp <-> ppm - inkscape: svg -> pdf | png | ps | eps - pdftocairo: pdf -> png | jpeg | ps | eps | svg Options: -V, --verbose print verbose info --dpi INTEGER the output image dpi --format TEXT the output image format --outputdir TEXT the image output dir --outputname TEXT the image output name --pdftocairo-fix-encoding TEXT In Windows,the pdftocairo fix encoding --overwrite / --no-overwrite overwrite the output image file, default is overwrite --transparent pdf convert to png|tiff can turn transparent on --help Show this message and exit. ``` ## changelog ### 0.3.0 - add tests - ximage convert add `--transparent` option used by pdftocairo.exe - code refine. ### 0.2.4 doc refine. ### 0.2.4 fix a bug: convert_image output_dir not return correctly. ### 0.2.3 1. fix pdftocairo.exe in windows can not handle the chinese problem. ~~中文用户经过测试需要加上如下encoding参数:`--pdftocairo-fix-encoding=gb18030`~~ 【现在似乎又没这个问题了,似乎win10更新了能够正确处理中文文件名了】 ### 0.2.0 1. change use pdf2ppm to pdftocairo, it can convert pdf to png|jpeg|svg etc. 2. the pip installation will make sure you have installed the pillow module. 3. the pip installation in windows will check is there have pdftocairo.exe, if can not found , program will copy the pdftocairo.exe to the python scripts folder.