mirror of
https://github.com/python-escpos/python-escpos
synced 2025-09-13 09:09:58 +00:00
add first draft of printer profile listing
This commit is contained in:

committed by
Patrick Kanzler

parent
09a598883c
commit
8222c1e587
20
doc/capability_templates/capabilities-template.jinja
Normal file
20
doc/capability_templates/capabilities-template.jinja
Normal file
@@ -0,0 +1,20 @@
|
||||
{% for item in data.profiles %}
|
||||
{% set printer = data.profiles[item] %}
|
||||
{% macro draw_with_underline(text, symbol='-') -%}
|
||||
{{ escape_rst(text) }}
|
||||
{{ escape_rst(text) | length * symbol }}
|
||||
{%- endmacro %}
|
||||
{{ draw_with_underline(printer.name) }}
|
||||
{{ escape_rst(printer.notes) }}
|
||||
|
||||
Basic information
|
||||
^^^^^^^^^^^^^^^^^
|
||||
|
||||
====================== ================================================================
|
||||
Name {{ escape_rst(printer.name|default('Unknown')) }}
|
||||
Vendor {{ escape_rst(printer.vendor|default('Unknown')) }}
|
||||
Media width (mm) {{ escape_rst(printer.media.width.mm|default('Unknown')|string) }}
|
||||
Media width (pixels) {{ escape_rst(printer.media.width.pixels|default('Unknown')|string) }}
|
||||
DPI {{ escape_rst(printer.media.dpi|default('Unknown')|string) }}
|
||||
====================== ================================================================
|
||||
{% endfor %}
|
Reference in New Issue
Block a user