Added code to set the 'fill to end of line' setting for the current selection. 5_5_x

Sat, 06 Dec 2014 13:03:59 +0100

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Sat, 06 Dec 2014 13:03:59 +0100
branch
5_5_x
changeset 3961
1e8abbfe11c7
parent 3958
14f5bcd2e2f8
child 3963
ebc0ea77c074

Added code to set the 'fill to end of line' setting for the current selection.
(grafted from 50e92e127159ca06c1a1fcaa73d437080c3640ed)

Preferences/ConfigurationPages/EditorHighlightingStylesPage.py file | annotate | diff | comparison | revisions
--- a/Preferences/ConfigurationPages/EditorHighlightingStylesPage.py	Mon Dec 01 14:05:48 2014 +0100
+++ b/Preferences/ConfigurationPages/EditorHighlightingStylesPage.py	Sat Dec 06 13:03:59 2014 +0100
@@ -316,9 +316,16 @@
         
         @param on flag indicating enabled or disabled state (boolean)
         """
-        self.lexer.setEolFill(on, self.style)
         checkState = Qt.Checked if on else Qt.Unchecked
-        self.styleElementList.currentItem().setCheckState(checkState)
+        if len(self.styleElementList.selectedItems()) > 1:
+            for selItem in self.styleElementList.selectedItems():
+                style = self.lexer.ind2style[
+                    self.styleElementList.row(selItem)]
+                self.lexer.setEolFill(on, style)
+                selItem.setCheckState(checkState)
+        else:
+            self.lexer.setEolFill(on, self.style)
+            self.styleElementList.currentItem().setCheckState(checkState)
         
     @pyqtSlot()
     def on_allEolFillButton_clicked(self):

eric ide

mercurial