From 348b6f54777eafa2d64e9b64bd87eb31b61d46cf Mon Sep 17 00:00:00 2001
From: A Nilsen <ban@nibio.no>
Date: Fri, 19 Aug 2022 14:42:45 +0000
Subject: [PATCH] Update get_nib.py
---
get_nib.py | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/get_nib.py b/get_nib.py
index 50e2ebf..c19dc9e 100644
--- a/get_nib.py
+++ b/get_nib.py
@@ -1243,7 +1243,7 @@ class getnib:
ymin = e.yMinimum()
ymax = e.yMaximum()
ok = self.check_bbsize(crs_proj_str, xmin, xmax, ymin, ymax) # Check if bb is small enough
- # If checked, use the length and height from map canvas sentre point
+ # If checked, use the length and height from map canvas centre point
elif self.dlg.radioButton_udbb.isChecked():
# Get the extent of current map canvas (coordinates in the project's crs)
l = self.dlg.lineEdit_lengthbb.text()
@@ -1263,6 +1263,7 @@ class getnib:
ymax = e.y() + int(h)*1000/2
""" Check length and height of bounding box. Limit is set to 500 km """
ok = self.check_bbsize(crs_proj_str, xmin, xmax, ymin, ymax) # Check if bb is small enough
+ else:
if self.dlg.radioButton_lyr.isChecked(): # layer-option checked
lyr_name = self.dlg.comboBox_lyr.currentText() # Get the layer name
if lyr_name != "": # If a layer is present/chosen
@@ -1273,7 +1274,7 @@ class getnib:
else: # If no file or layer is selcted, throw an error mesage and end plugin
self.iface.messageBar().pushMessage("Error", "No layer selected!", level=Qgis.Critical, duration=3)
return # Return from (end) plugin
- else:
+
elif self.dlg.radioButton_file.isChecked(): # file-option checked
fname = self.dlg.lineEdit_file.text() # get the text (path and filename)
if fname != "":
--
GitLab