View Issue Details

IDProjectCategoryView StatusLast Update
0016790ScribusDocumentationpublic2023-05-29 18:56
Reporterluzpaz Assigned Tojghali  
PrioritylowSeveritytextReproducibilityN/A
Status closedResolutionfixed 
Product Version1.7.0.svn 
Fixed in Version1.6.0.svn 
Summary0016790: Fix various typos
DescriptionAdded 2 patches. One fixes misc. source comments and the other fixes source code typos.
TagsNo tags attached.
PatchNo

Activities

luzpaz

2022-05-08 11:58

reporter  

scribus-typos.patch (4,401 bytes)   
From 67141c8266f31b813ac660179f9268e1d9b9efe7 Mon Sep 17 00:00:00 2001
From: luz paz <luzpaz@pm.me>
Date: Sun, 8 May 2022 07:52:31 -0400
Subject: [PATCH] Fix various typos

Found via `codespell -q 3 -S *.ts,*.po,./scribus/third_party,./doc,./ChangeLog,./codegen/cheetah,./resources/templates/template.de.xml,./resources/templates/template.es.xml,./resources/unicodemap/unicodenameslist.txt,./resources/loremipsum  -L ba,dum,fo,nd,pres,te`
---
 scribus/pageitem_table.h                            | 2 +-
 scribus/plugins/barcodegenerator/barcode.ps         | 6 +++---
 scribus/plugins/scripter/python/safe_eval.py        | 8 ++++----
 scribus/plugins/scripter/python/scripter_runtime.py | 2 +-
 4 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/scribus/pageitem_table.h b/scribus/pageitem_table.h
index eefbc95f2..f81024763 100644
--- a/scribus/pageitem_table.h
+++ b/scribus/pageitem_table.h
@@ -702,7 +702,7 @@ private:
 	// Undo/redo row height action
 	void restoreTableRowHeight(SimpleState *state, bool isUndo);
 
-	// Undo/redo column widht action
+	// Undo/redo column width action
 	void restoreTableColumnWidth(SimpleState *state, bool isUndo);
 
 private:
diff --git a/scribus/plugins/barcodegenerator/barcode.ps b/scribus/plugins/barcodegenerator/barcode.ps
index f491910c6..b53036b07 100644
--- a/scribus/plugins/barcodegenerator/barcode.ps
+++ b/scribus/plugins/barcodegenerator/barcode.ps
@@ -19969,7 +19969,7 @@ begin
             /fid () def
         } ifelse
 
-        % Read the postcode, country code and service code fields seperated by GS
+        % Read the postcode, country code and service code fields separated by GS
         barcode <1d> search pop /pcode exch def
         pop <1d> search pop /ccode exch def
         pop <1d> search pop /scode exch def
@@ -20408,7 +20408,7 @@ begin
     % Recompose the secondary parity codewords
     /secchk [ 0 1 scodes 1 sub { dup secochk exch get exch secechk exch get } for ] def
 
-    % Concatinate the data into final codewords
+    % Concatenate the data into final codewords
     /codewords [
         pri aload pop
         pri 10 rscodes aload pop
@@ -23996,7 +23996,7 @@ begin
         } if
 
         % Check for groups of blank rows unless data is encoded horizontally
-        % in a symbol of sufficent width to overcome up to six consecutive 0s
+        % in a symbol of sufficient width to overcome up to six consecutive 0s
         % in two neighbouring 5 of 9 dot patterns
         rows 2 mod 0 eq columns 12 le or {
             /sum 0 def  /p 0 def
diff --git a/scribus/plugins/scripter/python/safe_eval.py b/scribus/plugins/scripter/python/safe_eval.py
index 4b45b9adc..005c7ce01 100644
--- a/scribus/plugins/scripter/python/safe_eval.py
+++ b/scribus/plugins/scripter/python/safe_eval.py
@@ -475,16 +475,16 @@ class TestSafeEval(unittest.TestCase):
             timed_safe_eval, "().__class__.mro()[1].__subclasses__()")
 
     def test_timeout_ok(self):
-        # attempt to exectute 'slow' code which finishes within timelimit
+        # attempt to execute 'slow' code which finishes within timelimit
         def test(): time.sleep(2)
         env = {'test':test}
         timed_safe_eval("test()", env, timeout_secs = 5)
 
     def test_timeout_exceed(self):
