libreflow.extensions.sk.export-psd-layers 1.1.4__tar.gz → 1.1.6__tar.gz
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.
- {libreflow_extensions_sk_export_psd_layers-1.1.4 → libreflow_extensions_sk_export_psd_layers-1.1.6}/CHANGELOG.md +12 -0
- {libreflow_extensions_sk_export_psd_layers-1.1.4/src/libreflow.extensions.sk.export_psd_layers.egg-info → libreflow_extensions_sk_export_psd_layers-1.1.6}/PKG-INFO +13 -1
- libreflow_extensions_sk_export_psd_layers-1.1.6/src/libreflow/extensions/__init__.py +1 -0
- libreflow_extensions_sk_export_psd_layers-1.1.6/src/libreflow/extensions/sk/__init__.py +1 -0
- {libreflow_extensions_sk_export_psd_layers-1.1.4 → libreflow_extensions_sk_export_psd_layers-1.1.6}/src/libreflow/extensions/sk/export_psd_layers/__init__.py +34 -7
- {libreflow_extensions_sk_export_psd_layers-1.1.4 → libreflow_extensions_sk_export_psd_layers-1.1.6}/src/libreflow/extensions/sk/export_psd_layers/_version.py +3 -3
- {libreflow_extensions_sk_export_psd_layers-1.1.4 → libreflow_extensions_sk_export_psd_layers-1.1.6/src/libreflow.extensions.sk.export_psd_layers.egg-info}/PKG-INFO +13 -1
- libreflow_extensions_sk_export_psd_layers-1.1.4/src/libreflow/extensions/__init__.py +0 -0
- libreflow_extensions_sk_export_psd_layers-1.1.4/src/libreflow/extensions/sk/__init__.py +0 -0
- {libreflow_extensions_sk_export_psd_layers-1.1.4 → libreflow_extensions_sk_export_psd_layers-1.1.6}/MANIFEST.in +0 -0
- {libreflow_extensions_sk_export_psd_layers-1.1.4 → libreflow_extensions_sk_export_psd_layers-1.1.6}/README.md +0 -0
- {libreflow_extensions_sk_export_psd_layers-1.1.4 → libreflow_extensions_sk_export_psd_layers-1.1.6}/setup.cfg +0 -0
- {libreflow_extensions_sk_export_psd_layers-1.1.4 → libreflow_extensions_sk_export_psd_layers-1.1.6}/setup.py +0 -0
- {libreflow_extensions_sk_export_psd_layers-1.1.4 → libreflow_extensions_sk_export_psd_layers-1.1.6}/src/libreflow/__init__.py +0 -0
- {libreflow_extensions_sk_export_psd_layers-1.1.4 → libreflow_extensions_sk_export_psd_layers-1.1.6}/src/libreflow.extensions.sk.export_psd_layers.egg-info/SOURCES.txt +0 -0
- {libreflow_extensions_sk_export_psd_layers-1.1.4 → libreflow_extensions_sk_export_psd_layers-1.1.6}/src/libreflow.extensions.sk.export_psd_layers.egg-info/dependency_links.txt +0 -0
- {libreflow_extensions_sk_export_psd_layers-1.1.4 → libreflow_extensions_sk_export_psd_layers-1.1.6}/src/libreflow.extensions.sk.export_psd_layers.egg-info/requires.txt +0 -0
- {libreflow_extensions_sk_export_psd_layers-1.1.4 → libreflow_extensions_sk_export_psd_layers-1.1.6}/src/libreflow.extensions.sk.export_psd_layers.egg-info/top_level.txt +0 -0
- {libreflow_extensions_sk_export_psd_layers-1.1.4 → libreflow_extensions_sk_export_psd_layers-1.1.6}/versioneer.py +0 -0
|
@@ -19,6 +19,18 @@ Types of changes
|
|
|
19
19
|
|
|
20
20
|
## [Unreleased]
|
|
21
21
|
|
|
22
|
+
## [1.1.6] - 2025-08-07
|
|
23
|
+
|
|
24
|
+
### Fixed
|
|
25
|
+
|
|
26
|
+
* Export resized to psd canvas - makes the action less prone to crash from a lack of RAM
|
|
27
|
+
|
|
28
|
+
## [1.1.5] - 2025-07-03
|
|
29
|
+
|
|
30
|
+
### Fixed
|
|
31
|
+
|
|
32
|
+
* Top level layers are forced to be shown when exported and are not added to "hidden_layers" in JSON layers file anymore
|
|
33
|
+
|
|
22
34
|
## [1.1.4] - 2025-05-09
|
|
23
35
|
|
|
24
36
|
### Fixed
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: libreflow.extensions.sk.export_psd_layers
|
|
3
|
-
Version: 1.1.
|
|
3
|
+
Version: 1.1.6
|
|
4
4
|
Home-page: https://gitlab.com/lfs.coop/libreflow/libreflow_launcher
|
|
5
5
|
Author: Thomas Thiebaut
|
|
6
6
|
Author-email: autor@les-fees-speciales.coop
|
|
@@ -50,6 +50,18 @@ Types of changes
|
|
|
50
50
|
|
|
51
51
|
## [Unreleased]
|
|
52
52
|
|
|
53
|
+
## [1.1.6] - 2025-08-07
|
|
54
|
+
|
|
55
|
+
### Fixed
|
|
56
|
+
|
|
57
|
+
* Export resized to psd canvas - makes the action less prone to crash from a lack of RAM
|
|
58
|
+
|
|
59
|
+
## [1.1.5] - 2025-07-03
|
|
60
|
+
|
|
61
|
+
### Fixed
|
|
62
|
+
|
|
63
|
+
* Top level layers are forced to be shown when exported and are not added to "hidden_layers" in JSON layers file anymore
|
|
64
|
+
|
|
53
65
|
## [1.1.4] - 2025-05-09
|
|
54
66
|
|
|
55
67
|
### Fixed
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__path__ = __import__('pkgutil').extend_path(__path__, __name__)
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__path__ = __import__('pkgutil').extend_path(__path__, __name__)
|
|
@@ -182,9 +182,31 @@ class ExportPSDLayers(flow.Action):
|
|
|
182
182
|
|
|
183
183
|
folder_name = os.path.basename(render_revision.get_path())
|
|
184
184
|
|
|
185
|
+
# frame_bbox = (0, 0, 0, 0)
|
|
186
|
+
|
|
187
|
+
# frame_layer = psb.find("white")
|
|
188
|
+
|
|
189
|
+
# if frame_layer is None:
|
|
190
|
+
# raise Exception("FRAME LAYER NOT FOUND")
|
|
191
|
+
# else:
|
|
192
|
+
# frame_bbox = frame_layer.bbox
|
|
193
|
+
|
|
194
|
+
# if frame_bbox == (0, 0, 0, 0):
|
|
195
|
+
# raise Exception("Frame Layer has no bounding box")
|
|
196
|
+
|
|
197
|
+
# # Substract by 10pixels (width and height) in order to remove border margin
|
|
198
|
+
# # frame_bbox = (
|
|
199
|
+
# # frame_bbox[0] + 5,
|
|
200
|
+
# # frame_bbox[1] + 5,
|
|
201
|
+
# # frame_bbox[2] - 5,
|
|
202
|
+
# # frame_bbox[3] - 5,
|
|
203
|
+
# # )
|
|
204
|
+
|
|
205
|
+
# print(frame_bbox)
|
|
206
|
+
|
|
185
207
|
for layer in reversed(psb):
|
|
186
208
|
# Remove invalid characters
|
|
187
|
-
layer_name = layer.name
|
|
209
|
+
layer_name = layer.name.replace(' ','-')
|
|
188
210
|
match_invalid = re.search(r"[~\"#%&*:<>?/\\{|}]+", layer.name)
|
|
189
211
|
if match_invalid:
|
|
190
212
|
layer_name = layer_name.replace(match_invalid.group(0), '')
|
|
@@ -196,13 +218,18 @@ class ExportPSDLayers(flow.Action):
|
|
|
196
218
|
|
|
197
219
|
session.log_info(log_format.format(message=f'Exporting layer {layer_name}'))
|
|
198
220
|
|
|
199
|
-
|
|
200
|
-
|
|
221
|
+
if not layer.visible:
|
|
222
|
+
layer.visible = True
|
|
223
|
+
# psb.save(source_revision.get_path())
|
|
201
224
|
|
|
202
225
|
# Push layer in correct JSON data
|
|
203
226
|
layers_data["layers" if layer.visible else "hidden_layers"].append(
|
|
204
227
|
layer_name
|
|
205
228
|
)
|
|
229
|
+
|
|
230
|
+
image = layer.composite(viewport=psb.viewbox)
|
|
231
|
+
image.save(output_path)
|
|
232
|
+
|
|
206
233
|
|
|
207
234
|
# Export JSON data
|
|
208
235
|
json_object = json.dumps(layers_data)
|
|
@@ -246,7 +273,7 @@ class ExportPSDLayers(flow.Action):
|
|
|
246
273
|
utils_layer = psb.find("_utils")
|
|
247
274
|
if utils_layer : utils_layer.visible = False
|
|
248
275
|
|
|
249
|
-
image = psb.composite(force=True)
|
|
276
|
+
image = psb.composite(viewport=psb.viewbox,force=True)
|
|
250
277
|
image.save(output_path)
|
|
251
278
|
|
|
252
279
|
session.log_info(log_format.format(message='Export complete'))
|
|
@@ -485,7 +512,7 @@ class ExportPSDPreview(flow.Action):
|
|
|
485
512
|
|
|
486
513
|
output_path = f"{os.path.splitext(file_path)[0]}.png"
|
|
487
514
|
|
|
488
|
-
image = psb.composite()
|
|
515
|
+
image = psb.composite(viewport=psb.viewbox)
|
|
489
516
|
image.save(output_path)
|
|
490
517
|
|
|
491
518
|
return output_path
|
|
@@ -510,7 +537,7 @@ class ExportPSDPreview(flow.Action):
|
|
|
510
537
|
utils_layer = psb.find("_utils")
|
|
511
538
|
if utils_layer : utils_layer.visible = False
|
|
512
539
|
|
|
513
|
-
image = psb.composite(force=True)
|
|
540
|
+
image = psb.composite(viewport=psb.viewbox,force=True)
|
|
514
541
|
|
|
515
542
|
image.save(output_path)
|
|
516
543
|
|
|
@@ -541,7 +568,7 @@ class ExportPSDPreview(flow.Action):
|
|
|
541
568
|
frame_bbox[3] - 5,
|
|
542
569
|
)
|
|
543
570
|
|
|
544
|
-
image = psb.composite()
|
|
571
|
+
image = psb.composite(viewport=psb.viewbox)
|
|
545
572
|
image = image.crop(frame_bbox)
|
|
546
573
|
image.save(output_path)
|
|
547
574
|
|
|
@@ -8,11 +8,11 @@ import json
|
|
|
8
8
|
|
|
9
9
|
version_json = '''
|
|
10
10
|
{
|
|
11
|
-
"date": "2025-
|
|
11
|
+
"date": "2025-08-07T14:51:04+0200",
|
|
12
12
|
"dirty": false,
|
|
13
13
|
"error": null,
|
|
14
|
-
"full-revisionid": "
|
|
15
|
-
"version": "1.1.
|
|
14
|
+
"full-revisionid": "fe31644892623f2fd46e335334959c9335952d11",
|
|
15
|
+
"version": "1.1.6"
|
|
16
16
|
}
|
|
17
17
|
''' # END VERSION_JSON
|
|
18
18
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: libreflow.extensions.sk.export_psd_layers
|
|
3
|
-
Version: 1.1.
|
|
3
|
+
Version: 1.1.6
|
|
4
4
|
Home-page: https://gitlab.com/lfs.coop/libreflow/libreflow_launcher
|
|
5
5
|
Author: Thomas Thiebaut
|
|
6
6
|
Author-email: autor@les-fees-speciales.coop
|
|
@@ -50,6 +50,18 @@ Types of changes
|
|
|
50
50
|
|
|
51
51
|
## [Unreleased]
|
|
52
52
|
|
|
53
|
+
## [1.1.6] - 2025-08-07
|
|
54
|
+
|
|
55
|
+
### Fixed
|
|
56
|
+
|
|
57
|
+
* Export resized to psd canvas - makes the action less prone to crash from a lack of RAM
|
|
58
|
+
|
|
59
|
+
## [1.1.5] - 2025-07-03
|
|
60
|
+
|
|
61
|
+
### Fixed
|
|
62
|
+
|
|
63
|
+
* Top level layers are forced to be shown when exported and are not added to "hidden_layers" in JSON layers file anymore
|
|
64
|
+
|
|
53
65
|
## [1.1.4] - 2025-05-09
|
|
54
66
|
|
|
55
67
|
### Fixed
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|