Functions¶
src.utils.adobe.try_photoshop(func) -> Callable
¶
Decorator to handle trying to run a Photoshop action but allowing exceptions to fail silently.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
func
|
Function being wrapped. |
required |
Returns:
| Type | Description |
|---|---|
Callable
|
The wrapped function. |
Source code in src\utils\adobe.py
src.utils.adobe.get_photoshop_error_message(err: Exception) -> str
¶
Gets a user-facing error message based on a given Photoshop access exception.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
err
|
Exception
|
Exception object containing the reason an action failed. |
required |
Returns:
| Type | Description |
|---|---|
str
|
Proper user response for this exception. |
Source code in src\utils\adobe.py
src.utils.adobe.get_com_error(signed_int: int) -> str
¶
Check for an error message for both the signed and unsigned version of a COMError code (HRESULT).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
signed_int
|
int
|
Signed integer representing a COMError exception. |
required |
Returns:
| Type | Description |
|---|---|
str
|
The string error message associated with this COMError code. |