Convert PSD file to HTML
Project description
PSD to HTML converter based on [psd-tools](https://github.com/psd-tools/psd-tools)
Install
Use pip to install:
pip install psd2html
Usage
### As a command-line tool
The package comes with a command-line tool:
psd2html input.psd output.html
When the output path is a directory, or omitted, the tool infers the output name from the input:
psd2html file.psd # => file.html psd2html file.psd dir/ # => dir/file.html psd2html file.psd dir/file1 # => dir/file1.html psd2html file.psd dir/file1.html # => dir/file1.html
### As a python library
Example:
from psd2html import PSD2HTML
- with open(‘file.psd’, ‘rb’) as f:
converter = PSD2HTML(f) html = converter.html html_string = converter.html_str
Notes:
Not all PSD layers are being converted to HTML elements. Current release only converts the [TypeLayer](https://psd-tools.readthedocs.io/en/latest/reference/psd_tools.api.layers.html#typelayer) to HTML, all the others types i.e Artboard, PixelLayer, ShapeLayer and SmartObjectLayer are rendered as png images.
Future releases will include support for other types of layers.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file psd2html-0.3.0.tar.gz.
File metadata
- Download URL: psd2html-0.3.0.tar.gz
- Upload date:
- Size: 4.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.33.0 CPython/3.7.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c649fcfc08305fa826ab0949a74077214c35b84892a2a7b65557b1b74cf28c1a
|
|
| MD5 |
84da06b3d8eafe4b11c62dc5369cf1c0
|
|
| BLAKE2b-256 |
b4639d77649bd21d5093cf75dbdd4753c8d3a9b1fde4f91eda095f2eab0a0081
|
File details
Details for the file psd2html-0.3.0-py3-none-any.whl.
File metadata
- Download URL: psd2html-0.3.0-py3-none-any.whl
- Upload date:
- Size: 13.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.33.0 CPython/3.7.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e808b09cdb43f26616727224777a909ffcdc2732652b32fa289db1a7bc0411b5
|
|
| MD5 |
64a08d1a781b78efdd351647b7b776e9
|
|
| BLAKE2b-256 |
28a34741fac262a23153958b3d1257bce74eaeee8f71eb989265d3e3a1ec27f6
|