Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add HERMA 10003/4345 labels #26

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ pip install paperless-asn-qr-codes
## Usage

```
usage: paperless-asn-qr-codes [-h] [--format {averyL4731,avery5160,avery5161,avery5163,avery5167,avery5371}] [--digits DIGITS] [--border] [--row-wise] [--num-labels NUM_LABELS] [--pages PAGES]
usage: paperless-asn-qr-codes [-h] [--format {averyL4731,avery5160,avery5161,avery5163,avery5167,avery5371,herma10003}]
[--digits DIGITS] [--border] [--row-wise] [--num-labels NUM_LABELS] [--pages PAGES]
[--start-position START_POSITION]
start_asn output_file

Expand All @@ -25,7 +26,7 @@ positional arguments:

options:
-h, --help show this help message and exit
--format {averyL4731,avery5160,avery5161,avery5163,avery5167,avery5371}, -f {averyL4731,avery5160,avery5161,avery5163,avery5167,avery5371}
--format {averyL4731,avery5160,avery5161,avery5163,avery5167,avery5371,herma10003}, -f {averyL4731,avery5160,avery5161,avery5163,avery5167,avery5371,herma10003}
--digits DIGITS, -d DIGITS
Number of digits in the ASN (default: 7, produces 'ASN0000001')
--border, -b Display borders around labels, useful for debugging the printer alignment
Expand Down Expand Up @@ -64,6 +65,7 @@ The default is Avery L4731.

Currently tested and known working are:
- Avery L4731 (DIN A4 Labels)
- HERMA 10003 (formerly HERMA 4345)

## Tips & Tricks

Expand Down
9 changes: 9 additions & 0 deletions paperless_asn_qr_codes/avery_labels.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,15 @@ class LabelInfo:
margin=(54, 36),
pagesize=LETTER,
),
# HERMA No. 10003 labels (former article No. 4345)
"herma10003": LabelInfo(
labels_horizontal=5,
labels_vertical=16,
label_size=(35.56 * mm, 16.93 * mm),
gutter_size=(2.54 * mm, 0),
margin=(11.02 * mm, 13.06 * mm),
pagesize=A4,
),
}

RETURN_ADDRESS = 5167
Expand Down