Files
Nano-Banana-AI-Image-Editor/build/README.md

54 lines
1.4 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 应用图标
此目录包含用于打包桌面应用程序的图标文件。
## Windows 平台
Windows 平台需要 ICO 格式的图标文件,命名为 `icon.ico`
### 如何创建 ICO 文件
有几种方法可以创建 ICO 文件:
#### 方法1使用 Python 脚本(推荐)
项目根目录下提供了一个 Python 脚本 `convert_svg_to_ico.py`,可以直接将 SVG 转换为 ICO 格式:
1. 确保已安装 Python 3 和必要的依赖包:
```
pip install Pillow cairosvg
```
2. 在 Windows 上,您可能还需要安装 GTK3 运行时环境:
- 下载并安装 GTK3: https://github.com/tschoonj/GTK-for-Windows-Runtime-Environment-Installer
3. 运行转换脚本:
```
npm run electron:icon
```
或直接运行:
```
python convert_svg_to_ico.py
```
脚本会自动将 `public/favicon.svg` 转换为 `build/icon.ico`,并包含多个尺寸。
#### 方法2使用在线转换工具
- [ConvertICO](https://convertico.com/)
- [Online-Convert](https://image.online-convert.com/convert-to-ico)
- [CloudConvert](https://cloudconvert.com/png-to-ico)
#### 方法3使用图像编辑软件
使用支持 ICO 格式的图像编辑软件(如 GIMP、Photoshop 插件等)手动创建。
### 图标尺寸要求
Windows 应用程序图标应包含多个尺寸:
- 16x16
- 32x32
- 48x48
- 256x256
确保在生成 ICO 文件时包含这些尺寸。