-        # attempt to exectute code which never teminates
+        # attempt to execute code which never teminates
         self.assertRaises(SafeEvalException, \
-            timed_safe_eval, "while 1: pass")
-
+            timed_safe_eval, "while 1: pass")
+
     def test_invalid_context(self):
         # can't pass an environment with modules or builtins
         env = {'f' : __builtins__.open, 'g' : time}
diff --git a/scribus/plugins/scripter/python/scripter_runtime.py b/scribus/plugins/scripter/python/scripter_runtime.py
index 87cbdf2ba..856609815 100644
--- a/scribus/plugins/scripter/python/scripter_runtime.py
+++ b/scribus/plugins/scripter/python/scripter_runtime.py
@@ -164,7 +164,7 @@ def check_python(filename):
 
     problems = checkCode(code)
     if problems and len(problems) == 1 and isinstance(problems[0], SyntaxError):
-        return True # let's ignore it and let excepthook hande the error later
+        return True # let's ignore it and let excepthook handle the error later
     elif problems:
         ok = permitdlg.ask(filename, problems)
         if ok == -2: # deny and remember
-- 
2.35.1

scribus-typos.patch (4,401 bytes)   
scribus-source-typos.patch (2,249 bytes)   
From d550ee927286f266cd502dae709ff61a3f9c7ac2 Mon Sep 17 00:00:00 2001
From: luz paz <luzpaz@pm.me>
Date: Sun, 8 May 2022 07:57:49 -0400
Subject: [PATCH] Fix source typos

---
 scribus/plugins/scriptplugin/scripts/FontSample.py | 14 +++++++-------
 scribus/ui/query.cpp                               |  4 ++--
 2 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/scribus/plugins/scriptplugin/scripts/FontSample.py b/scribus/plugins/scriptplugin/scripts/FontSample.py
index 74a9201fc..3acc1879c 100644
--- a/scribus/plugins/scriptplugin/scripts/FontSample.py
+++ b/scribus/plugins/scriptplugin/scripts/FontSample.py
@@ -707,16 +707,16 @@ def draw_selection(fontList, getSizeOnly):
     set_odd_even(pageNum)
     lineHeight = 1 # include the one point of space below top margin
     lineHeight = lineHeight + draw_horiz_line(0, dD['paperLeftSide'], dD['paperLeftSide'] + dD['paperTextWidth'], 1)
-    usuableArea = dD['paperHeight'] - \
-                  dD['paperTopMargin'] - \
-                  lineHeight - \
-                  dD['paperBottomMargin'] - \
-                  dD['paperPageNumVertOffset']
+    usableArea = dD['paperHeight'] - \
+                 dD['paperTopMargin'] - \
+                 lineHeight - \
+                 dD['paperBottomMargin'] - \
+                 dD['paperPageNumVertOffset']
 
     blockHeight = draw_sample_block(fontList[0], dD['paperLeftSide'], 0, dD['paperTextWidth'], 1)
-    pageBlocks = int(usuableArea / blockHeight)
+    pageBlocks = int(usableArea / blockHeight)
     #print blockHeight
-    #print "Usuable area %s points high" % usuableArea
+    #print "Usable area %s points high" % usableArea
     #print "Used space on page is %s points high" % (blockHeight * pageBlocks)
 
     if not getSizeOnly:
diff --git a/scribus/ui/query.cpp b/scribus/ui/query.cpp
index b081cef98..02c50d92d 100644
--- a/scribus/ui/query.cpp
+++ b/scribus/ui/query.cpp
@@ -130,6 +130,6 @@ void Query::setCheckMode(bool mode)
 
 void Query::setValidator(const QRegularExpression& rx)
 {
-	QValidator* vaild = new QRegularExpressionValidator( rx, this );
-	answerEdit->setValidator(vaild);
+	QValidator* valid = new QRegularExpressionValidator( rx, this );
+	answerEdit->setValidator(valid);
 }
-- 
2.35.1

scribus-source-typos.patch (2,249 bytes)   

jghali

2022-05-09 18:38

administrator   ~0049642

Applied, thanks!

Issue History

Date Modified Username Field Change
2022-05-08 11:58 luzpaz New Issue
2022-05-08 11:58 luzpaz File Added: scribus-typos.patch
2022-05-08 11:58 luzpaz File Added: scribus-source-typos.patch
2022-05-09 18:38 jghali Assigned To => jghali
2022-05-09 18:38 jghali Status new => resolved
2022-05-09 18:38 jghali Resolution open => fixed
2022-05-09 18:38 jghali Fixed in Version => 1.6.0.svn
2022-05-09 18:38 jghali Note Added: 0049642
2023-05-29 18:56 cbradney Status resolved => closed