summaryrefslogtreecommitdiff
path: root/lib/extensions/element_info.py
diff options
context:
space:
mode:
authorKaalleen <36401965+kaalleen@users.noreply.github.com>2024-08-17 17:29:54 +0200
committerGitHub <noreply@github.com>2024-08-17 17:29:54 +0200
commit300755c436ff2dfb9cdcb18aeb14cc368631b784 (patch)
tree5dd5a1898724e2c70a30103250bd38f005f41561 /lib/extensions/element_info.py
parent404c483cc7c220b2521ab06011bf612303ca2029 (diff)
add wxpython abort message (as alternative to stderr output) (#3145)
Diffstat (limited to 'lib/extensions/element_info.py')
-rw-r--r--lib/extensions/element_info.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/extensions/element_info.py b/lib/extensions/element_info.py
index 846bba17..2f3de736 100644
--- a/lib/extensions/element_info.py
+++ b/lib/extensions/element_info.py
@@ -4,6 +4,7 @@
# Licensed under the GNU GPL version 3.0 or later. See the file LICENSE for details.
from ..elements import FillStitch, SatinColumn, Stroke
+from ..gui.abort_message import AbortMessageApp
from ..gui.element_info import ElementInfoApp
from ..i18n import _
from ..stitch_plan import stitch_groups_to_stitch_plan
@@ -15,6 +16,11 @@ class ElementInfo(InkstitchExtension):
def effect(self):
if not self.svg.selection or not self.get_elements():
+ app = AbortMessageApp(
+ _("Please select at least one element."),
+ _("https://inkstitch.org/docs/troubleshoot/#element-info")
+ )
+ app.MainLoop()
return
self.metadata = self.get_inkstitch_metadata()