Network/IRC/IrcMessageEdit.py

branch
Py2 comp.
changeset 3057
10516539f238
parent 2525
8b507a9a2d40
parent 2992
dbdf27746da5
child 3145
a9de05d4a22f
--- a/Network/IRC/IrcMessageEdit.py	Tue Oct 15 22:03:54 2013 +0200
+++ b/Network/IRC/IrcMessageEdit.py	Fri Oct 18 23:00:41 2013 +0200
@@ -20,14 +20,15 @@
     """
     MaxHistory = 100
     
-    def __init__(self, parent=None, inactiveText="", side=E5LineEdit.RightSide):
+    def __init__(self, parent=None, inactiveText="",
+                 side=E5LineEdit.RightSide):
         """
         Constructor
         
         @param parent reference to the parent widget (QWidget)
         @keyparam inactiveText text to be shown on inactivity (string)
-        @keyparam side side the clear button should be shown at (E5LineEdit.RightSide,
-            E5LineEdit.LeftSide)
+        @keyparam side side the clear button should be shown at
+            (E5LineEdit.RightSide, E5LineEdit.LeftSide)
         """
         super(IrcMessageEdit, self).__init__(parent, inactiveText, side)
         
@@ -38,7 +39,8 @@
         """
         Public method to set the text.
         
-        Note: This reimplementation ensures, that the cursor is at the end of the text.
+        Note: This reimplementation ensures, that the cursor is at the end of
+        the text.
         
         @param text text to be set (string)
         """
@@ -71,7 +73,7 @@
         """
         Protected slot to support wheel events.
         
-        @param reference to the wheel event (QWheelEvent)
+        @param evt reference to the wheel event (QWheelEvent)
         """
         if evt.delta() > 0:
             self.__getHistory(True)
@@ -109,19 +111,21 @@
         
         if up:
             self.__historyLine += 1
-            # If the position was moved past the end of the history, go to the last entry
+            # If the position was moved past the end of the history,
+            # go to the last entry
             if self.__historyLine == len(self.__historyList):
                 self.__historyLine -= 1
                 return
         else:
-            # If the position is at the top of the history, arrow-down shall add the text
-            # to the history and clear the line edit for new input
+            # If the position is at the top of the history, arrow-down shall
+            # add the text to the history and clear the line edit for new input
             if self.__historyLine == 0:
                 if self.text():
                     self.__addHistory(self.text())
                 self.setText("")
             else:
-                # If the position is not at the top of the history, decrement it
+                # If the position is not at the top of the history,
+                # decrement it
                 self.__historyLine -= 1
         
         # replace the text of the line edit with the selected history entry

eric ide

mercurial