PyPDFForm 1.4.24__py3-none-any.whl → 1.4.25__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of PyPDFForm might be problematic. Click here for more details.

PyPDFForm/__init__.py CHANGED
@@ -1,6 +1,6 @@
1
1
  # -*- coding: utf-8 -*-
2
2
  """Contains any object users might need."""
3
3
 
4
- __version__ = "1.4.24"
4
+ __version__ = "1.4.25"
5
5
 
6
6
  from .wrapper import FormWrapper, PdfWrapper, PyPDFForm
PyPDFForm/constants.py CHANGED
@@ -40,7 +40,7 @@ Ff = "/Ff"
40
40
  Tx = "/Tx"
41
41
  V = "/V"
42
42
  AP = "/AP"
43
- D = "/D"
43
+ N = "/N"
44
44
  Sig = "/Sig"
45
45
  DA = "/DA"
46
46
  Btn = "/Btn"
PyPDFForm/patterns.py CHANGED
@@ -5,7 +5,7 @@ from pypdf.generic import (DictionaryObject, NameObject, NumberObject,
5
5
  TextStringObject)
6
6
 
7
7
  from .constants import (AP, AS, CA, DA, FT, IMAGE_FIELD_IDENTIFIER, JS, MK,
8
- READ_ONLY, A, Btn, Ch, D, Ff, Off, Opt, Parent, Q, Sig,
8
+ READ_ONLY, A, Btn, Ch, Ff, N, Off, Opt, Parent, Q, Sig,
9
9
  Subtype, T, Tx, V, Widget, Yes)
10
10
  from .middleware.checkbox import Checkbox
11
11
  from .middleware.dropdown import Dropdown
@@ -96,7 +96,7 @@ BUTTON_STYLE_PATTERNS = [
96
96
  def simple_update_checkbox_value(annot: DictionaryObject, check: bool = False) -> None:
97
97
  """Patterns to update values for checkbox annotations."""
98
98
 
99
- for each in annot[AP][D]: # noqa
99
+ for each in annot[AP][N]: # noqa
100
100
  if (check and str(each) != Off) or (not check and str(each) == Off):
101
101
  annot[NameObject(AS)] = NameObject(each)
102
102
  annot[NameObject(V)] = NameObject(each)
@@ -106,7 +106,7 @@ def simple_update_checkbox_value(annot: DictionaryObject, check: bool = False) -
106
106
  def simple_update_radio_value(annot: DictionaryObject) -> None:
107
107
  """Patterns to update values for radio annotations."""
108
108
 
109
- for each in annot[AP][D]: # noqa
109
+ for each in annot[AP][N]: # noqa
110
110
  if str(each) != Off:
111
111
  annot[NameObject(AS)] = NameObject(each)
112
112
  annot[NameObject(Parent)][NameObject(V)] = NameObject(each) # noqa
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: PyPDFForm
3
- Version: 1.4.24
3
+ Version: 1.4.25
4
4
  Summary: The Python library for PDF forms.
5
5
  Home-page: https://github.com/chinapandaman/PyPDFForm
6
6
  Author: Jinge Li
@@ -1,11 +1,11 @@
1
- PyPDFForm/__init__.py,sha256=sVqbupVHGttf9tORArtgTZijeHFLnSoiJYk3OW2P_9E,149
1
+ PyPDFForm/__init__.py,sha256=72JoP1_grqtz5mmX6hf10W9k_vTvWsKJ0_VJBudDEX8,149
2
2
  PyPDFForm/adapter.py,sha256=OgAIwcmukpBqHFBLymd3I7wA7wIdipRqgURZA2Y0Hgo,885
3
- PyPDFForm/constants.py,sha256=m0qGFis52qQDFYyF1qnBJmwULX_y4v3iuWZ9iENNWfc,1671
3
+ PyPDFForm/constants.py,sha256=bGE1n-vRbyISZ34WVZSJYEKZ6mLa5m7ic9nuo_sO37w,1671
4
4
  PyPDFForm/coordinate.py,sha256=V_ZZQ1pXtVPAyfMJCX7fKoEimK7XwX6bU3VQ0nKOhQA,7314
5
5
  PyPDFForm/filler.py,sha256=oj4YkYDZu6kFee9oH8Znw2RyutyFfOJ-oQ-X1WRCKqY,7045
6
6
  PyPDFForm/font.py,sha256=she3ZZXPblr38XPeaeXA30RY1WdKC3l-RZBi9ZltCRQ,4402
7
7
  PyPDFForm/image.py,sha256=0GV8PFgY5oLJFHmhPD1fG-_5SBEO7jVLLtxCc_Uodfo,1143
8
- PyPDFForm/patterns.py,sha256=Yaholy3VPfGfAi3cSzzIhsIzC__6gNVotKEqRPbebqI,4332
8
+ PyPDFForm/patterns.py,sha256=Ylfe6s9UV2X7cRAFQjaGoEa4nVSpEn-MLrH7IROp_aY,4332
9
9
  PyPDFForm/template.py,sha256=X6JgIMkKeDLxkm6nD1_LJidlpet2IlRoVFppBPnzzPk,13505
10
10
  PyPDFForm/utils.py,sha256=gDeRDszZ5Q59RjZjJYnikS2pQ_hc78osQH2Oy1TuLsY,4269
11
11
  PyPDFForm/watermark.py,sha256=clYdRqCuWEE25IL-BUHnSo4HgLkHPSOl7FUJLhbAfGg,4755
@@ -23,8 +23,8 @@ PyPDFForm/widgets/base.py,sha256=Stq-oQt-cfwQ6nilQ4NqpO5udFSKDNb1mAwryrWggZA,207
23
23
  PyPDFForm/widgets/checkbox.py,sha256=MGB6NGI-XMBz4j2erykgYOCd1pswvthuQ6UFowQOd4o,503
24
24
  PyPDFForm/widgets/dropdown.py,sha256=2_R5xcLUWAL0G4raVgWWtE7TJdiWJITay-Gtl8YI2QI,705
25
25
  PyPDFForm/widgets/text.py,sha256=x8EglZLYoI9osN9wORLRYoR7lebrpj-wx38QiRH7H1A,629
26
- PyPDFForm-1.4.24.dist-info/LICENSE,sha256=43awmYkI6opyTpg19me731iO1WfXZwViqb67oWtCsFY,1065
27
- PyPDFForm-1.4.24.dist-info/METADATA,sha256=cC7aiDVQ0CrRmMLxYqymm-LGiuFJIpwlUjJoYbqjYeg,5367
28
- PyPDFForm-1.4.24.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
29
- PyPDFForm-1.4.24.dist-info/top_level.txt,sha256=GQQKuWqPUjT9YZqwK95NlAQzxjwoQrsxQ8ureM8lWOY,10
30
- PyPDFForm-1.4.24.dist-info/RECORD,,
26
+ PyPDFForm-1.4.25.dist-info/LICENSE,sha256=43awmYkI6opyTpg19me731iO1WfXZwViqb67oWtCsFY,1065
27
+ PyPDFForm-1.4.25.dist-info/METADATA,sha256=LARd-0ihydfM73xIkjYWNNpVTn8YegcjlyFAMKWGjLo,5367
28
+ PyPDFForm-1.4.25.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
29
+ PyPDFForm-1.4.25.dist-info/top_level.txt,sha256=GQQKuWqPUjT9YZqwK95NlAQzxjwoQrsxQ8ureM8lWOY,10
30
+ PyPDFForm-1.4.25.dist-info/RECORD,,