Browse Source

codespell

pull/49/head
Kurt Schwehr 4 years ago
parent
commit
cd41b2e578
  1. 2
      TermTk/TTkCore/canvas.py
  2. 4
      TermTk/TTkCore/string.py
  3. 2
      TermTk/TTkWidgets/TTkModelView/treewidget.py
  4. 2
      TermTk/TTkWidgets/TTkModelView/treewidgetitem.py
  5. 4
      TermTk/TTkWidgets/combobox.py
  6. 2
      TermTk/TTkWidgets/radiobutton.py
  7. 4
      TermTk/TTkWidgets/scrollbar.py
  8. 4
      TermTk/TTkWidgets/widget.py
  9. 2
      docs/MDNotes/TODO.md
  10. 8
      tutorial/002-layout.rst
  11. 2
      tutorial/005-calculator.rst
  12. 2
      tutorial/calculator/calculator.002.py
  13. 2
      tutorial/calculator/calculator.003.py
  14. 2
      tutorial/calculator/calculator.004.py
  15. 2
      tutorial/calculator/calculator.005.py
  16. 2
      tutorial/layout/example2.simple.vbox.py
  17. 2
      tutorial/layout/example3.simple.hbox.py
  18. 2
      tutorial/layout/example4.simple.grid.py
  19. 2
      tutorial/layout/example5.nested.layouts.py
  20. 2
      tutorial/layout/example6.grid.span.py

2
TermTk/TTkCore/canvas.py

@ -193,7 +193,7 @@ class TTkCanvas:
'''
NOTE:
drawText is one of the most abused functions,
there is some reduntant code here in order to reduce the footprint
there is some redundant code here in order to reduce the footprint
'''
if not self._visible: return

4
TermTk/TTkCore/string.py

@ -307,7 +307,7 @@ class TTkString():
def addColor(self, color, match=None, posFrom=None, posTo=None):
''' Add the color of the entire string or a slice of it
If only the color is specified, the entire sting is colorized
If only the color is specified, the entire string is colorized
:param color: the color to be used, defaults to :class:`~TermTk.TTkCore.color.TTkColor.RST`
:type color: :class:`~TermTk.TTkCore.color.TTkColor`
@ -345,7 +345,7 @@ class TTkString():
def setColor(self, color, match=None, posFrom=None, posTo=None):
''' Set the color of the entire string or a slice of it
If only the color is specified, the entire sting is colorized
If only the color is specified, the entire string is colorized
:param color: the color to be used, defaults to :class:`~TermTk.TTkCore.color.TTkColor.RST`
:type color: :class:`~TermTk.TTkCore.color.TTkColor`

2
TermTk/TTkWidgets/TTkModelView/treewidget.py

@ -235,7 +235,7 @@ class TTkTreeWidget(TTkAbstractScrollView):
@pyTTkSlot()
def _refreshCache(self):
''' I save a representation fo the displayed tree in a cache array
''' I save a representation of the displayed tree in a cache array
to avoid eccessve recursion over the items and
identify quickly the nth displayed line to improve the interaction

2
TermTk/TTkWidgets/TTkModelView/treewidgetitem.py

@ -142,7 +142,7 @@ class TTkTreeWidgetItem(TTkAbstractItemModel):
self._children,
key = lambda x : x.sortData(self._sortColumn),
reverse = self._sortOrder == TTkK.DescendingOrder)
# Broadcast the sorting to the childrens
# Broadcast the sorting to the children
if children:
for c in self._children:
c.dataChanged.disconnect(self.emitDataChanged)

4
TermTk/TTkWidgets/combobox.py

@ -44,7 +44,7 @@ class TTkComboBox(TTkWidget):
self.editTextChanged = pyTTkSignal(str)
TTkWidget.__init__(self, *args, **kwargs)
self._name = kwargs.get('name' , 'TTkCheckbox' )
# self.cehcked = pyTTkSignal()
# self.checked = pyTTkSignal()
self._lineEdit = TTkLineEdit(parent=self)
self._list = kwargs.get('list', [] )
self._insertPolicy = kwargs.get('insertPolicy', TTkK.InsertAtBottom )
@ -220,4 +220,4 @@ class TTkComboBox(TTkWidget):
def focusInEvent(self):
if self._editable:
self._lineEdit.setFocus()
self._lineEdit.setFocus()

