Skip to content
Snippets Groups Projects
Commit 01454b99 authored by Thomas Holene Løkkeborg's avatar Thomas Holene Løkkeborg
Browse files

#98 docstrings & liten lint fiks

parent af7d64df
No related branches found
No related tags found
1 merge request!73#98 Kodefrasemodul
Pipeline #83649 passed
...@@ -151,6 +151,11 @@ def event_is_ctrl_plus(event): ...@@ -151,6 +151,11 @@ def event_is_ctrl_plus(event):
---------- ----------
event : QKeyEvent event : QKeyEvent
Event to check. Event to check.
Returns
-------
bool
True if is event is 'CTRL +'
""" """
return ( return (
event.modifiers() == Qt.ControlModifier and event.key() == Qt.Key_Plus event.modifiers() == Qt.ControlModifier and event.key() == Qt.Key_Plus
...@@ -164,6 +169,11 @@ def event_is_ctrl_minus(event): ...@@ -164,6 +169,11 @@ def event_is_ctrl_minus(event):
---------- ----------
event : QKeyEvent event : QKeyEvent
Event to check. Event to check.
Returns
-------
bool
True if is event is 'CTRL -'
""" """
# Underline is in practice minus in this situation. We don't know why # Underline is in practice minus in this situation. We don't know why
return ( return (
...@@ -179,6 +189,11 @@ def event_is_shift_plus(event): ...@@ -179,6 +189,11 @@ def event_is_shift_plus(event):
---------- ----------
event : QKeyEvent event : QKeyEvent
Event to check. Event to check.
Returns
-------
bool
True if is event is 'SHIFT +'
""" """
return event.key() == Qt.Key_Question return event.key() == Qt.Key_Question
...@@ -190,6 +205,11 @@ def event_is_shift_minus(event): ...@@ -190,6 +205,11 @@ def event_is_shift_minus(event):
---------- ----------
event : QKeyEvent event : QKeyEvent
Event to check. Event to check.
Returns
-------
bool
True if is event is 'SHIFT -'
""" """
# Underline is in practice minus in this situation. We don't know why # Underline is in practice minus in this situation. We don't know why
return ( return (
......
...@@ -142,7 +142,7 @@ class TestModulesAcrossResolutions(unittest.TestCase): ...@@ -142,7 +142,7 @@ class TestModulesAcrossResolutions(unittest.TestCase):
if module == CodePhraseModule: if module == CodePhraseModule:
# CodePhraseModule needs a category injected in it's init. # CodePhraseModule needs a category injected in it's init.
# Choosing "Tresort" because it contains words short enough # Choosing "Tresort" because it contains words short enough
#to not expand the module beyond default width # to not expand the module beyond default width
module_instance = module( module_instance = module(
database=database, category="Tresort" database=database, category="Tresort"
) )
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment