kopia lustrzana https://github.com/inkstitch/inkstitch
19 wiersze
593 B
Python
Executable File
19 wiersze
593 B
Python
Executable File
import pyembroidery
|
|
|
|
from .utils import build_environment, write_inx_file
|
|
|
|
|
|
def pyembroidery_input_formats():
|
|
for format in pyembroidery.supported_formats():
|
|
if 'reader' in format and format['category'] == 'embroidery':
|
|
yield format['extension'], format['description']
|
|
|
|
|
|
def generate_input_inx_files():
|
|
env = build_environment()
|
|
template = env.get_template('input.inx')
|
|
|
|
for format, description in pyembroidery_input_formats():
|
|
name = "input_%s" % format.upper()
|
|
write_inx_file(name, template.render(format=format, description=description))
|