2
TermTk/TTkWidgets/radiobutton.py

@ -69,7 +69,7 @@ class TTkRadioButton(TTkWidget):
self.clicked = pyTTkSignal()
TTkWidget.__init__(self, *args, **kwargs)
self._name = kwargs.get('name' , 'TTkRadioButton' )
# self.cehcked = pyTTkSignal()
# self.checked = pyTTkSignal()
self._checked = kwargs.get('checked', False )
self._text = kwargs.get('text', '' )
self.setMinimumSize(3 + len(self._text), 1)

4
TermTk/TTkWidgets/scrollbar.py

@ -107,7 +107,7 @@ class TTkScrollBar(TTkWidget):
if asciiStep==0: asciiStep=1 # Force the slider to be at least one char wide
asciiDrawingSize = size2 - asciiStep
a = self._value - self._minimum
# covert i screen coordinates
# convert i screen coordinates
aa = asciiDrawingSize * a // (self._maximum - self._minimum)
bb = aa + asciiStep
self._canvas.drawScroll(pos=(0,0),size=size,slider=(aa+1,bb+1),orientation=self._orientation, color=color)
@ -265,4 +265,4 @@ class TTkScrollBar(TTkWidget):
def focusColor(self, color):
if self.focusColor != color:
self._focusColor = color
self.update()
self.update()

4
TermTk/TTkWidgets/widget.py

@ -194,7 +194,7 @@ class TTkWidget(TMouseEvents,TKeyEvents, TDragEvents):
def paintEvent(self):
'''
Paint Event callback,
ths need to be overridden in the widget.
this need to be overridden in the widget.
'''
pass
@ -341,7 +341,7 @@ class TTkWidget(TMouseEvents,TKeyEvents, TDragEvents):
if not self._enabled: return True
# Mouse Drag has priority because it
# should be handled by the focussed widget
# should be handled by the focused widget
# unless there is a Drag and Drop event ongoing
if evt.evt == TTkK.Drag and not TTkHelper.isDnD():
if self.mouseDragEvent(evt):

2
docs/MDNotes/TODO.md

@ -51,7 +51,7 @@
## Logs
- [x] Log Class
- [ ] Run Logger on a separate thread (push sring to a queue)
- [ ] Run Logger on a separate thread (push string to a queue)
- [ ] Include option to force print
- [ ] Log helpers
- [x] File and Stdout logger

8
tutorial/002-layout.rst

@ -152,7 +152,7 @@ Following is the code to execute `VBox Example`_ in pyTermTk_
import TermTk as ttk
# Set the VBoxLayout as defaut in the terminal widget
# Set the VBoxLayout as default in the terminal widget
root = ttk.TTk(layout=ttk.TTkVBoxLayout())
# Attach 4 buttons to the root widget
@ -198,7 +198,7 @@ Following is the code to execute `HBox Example`_ in pyTermTk_
import TermTk as ttk
# Set the HBoxLayout as defaut in the terminal widget
# Set the HBoxLayout as default in the terminal widget
root = ttk.TTk()
root.setLayout(ttk.TTkHBoxLayout())
@ -246,7 +246,7 @@ Following is the code to execute `HBox Example`_ in pyTermTk_
import TermTk as ttk
# Set the GridLayout as defaut in the terminal widget
# Set the GridLayout as default in the terminal widget
gridLayout = ttk.TTkGridLayout(columnMinHeight=0,columnMinWidth=2)
root = ttk.TTk(layout=gridLayout)
@ -290,7 +290,7 @@ Following is the code to execute `Nested Layouts Example`_ in pyTermTk_
import TermTk as ttk
# Set the GridLayout as defaut in the terminal widget
# Set the GridLayout as default in the terminal widget
root = ttk.TTk()
gridLayout = ttk.TTkGridLayout()

2
tutorial/005-calculator.rst

@ -124,7 +124,7 @@ Based on the positions and sizes defined in the `design layout <#design>`_, I pl
# Just to show off I am using another way to attach it to the grid layout
winLayout.addWidget(btn0:=ttk.TTkButton(border=True, text="0"), 4,0, 1,2)
# Define the 2 algebric buttons
# Define the 2 algebraic buttons
winLayout.addWidget(btnAdd:=ttk.TTkButton(border=True, text="+"), 1,3)
winLayout.addWidget(btnSub:=ttk.TTkButton(border=True, text="-"), 2,3)

2
tutorial/calculator/calculator.002.py

@ -66,7 +66,7 @@ winLayout.addWidget(btn9, 3,2)
# Just to show off I am using another way to attach it to the grid layout
winLayout.addWidget(btn0:=ttk.TTkButton(border=True, text="0"), 4,0, 1,2)
# Define the 2 algebric buttons
# Define the 2 algebraic buttons
winLayout.addWidget(btnAdd:=ttk.TTkButton(border=True, text="+"), 1,3)
winLayout.addWidget(btnSub:=ttk.TTkButton(border=True, text="-"), 2,3)

2
tutorial/calculator/calculator.003.py

@ -67,7 +67,7 @@ winLayout.addWidget(btn9, 3,2)
# Just to show off I am using another way to attach it to the grid layout
winLayout.addWidget(btn0:=ttk.TTkButton(border=True, text="0"), 4,0, 1,2)
# Define the 2 algebric buttons
# Define the 2 algebraic buttons
winLayout.addWidget(btnAdd:=ttk.TTkButton(border=True, text="+"), 1,3)
winLayout.addWidget(btnSub:=ttk.TTkButton(border=True, text="-"), 2,3)

2
tutorial/calculator/calculator.004.py

@ -68,7 +68,7 @@ winLayout.addWidget(btn9, 3,2)
# Just to show off I am using another way to attach it to the grid layout
winLayout.addWidget(btn0:=ttk.TTkButton(border=True, text="0"), 4,0, 1,2)
# Define the 2 algebric buttons
# Define the 2 algebraic buttons
winLayout.addWidget(btnAdd:=ttk.TTkButton(border=True, text="+"), 1,3)
winLayout.addWidget(btnSub:=ttk.TTkButton(border=True, text="-"), 2,3)

2
tutorial/calculator/calculator.005.py

@ -68,7 +68,7 @@ winLayout.addWidget(btn9, 3,2)
# Just to show off I am using another way to attach it to the grid layout
winLayout.addWidget(btn0:=ttk.TTkButton(border=True, text="0"), 4,0, 1,2)
# Define the 2 algebric buttons
# Define the 2 algebraic buttons
winLayout.addWidget(btnAdd:=ttk.TTkButton(border=True, text="+"), 1,3)
winLayout.addWidget(btnSub:=ttk.TTkButton(border=True, text="-"), 2,3)

2
tutorial/layout/example2.simple.vbox.py

@ -24,7 +24,7 @@
import TermTk as ttk
# Set the VBoxLayout as defaut in the terminal widget
# Set the VBoxLayout as default in the terminal widget
root = ttk.TTk(layout=ttk.TTkVBoxLayout())
# Attach 4 buttons to the root widget

2
tutorial/layout/example3.simple.hbox.py

@ -24,7 +24,7 @@
import TermTk as ttk
# Set the HBoxLayout as defaut in the terminal widget
# Set the HBoxLayout as default in the terminal widget
root = ttk.TTk()
root.setLayout(ttk.TTkHBoxLayout())

2
tutorial/layout/example4.simple.grid.py

@ -24,7 +24,7 @@
import TermTk as ttk
# Set the GridLayout as defaut in the terminal widget
# Set the GridLayout as default in the terminal widget
gridLayout = ttk.TTkGridLayout(columnMinHeight=0,columnMinWidth=2)
root = ttk.TTk(layout=gridLayout)

2
tutorial/layout/example5.nested.layouts.py

@ -24,7 +24,7 @@
import TermTk as ttk
# Set the GridLayout as defaut in the terminal widget
# Set the GridLayout as default in the terminal widget
root = ttk.TTk()
gridLayout = ttk.TTkGridLayout()

2
tutorial/layout/example6.grid.span.py

@ -24,7 +24,7 @@
import TermTk as ttk
# Set the GridLayout as defaut in the terminal widget
# Set the GridLayout as default in the terminal widget
root = ttk.TTk()
gridLayout = ttk.TTkGridLayout()

Loading…
Cancel
Save