Sat, 19 Oct 2013 15:15:50 +0200
Fixed a bunch of indentation issues.
--- a/IconEditor/IconEditorWindow.py Sat Oct 19 14:05:26 2013 +0200 +++ b/IconEditor/IconEditorWindow.py Sat Oct 19 15:15:50 2013 +0200 @@ -191,8 +191,8 @@ 0, self, 'iconEditor_file_new') self.newAct.setStatusTip(self.trUtf8('Create a new icon')) self.newAct.setWhatsThis(self.trUtf8( - """<b>New</b>""" - """<p>This creates a new icon.</p>""" + """<b>New</b>""" + """<p>This creates a new icon.</p>""" )) self.newAct.triggered[()].connect(self.__newIcon) self.__actions.append(self.newAct) @@ -205,8 +205,8 @@ self.newWindowAct.setStatusTip(self.trUtf8( 'Open a new icon editor window')) self.newWindowAct.setWhatsThis(self.trUtf8( - """<b>New Window</b>""" - """<p>This opens a new icon editor window.</p>""" + """<b>New Window</b>""" + """<p>This opens a new icon editor window.</p>""" )) self.newWindowAct.triggered[()].connect(self.__newWindow) self.__actions.append(self.newWindowAct) @@ -219,9 +219,9 @@ 0, self, 'iconEditor_file_open') self.openAct.setStatusTip(self.trUtf8('Open an icon file for editing')) self.openAct.setWhatsThis(self.trUtf8( - """<b>Open File</b>""" - """<p>This opens a new icon file for editing.""" - """ It pops up a file selection dialog.</p>""" + """<b>Open File</b>""" + """<p>This opens a new icon file for editing.""" + """ It pops up a file selection dialog.</p>""" )) self.openAct.triggered[()].connect(self.__openIcon) self.__actions.append(self.openAct) @@ -249,8 +249,8 @@ self.saveAsAct.setStatusTip( self.trUtf8('Save the current icon to a new file')) self.saveAsAct.setWhatsThis(self.trUtf8( - """<b>Save As...</b>""" - """<p>Saves the current icon to a new file.</p>""" + """<b>Save As...</b>""" + """<p>Saves the current icon to a new file.</p>""" )) self.saveAsAct.triggered[()].connect(self.__saveIconAs) self.__actions.append(self.saveAsAct) @@ -264,8 +264,8 @@ self.closeAct.setStatusTip(self.trUtf8( 'Close the current icon editor window')) self.closeAct.setWhatsThis(self.trUtf8( - """<b>Close</b>""" - """<p>Closes the current icon editor window.</p>""" + """<b>Close</b>""" + """<p>Closes the current icon editor window.</p>""" )) self.closeAct.triggered[()].connect(self.close) self.__actions.append(self.closeAct) @@ -291,8 +291,8 @@ 0, self, 'iconEditor_file_quit') self.exitAct.setStatusTip(self.trUtf8('Quit the icon editor')) self.exitAct.setWhatsThis(self.trUtf8( - """<b>Quit</b>""" - """<p>Quit the icon editor.</p>""" + """<b>Quit</b>""" + """<p>Quit the icon editor.</p>""" )) if not self.fromEric: self.exitAct.triggered[()].connect(self.__closeAll) @@ -479,8 +479,8 @@ 0, self, 'iconEditor_view_zoom_in') self.zoomInAct.setStatusTip(self.trUtf8('Zoom in on the icon')) self.zoomInAct.setWhatsThis(self.trUtf8( - """<b>Zoom in</b>""" - """<p>Zoom in on the icon. This makes the grid bigger.</p>""" + """<b>Zoom in</b>""" + """<p>Zoom in on the icon. This makes the grid bigger.</p>""" )) self.zoomInAct.triggered[()].connect(self.__zoomIn) self.__actions.append(self.zoomInAct) @@ -493,8 +493,8 @@ 0, self, 'iconEditor_view_zoom_out') self.zoomOutAct.setStatusTip(self.trUtf8('Zoom out on the icon')) self.zoomOutAct.setWhatsThis(self.trUtf8( - """<b>Zoom out</b>""" - """<p>Zoom out on the icon. This makes the grid smaller.</p>""" + """<b>Zoom out</b>""" + """<p>Zoom out on the icon. This makes the grid smaller.</p>""" )) self.zoomOutAct.triggered[()].connect(self.__zoomOut) self.__actions.append(self.zoomOutAct) @@ -508,9 +508,9 @@ self.zoomResetAct.setStatusTip(self.trUtf8( 'Reset the zoom of the icon')) self.zoomResetAct.setWhatsThis(self.trUtf8( - """<b>Zoom reset</b>""" - """<p>Reset the zoom of the icon. """ - """This sets the zoom factor to 100%.</p>""" + """<b>Zoom reset</b>""" + """<p>Reset the zoom of the icon. """ + """This sets the zoom factor to 100%.</p>""" )) self.zoomResetAct.triggered[()].connect(self.__zoomReset) self.__actions.append(self.zoomResetAct) @@ -524,9 +524,9 @@ self.showGridAct.setStatusTip(self.trUtf8( 'Toggle the display of the grid')) self.showGridAct.setWhatsThis(self.trUtf8( - """<b>Show Grid</b>""" - """<p>Toggle the display of the grid.</p>""" - )) + """<b>Show Grid</b>""" + """<p>Toggle the display of the grid.</p>""" + )) self.showGridAct.triggered[bool].connect(self.__editor.setGridEnabled) self.__actions.append(self.showGridAct) self.showGridAct.setCheckable(True) @@ -549,8 +549,8 @@ 0, 0, self.drawingActGrp, 'iconEditor_tools_pencil') self.drawPencilAct.setWhatsThis(self.trUtf8( - """<b>Free hand</b>""" - """<p>Draws non linear lines.</p>""" + """<b>Free hand</b>""" + """<p>Draws non linear lines.</p>""" )) self.drawPencilAct.setCheckable(True) self.esm.setMapping(self.drawPencilAct, IconEditorGrid.Pencil) @@ -564,9 +564,9 @@ 0, 0, self.drawingActGrp, 'iconEditor_tools_color_picker') self.drawColorPickerAct.setWhatsThis(self.trUtf8( - """<b>Color Picker</b>""" - """<p>The color of the pixel clicked on will become """ - """the current draw color.</p>""" + """<b>Color Picker</b>""" + """<p>The color of the pixel clicked on will become """ + """the current draw color.</p>""" )) self.drawColorPickerAct.setCheckable(True) self.esm.setMapping(self.drawColorPickerAct, @@ -581,8 +581,8 @@ 0, 0, self.drawingActGrp, 'iconEditor_tools_rectangle') self.drawRectangleAct.setWhatsThis(self.trUtf8( - """<b>Rectangle</b>""" - """<p>Draw a rectangle.</p>""" + """<b>Rectangle</b>""" + """<p>Draw a rectangle.</p>""" )) self.drawRectangleAct.setCheckable(True) self.esm.setMapping(self.drawRectangleAct, IconEditorGrid.Rectangle) @@ -596,8 +596,8 @@ 0, 0, self.drawingActGrp, 'iconEditor_tools_filled_rectangle') self.drawFilledRectangleAct.setWhatsThis(self.trUtf8( - """<b>Filled Rectangle</b>""" - """<p>Draw a filled rectangle.</p>""" + """<b>Filled Rectangle</b>""" + """<p>Draw a filled rectangle.</p>""" )) self.drawFilledRectangleAct.setCheckable(True) self.esm.setMapping(self.drawFilledRectangleAct, @@ -612,8 +612,8 @@ 0, 0, self.drawingActGrp, 'iconEditor_tools_circle') self.drawCircleAct.setWhatsThis(self.trUtf8( - """<b>Circle</b>""" - """<p>Draw a circle.</p>""" + """<b>Circle</b>""" + """<p>Draw a circle.</p>""" )) self.drawCircleAct.setCheckable(True) self.esm.setMapping(self.drawCircleAct, IconEditorGrid.Circle) @@ -627,8 +627,8 @@ 0, 0, self.drawingActGrp, 'iconEditor_tools_filled_circle') self.drawFilledCircleAct.setWhatsThis(self.trUtf8( - """<b>Filled Circle</b>""" - """<p>Draw a filled circle.</p>""" + """<b>Filled Circle</b>""" + """<p>Draw a filled circle.</p>""" )) self.drawFilledCircleAct.setCheckable(True) self.esm.setMapping(self.drawFilledCircleAct, @@ -643,8 +643,8 @@ 0, 0, self.drawingActGrp, 'iconEditor_tools_ellipse') self.drawEllipseAct.setWhatsThis(self.trUtf8( - """<b>Ellipse</b>""" - """<p>Draw an ellipse.</p>""" + """<b>Ellipse</b>""" + """<p>Draw an ellipse.</p>""" )) self.drawEllipseAct.setCheckable(True) self.esm.setMapping(self.drawEllipseAct, IconEditorGrid.Ellipse) @@ -658,8 +658,8 @@ 0, 0, self.drawingActGrp, 'iconEditor_tools_filled_ellipse') self.drawFilledEllipseAct.setWhatsThis(self.trUtf8( - """<b>Filled Ellipse</b>""" - """<p>Draw a filled ellipse.</p>""" + """<b>Filled Ellipse</b>""" + """<p>Draw a filled ellipse.</p>""" )) self.drawFilledEllipseAct.setCheckable(True) self.esm.setMapping(self.drawFilledEllipseAct, @@ -674,9 +674,9 @@ 0, 0, self.drawingActGrp, 'iconEditor_tools_flood_fill') self.drawFloodFillAct.setWhatsThis(self.trUtf8( - """<b>Flood Fill</b>""" - """<p>Fill adjoining pixels with the same color with """ - """the current color.</p>""" + """<b>Flood Fill</b>""" + """<p>Fill adjoining pixels with the same color with """ + """the current color.</p>""" )) self.drawFloodFillAct.setCheckable(True) self.esm.setMapping(self.drawFloodFillAct, IconEditorGrid.Fill) @@ -690,8 +690,8 @@ 0, 0, self.drawingActGrp, 'iconEditor_tools_line') self.drawLineAct.setWhatsThis(self.trUtf8( - """<b>Line</b>""" - """<p>Draw a line.</p>""" + """<b>Line</b>""" + """<p>Draw a line.</p>""" )) self.drawLineAct.setCheckable(True) self.esm.setMapping(self.drawLineAct, IconEditorGrid.Line) @@ -705,8 +705,8 @@ 0, 0, self.drawingActGrp, 'iconEditor_tools_eraser') self.drawEraserAct.setWhatsThis(self.trUtf8( - """<b>Eraser (Transparent)</b>""" - """<p>Erase pixels by setting them to transparent.</p>""" + """<b>Eraser (Transparent)</b>""" + """<p>Erase pixels by setting them to transparent.</p>""" )) self.drawEraserAct.setCheckable(True) self.esm.setMapping(self.drawEraserAct, IconEditorGrid.Rubber) @@ -1120,14 +1120,14 @@ E5MessageBox.warning( self, self.trUtf8("eric5 Icon Editor"), self.trUtf8("The file '{0}' does not exist.") - .format(fileName)) + .format(fileName)) return if not file.open(QFile.ReadOnly): E5MessageBox.warning( self, self.trUtf8("eric5 Icon Editor"), self.trUtf8("Cannot read file '{0}:\n{1}.") - .format(fileName, file.errorString())) + .format(fileName, file.errorString())) return file.close() @@ -1147,7 +1147,7 @@ E5MessageBox.warning( self, self.trUtf8("eric5 Icon Editor"), self.trUtf8("Cannot write file '{0}:\n{1}.") - .format(fileName, file.errorString())) + .format(fileName, file.errorString())) self.__checkActions() @@ -1161,7 +1161,7 @@ E5MessageBox.warning( self, self.trUtf8("eric5 Icon Editor"), self.trUtf8("Cannot write file '{0}:\n{1}.") - .format(fileName, file.errorString())) + .format(fileName, file.errorString())) self.__checkActions()
--- a/MultiProject/MultiProject.py Sat Oct 19 14:05:26 2013 +0200 +++ b/MultiProject/MultiProject.py Sat Oct 19 15:15:50 2013 +0200 @@ -419,7 +419,7 @@ self.parent(), self.trUtf8("Open multiproject"), Preferences.getMultiProject("Workspace") or - Utilities.getHomeDir(), + Utilities.getHomeDir(), self.trUtf8("Multiproject Files (*.e4m)")) if fn == "": @@ -444,7 +444,7 @@ self.multiProjectOpened.emit() if openMaster and Preferences.getMultiProject( - "OpenMasterAutomatically"): + "OpenMasterAutomatically"): self.__openMasterProject(False) else: QApplication.restoreOverrideCursor() @@ -475,7 +475,7 @@ defaultPath = self.ppath else: defaultPath = Preferences.getMultiProject("Workspace") or \ - Utilities.getHomeDir() + Utilities.getHomeDir() fn, selectedFilter = E5FileDialog.getSaveFileNameAndFilter( self.parent(), self.trUtf8("Save multiproject as"),
--- a/Network/IRC/IrcChannelWidget.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Network/IRC/IrcChannelWidget.py Sat Oct 19 15:15:50 2013 +0200 @@ -349,9 +349,10 @@ self.messages.append( '<font color="{0}">{2} <b><</b><font color="{1}">{3}</font>' '<b>></b> {4}</font>'.format( - Preferences.getIrc("ChannelMessageColour"), - Preferences.getIrc("OwnNickColour"), - ircTimestamp(), self.__userName, Utilities.html_encode(msg))) + Preferences.getIrc("ChannelMessageColour"), + Preferences.getIrc("OwnNickColour"), + ircTimestamp(), self.__userName, + Utilities.html_encode(msg))) if msg.startswith("/"): if self.__private: E5MessageBox.information( @@ -386,7 +387,7 @@ self.trUtf8("Leave IRC channel"), self.trUtf8( """Do you really want to leave the IRC channel <b>{0}</b>?""") - .format(self.__name)) + .format(self.__name)) if ok: if not self.__private: self.sendData.emit( @@ -517,16 +518,16 @@ self.__appendMessage( '<font color="{0}">{2} <b><</b><font color="{1}">{3}</font>' '<b>></b> {4}</font>'.format( - Preferences.getIrc("ChannelMessageColour"), - Preferences.getIrc("NickColour"), - ircTimestamp(), sender, ircFilter(msg))) + Preferences.getIrc("ChannelMessageColour"), + Preferences.getIrc("NickColour"), + ircTimestamp(), sender, ircFilter(msg))) if Preferences.getIrc("ShowNotifications"): if Preferences.getIrc("NotifyMessage"): self.__ui.showNotification( UI.PixmapCache.getPixmap("irc48.png"), self.trUtf8("Channel Message"), msg) elif Preferences.getIrc("NotifyNick") and \ - self.__userName.lower() in msg.lower(): + self.__userName.lower() in msg.lower(): self.__ui.showNotification( UI.PixmapCache.getPixmap("irc48.png"), self.trUtf8("Nick mentioned"), msg) @@ -554,13 +555,13 @@ IrcUserItem(match.group(1), self.usersList) msg = self.trUtf8( "{0} has joined the channel {1} ({2}).").format( - match.group(1), self.__name, match.group(2)) + match.group(1), self.__name, match.group(2)) self.__addManagementMessage( IrcChannelWidget.JoinIndicator, msg) else: msg = self.trUtf8( "You have joined the channel {0} ({1}).").format( - self.__name, match.group(2)) + self.__name, match.group(2)) self.__addManagementMessage( IrcChannelWidget.JoinIndicator, msg) if Preferences.getIrc("ShowNotifications") and \ @@ -727,7 +728,7 @@ IrcChannelWidget.MessageIndicator, self.trUtf8("The topic was set by {0} on {1}.").format( match.group(2), QDateTime.fromTime_t(int(match.group(3))) - .toString("yyyy-MM-dd hh:mm"))) + .toString("yyyy-MM-dd hh:mm"))) return True return False @@ -796,7 +797,7 @@ IrcChannelWidget.MessageIndicator, self.trUtf8("This channel was created on {0}.").format( QDateTime.fromTime_t(int(match.group(2))) - .toString("yyyy-MM-dd hh:mm"))) + .toString("yyyy-MM-dd hh:mm"))) return True return False @@ -1023,7 +1024,7 @@ self.__addManagementMessage( self.trUtf8("CTCP"), self.trUtf8("Received Version request from {0}.").format( - match.group(1))) + match.group(1))) self.sendCtcpReply.emit(match.group(1), "VERSION " + msg) elif ctcpRequest == "ping": self.__addManagementMessage( @@ -1107,7 +1108,7 @@ color = Preferences.getIrc("ChannelInfoColour") self.__appendMessage( '<font color="{0}">{1} <b>[</b>{2}<b>]</b> {3}</font>'.format( - color, ircTimestamp(), indicator, message)) + color, ircTimestamp(), indicator, message)) def __appendMessage(self, message): """ @@ -1199,7 +1200,7 @@ "", self.trUtf8( "HTML Files (*.{0});;Text Files (*.txt);;All Files (*)") - .format(htmlExtension), + .format(htmlExtension), None, E5FileDialog.Options(E5FileDialog.DontConfirmOverwrite)) if fname: @@ -1235,7 +1236,7 @@ self.trUtf8( """<p>The messages contents could not be written""" """ to <b>{0}</b></p><p>Reason: {1}</p>""") - .format(fname, str(err))) + .format(fname, str(err))) def __initMessagesMenu(self): """ @@ -1413,7 +1414,7 @@ self.__addManagementMessage( self.trUtf8("Who"), self.trUtf8("End of WHO list for {0}.").format( - match.group(1))) + match.group(1))) return True return False @@ -1488,7 +1489,7 @@ if channel.startswith(("*", "&")): adminChannels.append(channel[1:]) elif channel.startswith(("!", "~")) and \ - self.__ircWidget.isChannelName(channel[1:]): + self.__ircWidget.isChannelName(channel[1:]): ownerChannels.append(channel[1:]) elif channel.startswith("@+"): opChannels.append(channel[2:]) @@ -1506,32 +1507,32 @@ self.__addManagementMessage( self.trUtf8("Whois"), self.trUtf8("{0} is a user on channels: {1}").format( - match.group(1), " ".join(userChannels))) + match.group(1), " ".join(userChannels))) if voiceChannels: self.__addManagementMessage( self.trUtf8("Whois"), self.trUtf8("{0} has voice on channels: {1}").format( - match.group(1), " ".join(voiceChannels))) + match.group(1), " ".join(voiceChannels))) if halfopChannels: self.__addManagementMessage( self.trUtf8("Whois"), self.trUtf8("{0} is a halfop on channels: {1}").format( - match.group(1), " ".join(halfopChannels))) + match.group(1), " ".join(halfopChannels))) if opChannels: self.__addManagementMessage( self.trUtf8("Whois"), self.trUtf8("{0} is an operator on channels: {1}").format( - match.group(1), " ".join(opChannels))) + match.group(1), " ".join(opChannels))) if ownerChannels: self.__addManagementMessage( self.trUtf8("Whois"), self.trUtf8("{0} is owner of channels: {1}").format( - match.group(1), " ".join(ownerChannels))) + match.group(1), " ".join(ownerChannels))) if adminChannels: self.__addManagementMessage( self.trUtf8("Whois"), self.trUtf8("{0} is admin on channels: {1}").format( - match.group(1), " ".join(adminChannels))) + match.group(1), " ".join(adminChannels))) return True return False @@ -1618,19 +1619,22 @@ secondsString = self.trUtf8("%n second(s)", "", seconds) self.__addManagementMessage( self.trUtf8("Whois"), - self.trUtf8("{0} has been idle for {1}, {2}, and {3}.", - "{0} = name of person, {1} = (x hours), " - "{2} = (x minutes), {3} = (x seconds)").format( - match.group(1), hoursString, minutesString, secondsString)) + self.trUtf8( + "{0} has been idle for {1}, {2}, and {3}.", + "{0} = name of person, {1} = (x hours), " + "{2} = (x minutes), {3} = (x seconds)") + .format(match.group(1), hoursString, minutesString, + secondsString)) elif minutes: minutesString = self.trUtf8("%n minute(s)", "", minutes) secondsString = self.trUtf8("%n second(s)", "", seconds) self.__addManagementMessage( self.trUtf8("Whois"), - self.trUtf8("{0} has been idle for {1} and {2}.", - "{0} = name of person, {1} = (x minutes), " - "{3} = (x seconds)").format( - match.group(1), minutesString, secondsString)) + self.trUtf8( + "{0} has been idle for {1} and {2}.", + "{0} = name of person, {1} = (x minutes), " + "{3} = (x seconds)") + .format(match.group(1), minutesString, secondsString)) else: self.__addManagementMessage( self.trUtf8("Whois"), @@ -1642,8 +1646,8 @@ self.__addManagementMessage( self.trUtf8("Whois"), self.trUtf8("{0} has been online since {1}.").format( - match.group(1), - signonTime.toString("yyyy-MM-dd, hh:mm:ss"))) + match.group(1), + signonTime.toString("yyyy-MM-dd, hh:mm:ss"))) return True return False @@ -1772,7 +1776,7 @@ self.__addManagementMessage( self.trUtf8("Whois"), self.trUtf8("{0} is connecting from {1} (IP: {2}).").format( - match.group(1), match.group(2), match.group(3))) + match.group(1), match.group(2), match.group(3))) return True return False
--- a/Network/IRC/IrcIdentitiesEditDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Network/IRC/IrcIdentitiesEditDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -325,7 +325,7 @@ for networkName in self.__manager.getNetworkNames(): inUse = ( self.__manager.getNetwork(networkName).getIdentityName() == - currentIdentity) + currentIdentity) if inUse: break
--- a/Network/IRC/IrcNetworkEditDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Network/IRC/IrcNetworkEditDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -186,7 +186,7 @@ self.trUtf8("Delete Channel"), self.trUtf8( """Do you really want to delete channel <b>{0}</b>?""") - .format(itm.text(0))) + .format(itm.text(0))) if res: self.__network.deleteChannel(itm.text(0))
--- a/Network/IRC/IrcNetworkListDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Network/IRC/IrcNetworkListDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -81,7 +81,7 @@ if identityName == IrcIdentity.DefaultIdentityName: identityName = IrcIdentity.DefaultIdentityDisplay autoConnect = self.trUtf8("Yes") if network.autoConnect() \ - else self.trUtf8("No") + else self.trUtf8("No") QTreeWidgetItem( itm, @@ -163,7 +163,7 @@ self.trUtf8("Delete Irc Network"), self.trUtf8( """Do you really want to delete IRC network <b>{0}</b>?""") - .format(networkName)) + .format(networkName)) if res: index = self.networksList.indexOfTopLevelItem(itm) self.networksList.takeTopLevelItem(index)
--- a/Network/IRC/IrcNetworkWidget.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Network/IRC/IrcNetworkWidget.py Sat Oct 19 15:15:50 2013 +0200 @@ -373,7 +373,7 @@ "", self.trUtf8( "HTML Files (*.{0});;Text Files (*.txt);;All Files (*)") - .format(htmlExtension), + .format(htmlExtension), None, E5FileDialog.Options(E5FileDialog.DontConfirmOverwrite)) if fname: @@ -409,7 +409,7 @@ self.trUtf8( """<p>The messages contents could not be written""" """ to <b>{0}</b></p><p>Reason: {1}</p>""") - .format(fname, str(err))) + .format(fname, str(err))) def __initMessagesMenu(self): """
--- a/Network/IRC/IrcUtilities.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Network/IRC/IrcUtilities.py Sat Oct 19 15:15:50 2013 +0200 @@ -113,8 +113,8 @@ tag = '<span style="background-color:{0};color={1}">'\ .format(Preferences.getIrc( "IrcColor{0}".format(int(colors[0]))), - Preferences.getIrc( - "IrcColor{0}".format(int(colors[1])))) + Preferences.getIrc( + "IrcColor{0}".format(int(colors[1])))) else: # background only tag = '<span style="background-color:{0}">'.format(
--- a/Network/IRC/IrcWidget.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Network/IRC/IrcWidget.py Sat Oct 19 15:15:50 2013 +0200 @@ -238,7 +238,7 @@ self.trUtf8("""<p>Do you really want to disconnect from""" """ <b>{0}</b>?</p><p>All channels will be""" """ closed.</p>""") - .format(self.__server.getName())) + .format(self.__server.getName())) if ok: self.networkWidget.addServerMessage( self.trUtf8("Info"), @@ -594,7 +594,7 @@ else: self.networkWidget.addMessage( self.trUtf8("User {0} is now known as {1}.").format( - oldNick, newNick)) + oldNick, newNick)) return True elif name == "ERROR": self.networkWidget.addErrorMessage( @@ -669,18 +669,18 @@ parts = message.strip().split() message = self.trUtf8( "Server {0} (Version {1}), User-Modes: {2}," - " Channel-Modes: {3}").format( - parts[1], parts[2], parts[3], parts[4]) + " Channel-Modes: {3}")\ + .format(parts[1], parts[2], parts[3], parts[4]) elif code == 265: parts = message.strip().split() message = self.trUtf8( "Current users on {0}: {1}, max. {2}").format( - server, parts[1], parts[2]) + server, parts[1], parts[2]) elif code == 266: parts = message.strip().split() message = self.trUtf8( "Current users on the network: {0}, max. {1}").format( - parts[1], parts[2]) + parts[1], parts[2]) elif code == 305: message = self.trUtf8("You are no longer marked as being away.") elif code == 306: @@ -795,8 +795,8 @@ """Could not connect to {0} (port {1}) using an SSL""" """ encrypted connection. Either the server does not""" """ support SSL (did you use the correct port?) or""" - """ you rejected the certificate.""").format( - self.__server.getName(), self.__server.getPort())) + """ you rejected the certificate.""") + .format(self.__server.getName(), self.__server.getPort())) self.__socket.close() else: if defaultChanged: @@ -808,8 +808,8 @@ self.trUtf8( """The SSL certificate for the server {0} (port {1})""" """ failed the authenticity check. SSL errors""" - """ were accepted by you.""").format( - self.__server.getName(), self.__server.getPort())) + """ were accepted by you.""") + .format(self.__server.getName(), self.__server.getPort())) if self.__connectionState == IrcWidget.ServerConnecting: self.__socket.ignoreSslErrors() @@ -887,8 +887,8 @@ self.networkWidget.addServerMessage( self.trUtf8("CTCP"), self.trUtf8( - "Received unknown CTCP-{0} request from {1}.").format( - ctcpRequest, match.group(1))) + "Received unknown CTCP-{0} request from {1}.") + .format(ctcpRequest, match.group(1))) return True return False @@ -902,7 +902,7 @@ self.channelsWidget.setTabText( index, self.trUtf8("{0} ({1})", "channel name, users count").format( - channel.name(), channel.getUsersCount())) + channel.name(), channel.getUsersCount())) def __handleNickInUseLogin(self): """ @@ -918,8 +918,8 @@ self.trUtf8("Critical"), self.trUtf8( "No nickname acceptable to the server configured" - " for <b>{0}</b>. Disconnecting...").format( - self.__userName), + " for <b>{0}</b>. Disconnecting...") + .format(self.__userName), filterMsg=False) self.__connectNetwork("", False, silent=True) self.__nickName = ""
--- a/PluginManager/PluginInstallDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/PluginManager/PluginInstallDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -143,7 +143,7 @@ self.destinationCombo.currentText(), self.destinationCombo.itemData( self.destinationCombo.currentIndex()) - ) + ) self.summaryEdit.setPlainText(msg) @pyqtSlot() @@ -345,7 +345,7 @@ self.trUtf8( """<p>The plugin module <b>{0}</b> does not contain """ """a 'packageName' attribute. Aborting...</p>""")\ - .format(pluginFileName), \ + .format(pluginFileName), \ False if pyqtApi < 2: @@ -353,7 +353,7 @@ self.trUtf8( """<p>The plugin module <b>{0}</b> does not conform""" """ with the PyQt v2 API. Aborting...</p>""")\ - .format(pluginFileName), \ + .format(pluginFileName), \ False # check, if it is a plugin, that collides with others
--- a/PluginManager/PluginManager.py Sat Oct 19 14:05:26 2013 +0200 +++ b/PluginManager/PluginManager.py Sat Oct 19 15:15:50 2013 +0200 @@ -80,7 +80,7 @@ self.pluginDirs = { "eric5": os.path.join(getConfig('ericDir'), "Plugins"), "global": os.path.join(Utilities.getPythonModulesDirectory(), - "eric5plugins"), + "eric5plugins"), "user": os.path.join(Utilities.getConfigDir(), "eric5plugins"), } self.__priorityOrder = ["eric5", "global", "user"] @@ -123,7 +123,7 @@ Public method to finalize the setup of the plugin manager. """ for module in list(self.__onDemandInactiveModules.values()) + \ - list(self.__onDemandActiveModules.values()): + list(self.__onDemandActiveModules.values()): if hasattr(module, "moduleSetup"): module.moduleSetup() @@ -769,7 +769,7 @@ for name, module in \ list(self.__onDemandActiveModules.items()) + \ - list(self.__onDemandInactiveModules.items()): + list(self.__onDemandInactiveModules.items()): if getattr(module, "pluginType") == type_ and \ getattr(module, "error", "") == "": plugin_name = getattr(module, "pluginTypename") @@ -795,7 +795,7 @@ """ for modname, module in \ list(self.__onDemandActiveModules.items()) + \ - list(self.__onDemandInactiveModules.items()): + list(self.__onDemandInactiveModules.items()): if getattr(module, "pluginType") == type_ and \ getattr(module, "pluginTypename") == name: if hasattr(module, "previewPix"): @@ -815,7 +815,7 @@ apis = [] for module in list(self.__activeModules.values()) + \ - list(self.__onDemandActiveModules.values()): + list(self.__onDemandActiveModules.values()): if hasattr(module, "apiFiles"): apis.extend(module.apiFiles(language)) @@ -858,13 +858,13 @@ infos = [] for module in list(self.__activeModules.values()) + \ - list(self.__inactiveModules.values()): + list(self.__inactiveModules.values()): if hasattr(module, "exeDisplayDataList"): infos.extend(module.exeDisplayDataList()) elif hasattr(module, "exeDisplayData"): infos.append(module.exeDisplayData()) for module in list(self.__onDemandActiveModules.values()) + \ - list(self.__onDemandInactiveModules.values()): + list(self.__onDemandInactiveModules.values()): if hasattr(module, "exeDisplayDataList"): infos.extend(module.exeDisplayDataList()) elif hasattr(module, "exeDisplayData"): @@ -906,8 +906,8 @@ """ configData = {} for module in list(self.__activeModules.values()) + \ - list(self.__onDemandActiveModules.values()) + \ - list(self.__onDemandInactiveModules.values()): + list(self.__onDemandActiveModules.values()) + \ + list(self.__onDemandInactiveModules.values()): if hasattr(module, 'getConfigData'): configData.update(module.getConfigData()) return configData @@ -920,9 +920,9 @@ @return flag indicating, if the plugin is loaded (boolean) """ return pluginName in self.__activeModules or \ - pluginName in self.__inactiveModules or \ - pluginName in self.__onDemandActiveModules or \ - pluginName in self.__onDemandInactiveModules + pluginName in self.__inactiveModules or \ + pluginName in self.__onDemandActiveModules or \ + pluginName in self.__onDemandInactiveModules def isPluginActive(self, pluginName): """ @@ -932,7 +932,7 @@ @return flag indicating, if the plugin is active (boolean) """ return pluginName in self.__activeModules or \ - pluginName in self.__onDemandActiveModules + pluginName in self.__onDemandActiveModules ########################################################################### ## Specialized plugin module handling methods below @@ -958,7 +958,7 @@ for name, module in \ list(self.__onDemandActiveModules.items()) + \ - list(self.__onDemandInactiveModules.items()): + list(self.__onDemandInactiveModules.items()): if getattr(module, "pluginType") == "version_control": if hasattr(module, "getVcsSystemIndicator"): res = module.getVcsSystemIndicator() @@ -1005,7 +1005,7 @@ """ <b>{0}</b> could not be created. Please""" """ configure it via the configuration""" """ dialog.</p><p>Reason: {1}</p>""") - .format(downloadDir, str(err))) + .format(downloadDir, str(err))) downloadDir = "" Preferences.setPluginManager("DownloadPath", downloadDir)
--- a/PluginManager/PluginRepositoryDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/PluginManager/PluginRepositoryDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -336,14 +336,14 @@ self.trUtf8("Read plugins repository file"), self.trUtf8("<p>The plugins repository file <b>{0}</b> " "could not be read. Select Update</p>") - .format(self.pluginRepositoryFile)) + .format(self.pluginRepositoryFile)) else: self.__repositoryMissing = True QTreeWidgetItem( self.repositoryList, ["", self.trUtf8( "No plugin repository file available.\nSelect Update.") - ]) + ]) self.repositoryList.resizeColumnToContents(1) def __downloadFile(self, url, filename, doneMethod=None):
--- a/PluginManager/PluginUninstallDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/PluginManager/PluginUninstallDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -69,8 +69,7 @@ @param index index of the selected item (integer) """ - pluginDirectory = self.pluginDirectoryCombo\ - .itemData(index) + pluginDirectory = self.pluginDirectoryCombo.itemData(index) pluginNames = sorted(self.__pluginManager.getPluginModules( pluginDirectory)) self.pluginNameCombo.clear() @@ -95,10 +94,10 @@ @return flag indicating success (boolean) """ pluginDirectory = self.pluginDirectoryCombo\ - .itemData(self.pluginDirectoryCombo.currentIndex()) + .itemData(self.pluginDirectoryCombo.currentIndex()) pluginName = self.pluginNameCombo.currentText() pluginFile = self.pluginNameCombo\ - .itemData(self.pluginNameCombo.currentIndex()) + .itemData(self.pluginNameCombo.currentIndex()) if not self.__pluginManager.unloadPlugin(pluginName): E5MessageBox.critical( @@ -193,7 +192,7 @@ self.trUtf8( """<p>The plugin <b>{0}</b> was uninstalled successfully""" """ from {1}.</p>""") - .format(pluginName, pluginDirectory)) + .format(pluginName, pluginDirectory)) return True
--- a/Plugins/AboutPlugin/AboutDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/AboutPlugin/AboutDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -725,7 +725,8 @@ Program, unless a warranty or assumption of liability accompanies a copy of the Program in return for a fee. - END OF TERMS AND CONDITIONS""".format(UI.Info.Copyright) + END OF TERMS AND CONDITIONS""" \ +.format(UI.Info.Copyright) # __IGNORE_WARNING__ class AboutDialog(QDialog, Ui_AboutDialog):
--- a/Plugins/CheckerPlugins/CodeStyleChecker/CodeStyleChecker.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/CheckerPlugins/CodeStyleChecker/CodeStyleChecker.py Sat Oct 19 15:15:50 2013 +0200 @@ -52,8 +52,7 @@ interpreter = Preferences.getDebugger("PythonInterpreter") if interpreter == "" or not Utilities.isExecutable(interpreter): self.errors.append( - (filename, 1, 1, - QCoreApplication.translate( + (filename, 1, 1, QCoreApplication.translate( "CodeStyleCheckerPy2", "Python2 interpreter not configured."))) return @@ -86,8 +85,8 @@ if finished: output = \ str(proc.readAllStandardOutput(), - Preferences.getSystem("IOEncoding"), - 'replace').splitlines() + Preferences.getSystem("IOEncoding"), + 'replace').splitlines() if output[0] == "ERROR": self.errors.append((filename, 1, 1, output[2])) return @@ -126,7 +125,6 @@ index += 1 else: self.errors.append( - (filename, 1, 1, - QCoreApplication.translate( + (filename, 1, 1, QCoreApplication.translate( "CodeStyleCheckerPy2", "Python2 interpreter did not finish within 15s.")))
--- a/Plugins/CheckerPlugins/CodeStyleChecker/CodeStyleCheckerDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/CheckerPlugins/CodeStyleChecker/CodeStyleCheckerDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -130,7 +130,7 @@ """ self.resultList.sortItems(self.resultList.sortColumn(), self.resultList.header().sortIndicatorOrder() - ) + ) def __createResultItem(self, file, line, pos, message, fixed, autofixing): """ @@ -399,7 +399,7 @@ self.__createResultItem( file, "1", "1", self.trUtf8("Error: {0}").format(str(msg)) - .rstrip()[1:-1], False, False) + .rstrip()[1:-1], False, False) progress += 1 continue
--- a/Plugins/CheckerPlugins/CodeStyleChecker/DocStyleChecker.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/CheckerPlugins/CodeStyleChecker/DocStyleChecker.py Sat Oct 19 15:15:50 2013 +0200 @@ -707,7 +707,7 @@ endLine = classContext.start() + end[0] contexts.append(DocStyleContext( self.__source[startLine:endLine], - startLine, "def")) + startLine, "def")) except StopIteration: pass self.__methodsCache = contexts
--- a/Plugins/CheckerPlugins/SyntaxChecker/SyntaxCheckerDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/CheckerPlugins/SyntaxChecker/SyntaxCheckerDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -66,7 +66,7 @@ """ self.resultList.sortItems(self.resultList.sortColumn(), self.resultList.header().sortIndicatorOrder() - ) + ) def __createResultItem(self, file, line, index, error, sourcecode, isWarning=False): @@ -192,7 +192,7 @@ self.__createResultItem( file, "1", 0, self.trUtf8("Error: {0}").format(str(msg)) - .rstrip()[1:-1], "") + .rstrip()[1:-1], "") progress += 1 continue
--- a/Plugins/CheckerPlugins/Tabnanny/Tabnanny.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/CheckerPlugins/Tabnanny/Tabnanny.py Sat Oct 19 15:15:50 2013 +0200 @@ -267,8 +267,8 @@ for ts in range(1, n + 1): if self.indent_level(ts) != other.indent_level(ts): a.append((ts, - self.indent_level(ts), - other.indent_level(ts))) + self.indent_level(ts), + other.indent_level(ts))) return a # Return True iff self.indent_level(t) < other.indent_level(t) @@ -325,8 +325,8 @@ for ts in range(1, n + 1): if self.indent_level(ts) >= other.indent_level(ts): a.append((ts, - self.indent_level(ts), - other.indent_level(ts))) + self.indent_level(ts), + other.indent_level(ts))) return a
--- a/Plugins/CheckerPlugins/Tabnanny/TabnannyDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/CheckerPlugins/Tabnanny/TabnannyDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -276,10 +276,9 @@ proc.start(interpreter, [checker, filename]) finished = proc.waitForFinished(15000) if finished: - output = \ - str(proc.readAllStandardOutput(), - Preferences.getSystem("IOEncoding"), - 'replace').splitlines() + output = str(proc.readAllStandardOutput(), + Preferences.getSystem("IOEncoding"), + 'replace').splitlines() nok = output[0] == "ERROR" if nok:
--- a/Plugins/PluginAbout.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/PluginAbout.py Sat Oct 19 15:15:50 2013 +0200 @@ -83,7 +83,7 @@ self.aboutAct.setWhatsThis(self.trUtf8( """<b>About {0}</b>""" """<p>Display some information about this software.</p>""" - ).format(UI.Info.Program)) + ).format(UI.Info.Program)) self.aboutAct.triggered[()].connect(self.__about) self.aboutAct.setMenuRole(QAction.AboutRole) acts.append(self.aboutAct)
--- a/Plugins/PluginEricapi.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/PluginEricapi.py Sat Oct 19 15:15:50 2013 +0200 @@ -30,8 +30,8 @@ packageName = "__core__" shortDescription = "Show the Ericapi dialogs." longDescription = """This plugin implements the Ericapi dialogs.""" \ - """ Ericapi is used to generate a QScintilla API file for Python and Ruby"""\ - """ projects.""" + """ Ericapi is used to generate a QScintilla API file for Python and""" \ + """ Ruby projects.""" pyqtApi = 2 # End-Of-Header @@ -135,7 +135,7 @@ if self.__projectAct is not None: self.__projectAct.setEnabled( e5App().getObject("Project").getProjectLanguage() in - ["Python", "Python2", "Python3", "Ruby"]) + ["Python", "Python2", "Python3", "Ruby"]) def __doEricapi(self): """
--- a/Plugins/PluginEricdoc.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/PluginEricdoc.py Sat Oct 19 15:15:50 2013 +0200 @@ -30,8 +30,8 @@ packageName = "__core__" shortDescription = "Show the Ericdoc dialogs." longDescription = """This plugin implements the Ericdoc dialogs.""" \ - """ Ericdoc is used to generate a source code documentation""" \ - """ for Python and Ruby projects.""" + """ Ericdoc is used to generate a source code documentation""" \ + """ for Python and Ruby projects.""" pyqtApi = 2 # End-Of-Header @@ -170,7 +170,7 @@ if self.__projectAct is not None: self.__projectAct.setEnabled( e5App().getObject("Project").getProjectLanguage() in - ["Python", "Python2", "Python3", "Ruby"]) + ["Python", "Python2", "Python3", "Ruby"]) def __doEricdoc(self): """
--- a/Plugins/PluginSyntaxChecker.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/PluginSyntaxChecker.py Sat Oct 19 15:15:50 2013 +0200 @@ -27,7 +27,8 @@ packageName = "__core__" shortDescription = "Show the Syntax Checker dialog." longDescription = """This plugin implements the Syntax Checker dialog.""" \ - """ Syntax Checker is used to check Python source files for correct syntax.""" + """ Syntax Checker is used to check Python source files for correct""" \ + """ syntax.""" pyqtApi = 2 # End-Of-Header @@ -90,8 +91,8 @@ self.trUtf8('&Syntax...'), 0, 0, self, "") self.__editorAct.setWhatsThis(self.trUtf8( - """<b>Check Syntax...</b>""" - """<p>This checks Python files for syntax errors.</p>""" + """<b>Check Syntax...</b>""" + """<p>This checks Python files for syntax errors.</p>""" )) self.__editorAct.triggered[()].connect(self.__editorSyntaxCheck) @@ -149,7 +150,7 @@ if menuName == "Checks" and self.__projectAct is not None: self.__projectAct.setEnabled( e5App().getObject("Project").getProjectLanguage() in - ["Python3", "Python2", "Python"]) + ["Python3", "Python2", "Python"]) def __projectBrowserShowMenu(self, menuName, menu): """ @@ -187,8 +188,8 @@ files = [os.path.join(ppath, file) for file in project.pdata["SOURCES"] if file.endswith( - tuple(Preferences.getPython("Python3Extensions")) + - tuple(Preferences.getPython("PythonExtensions")))] + tuple(Preferences.getPython("Python3Extensions")) + + tuple(Preferences.getPython("PythonExtensions")))] from CheckerPlugins.SyntaxChecker.SyntaxCheckerDialog import \ SyntaxCheckerDialog
--- a/Plugins/PluginTabnanny.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/PluginTabnanny.py Sat Oct 19 15:15:50 2013 +0200 @@ -27,7 +27,8 @@ packageName = "__core__" shortDescription = "Show the Tabnanny dialog." longDescription = """This plugin implements the Tabnanny dialog.""" \ - """ Tabnanny is used to check Python source files for correct indentations.""" + """ Tabnanny is used to check Python source files for correct""" \ + """ indentations.""" pyqtApi = 2 # End-Of-Header @@ -151,7 +152,7 @@ if menuName == "Checks" and self.__projectAct is not None: self.__projectAct.setEnabled( e5App().getObject("Project").getProjectLanguage() in - ["Python3", "Python2", "Python"]) + ["Python3", "Python2", "Python"]) def __projectBrowserShowMenu(self, menuName, menu): """ @@ -190,8 +191,8 @@ files = [os.path.join(ppath, file) for file in project.pdata["SOURCES"] if file.endswith( - tuple(Preferences.getPython("Python3Extensions")) + - tuple(Preferences.getPython("PythonExtensions")))] + tuple(Preferences.getPython("Python3Extensions")) + + tuple(Preferences.getPython("PythonExtensions")))] from CheckerPlugins.Tabnanny.TabnannyDialog import TabnannyDialog self.__projectTabnannyDialog = TabnannyDialog()
--- a/Plugins/PluginVcsMercurial.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/PluginVcsMercurial.py Sat Oct 19 15:15:50 2013 +0200 @@ -126,10 +126,10 @@ """ return { "zzz_mercurialPage": - [QApplication.translate("VcsMercurialPlugin", "Mercurial"), - os.path.join("VcsPlugins", "vcsMercurial", "icons", - "preferences-mercurial.png"), - createConfigurationPage, "vcsPage", None], + [QApplication.translate("VcsMercurialPlugin", "Mercurial"), + os.path.join("VcsPlugins", "vcsMercurial", "icons", + "preferences-mercurial.png"), + createConfigurationPage, "vcsPage", None], }
--- a/Plugins/PluginVcsPySvn.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/PluginVcsPySvn.py Sat Oct 19 15:15:50 2013 +0200 @@ -120,10 +120,10 @@ """ return { "zzz_subversionPage": - [QApplication.translate("VcsPySvnPlugin", "Subversion"), - os.path.join("VcsPlugins", "vcsPySvn", "icons", - "preferences-subversion.png"), - createConfigurationPage, "vcsPage", None], + [QApplication.translate("VcsPySvnPlugin", "Subversion"), + os.path.join("VcsPlugins", "vcsPySvn", "icons", + "preferences-subversion.png"), + createConfigurationPage, "vcsPage", None], }
--- a/Plugins/PluginVcsSubversion.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/PluginVcsSubversion.py Sat Oct 19 15:15:50 2013 +0200 @@ -127,10 +127,10 @@ """ return { "zzz_subversionPage": - [QApplication.translate("VcsSubversionPlugin", "Subversion"), - os.path.join("VcsPlugins", "vcsSubversion", "icons", - "preferences-subversion.png"), - createConfigurationPage, "vcsPage", None], + [QApplication.translate("VcsSubversionPlugin", "Subversion"), + os.path.join("VcsPlugins", "vcsSubversion", "icons", + "preferences-subversion.png"), + createConfigurationPage, "vcsPage", None], }
--- a/Plugins/PluginWizardE5MessageBox.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/PluginWizardE5MessageBox.py Sat Oct 19 15:15:50 2013 +0200 @@ -69,8 +69,8 @@ """ self.action = E5Action( self.trUtf8('E5MessageBox Wizard'), - self.trUtf8('&E5MessageBox Wizard...'), 0, 0, self, - 'wizards_e5messagebox') + self.trUtf8('&E5MessageBox Wizard...'), 0, 0, self, + 'wizards_e5messagebox') self.action.setStatusTip(self.trUtf8('E5MessageBox Wizard')) self.action.setWhatsThis(self.trUtf8( """<b>E5MessageBox Wizard</b>"""
--- a/Plugins/VcsPlugins/vcsMercurial/BookmarksExtension/bookmarks.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/BookmarksExtension/bookmarks.py Sat Oct 19 15:15:50 2013 +0200 @@ -317,7 +317,7 @@ args.append(bookmark) dia = HgDialog(self.trUtf8( - 'Pulling bookmark from a remote Mercurial repository'), + 'Pulling bookmark from a remote Mercurial repository'), self.vcs) res = dia.startProcess(args, repodir) if res: @@ -351,7 +351,7 @@ args.append(bookmark) dia = HgDialog(self.trUtf8( - 'Pushing bookmark to a remote Mercurial repository'), + 'Pushing bookmark to a remote Mercurial repository'), self.vcs) res = dia.startProcess(args, repodir) if res:
--- a/Plugins/VcsPlugins/vcsMercurial/HgBackoutDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/HgBackoutDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -178,4 +178,4 @@ date, self.userEdit.text(), msg - ) + )
--- a/Plugins/VcsPlugins/vcsMercurial/HgClient.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/HgClient.py Sat Oct 19 15:15:50 2013 +0200 @@ -81,9 +81,9 @@ serverStarted = self.__server.waitForStarted(5000) if not serverStarted: return False, self.trUtf8( - 'The process {0} could not be started. ' - 'Ensure, that it is in the search path.' - ).format('hg') + 'The process {0} could not be started. ' + 'Ensure, that it is in the search path.' + ).format('hg') self.__server.setReadChannel(QProcess.StandardOutput) ok, error = self.__readHello()
--- a/Plugins/VcsPlugins/vcsMercurial/HgDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/HgDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -120,7 +120,7 @@ "transplant", "update", "import", "revert", "graft"] or \ (args[0] in ["pull", "unbundle"] and - ("--update" in args[1:] or "--rebase" in args[1:])): + ("--update" in args[1:] or "--rebase" in args[1:])): self.__updateCommand = True else: self.__updateCommand = False
--- a/Plugins/VcsPlugins/vcsMercurial/HgDiffDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/HgDiffDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -313,8 +313,8 @@ while self.process.canReadLine(): line = str(self.process.readLine(), - Preferences.getSystem("IOEncoding"), - 'replace') + Preferences.getSystem("IOEncoding"), + 'replace') self.__processOutputLine(line) def __readStderr(self): @@ -441,7 +441,7 @@ self.trUtf8( '<p>The patch file <b>{0}</b> could not be saved.' '<br>Reason: {1}</p>') - .format(fname, str(why))) + .format(fname, str(why))) def on_passwordCheckBox_toggled(self, isOn): """
--- a/Plugins/VcsPlugins/vcsMercurial/HgLogBrowserDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/HgLogBrowserDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -10,7 +10,7 @@ import os from PyQt4.QtCore import pyqtSlot, Qt, QDate, QProcess, QTimer, QRegExp, \ - QSize, QPoint + QSize, QPoint from PyQt4.QtGui import QDialog, QDialogButtonBox, QHeaderView, \ QTreeWidgetItem, QApplication, QCursor, QLineEdit, QColor, \ QPixmap, QPainter, QPen, QBrush, QIcon @@ -933,8 +933,8 @@ while self.process.canReadLine(): line = str(self.process.readLine(), - Preferences.getSystem("IOEncoding"), - 'replace') + Preferences.getSystem("IOEncoding"), + 'replace') self.buf.append(line) def __readStderr(self): @@ -946,8 +946,8 @@ """ if self.process is not None: s = str(self.process.readAllStandardError(), - Preferences.getSystem("IOEncoding"), - 'replace') + Preferences.getSystem("IOEncoding"), + 'replace') self.__showError(s) def __showError(self, out): @@ -1042,7 +1042,7 @@ # step 2: set the status of the phase button if public == 0 and \ ((secret > 0 and draft == 0) or - (secret == 0 and draft > 0)): + (secret == 0 and draft > 0)): self.phaseButton.setEnabled(True) else: self.phaseButton.setEnabled(False)
--- a/Plugins/VcsPlugins/vcsMercurial/HgLogDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/HgLogDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -356,19 +356,19 @@ Utilities.html_encode(fileCopies[f])) else: html += self.trUtf8('Added {0}<br />\n')\ - .format(Utilities.html_encode(f)) + .format(Utilities.html_encode(f)) if entry["files_mods"]: html += '<br />\n' for f in entry["files_mods"].strip().split(", "): html += self.trUtf8('Modified {0}<br />\n')\ - .format(Utilities.html_encode(f)) + .format(Utilities.html_encode(f)) if entry["file_dels"]: html += '<br />\n' for f in entry["file_dels"].strip().split(", "): html += self.trUtf8('Deleted {0}<br />\n')\ - .format(Utilities.html_encode(f)) + .format(Utilities.html_encode(f)) html += '</p>{0}<br/>\n'.format(80 * "=") @@ -388,8 +388,8 @@ while self.process.canReadLine(): s = str(self.process.readLine(), - Preferences.getSystem("IOEncoding"), - 'replace') + Preferences.getSystem("IOEncoding"), + 'replace') self.__processOutputLine(s) def __processOutputLine(self, line): @@ -411,8 +411,8 @@ if key == "change": self.endInitialText = True if key in ("change", "branches", "tags", "parents", "user", - "date", "file_copies", "file_adds", "files_mods", - "file_dels", "bookmarks", "phase"): + "date", "file_copies", "file_adds", "files_mods", + "file_dels", "bookmarks", "phase"): self.lastLogEntry[key] = value.strip() elif key == "description": self.lastLogEntry[key] = [value.strip()] @@ -431,8 +431,8 @@ """ if self.process is not None: s = str(self.process.readAllStandardError(), - Preferences.getSystem("IOEncoding"), - 'replace') + Preferences.getSystem("IOEncoding"), + 'replace') self.__showError(s) def __showError(self, out):
--- a/Plugins/VcsPlugins/vcsMercurial/HgMultiRevisionSelectionDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/HgMultiRevisionSelectionDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -15,7 +15,7 @@ class HgMultiRevisionSelectionDialog( - QDialog, Ui_HgMultiRevisionSelectionDialog): + QDialog, Ui_HgMultiRevisionSelectionDialog): """ Class implementing a dialog to select revisions. """
--- a/Plugins/VcsPlugins/vcsMercurial/HgNewProjectOptionsDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/HgNewProjectOptionsDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -53,8 +53,9 @@ self.networkPath = "localhost/" self.localProtocol = True - self.vcsProjectDirEdit.setText(Utilities.toNativeSeparators( - Preferences.getMultiProject("Workspace") or + self.vcsProjectDirEdit.setText( + Utilities.toNativeSeparators( + Preferences.getMultiProject("Workspace") or Utilities.getHomeDir())) @pyqtSlot()
--- a/Plugins/VcsPlugins/vcsMercurial/HgServeDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/HgServeDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -193,8 +193,8 @@ """ if self.process is not None: s = str(self.process.readAllStandardOutput(), - Preferences.getSystem("IOEncoding"), - 'replace') + Preferences.getSystem("IOEncoding"), + 'replace') self.__appendText(s, False) def __readStderr(self): @@ -205,8 +205,8 @@ """ if self.process is not None: s = str(self.process.readAllStandardError(), - Preferences.getSystem("IOEncoding"), - 'replace') + Preferences.getSystem("IOEncoding"), + 'replace') self.__appendText(s, True) def __appendText(self, txt, error=False):
--- a/Plugins/VcsPlugins/vcsMercurial/HgStatusMonitorThread.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/HgStatusMonitorThread.py Sat Oct 19 15:15:50 2013 +0200 @@ -154,7 +154,7 @@ self.reportedStates = states return True, \ - self.trUtf8("Mercurial status checked successfully") + self.trUtf8("Mercurial status checked successfully") def _shutdown(self): """
--- a/Plugins/VcsPlugins/vcsMercurial/ProjectBrowserHelper.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/ProjectBrowserHelper.py Sat Oct 19 15:15:50 2013 +0200 @@ -267,13 +267,13 @@ self.vcsMenuActions.append(act) menu.addSeparator() menu.addAction(self.trUtf8('Select all local file entries'), - self.browser.selectLocalEntries) + self.browser.selectLocalEntries) menu.addAction(self.trUtf8('Select all versioned file entries'), - self.browser.selectVCSEntries) + self.browser.selectVCSEntries) menu.addAction(self.trUtf8('Select all local directory entries'), - self.browser.selectLocalDirEntries) + self.browser.selectLocalDirEntries) menu.addAction(self.trUtf8('Select all versioned directory entries'), - self.browser.selectVCSDirEntries) + self.browser.selectVCSDirEntries) menu.addSeparator() mainMenu.addSeparator() @@ -347,13 +347,13 @@ self.vcsMultiMenuActions.append(act) menu.addSeparator() menu.addAction(self.trUtf8('Select all local file entries'), - self.browser.selectLocalEntries) + self.browser.selectLocalEntries) menu.addAction(self.trUtf8('Select all versioned file entries'), - self.browser.selectVCSEntries) + self.browser.selectVCSEntries) menu.addAction(self.trUtf8('Select all local directory entries'), - self.browser.selectLocalDirEntries) + self.browser.selectLocalDirEntries) menu.addAction(self.trUtf8('Select all versioned directory entries'), - self.browser.selectVCSDirEntries) + self.browser.selectVCSDirEntries) menu.addSeparator() mainMenu.addSeparator() @@ -379,13 +379,13 @@ menu.addSeparator() menu.addAction(self.trUtf8('Select all local file entries'), - self.browser.selectLocalEntries) + self.browser.selectLocalEntries) menu.addAction(self.trUtf8('Select all versioned file entries'), - self.browser.selectVCSEntries) + self.browser.selectVCSEntries) menu.addAction(self.trUtf8('Select all local directory entries'), - self.browser.selectLocalDirEntries) + self.browser.selectLocalDirEntries) menu.addAction(self.trUtf8('Select all versioned directory entries'), - self.browser.selectVCSDirEntries) + self.browser.selectVCSDirEntries) menu.addSeparator() mainMenu.addSeparator() @@ -470,13 +470,13 @@ self.vcsDirMenuActions.append(act) menu.addSeparator() menu.addAction(self.trUtf8('Select all local file entries'), - self.browser.selectLocalEntries) + self.browser.selectLocalEntries) menu.addAction(self.trUtf8('Select all versioned file entries'), - self.browser.selectVCSEntries) + self.browser.selectVCSEntries) menu.addAction(self.trUtf8('Select all local directory entries'), - self.browser.selectLocalDirEntries) + self.browser.selectLocalDirEntries) menu.addAction(self.trUtf8('Select all versioned directory entries'), - self.browser.selectVCSDirEntries) + self.browser.selectVCSDirEntries) menu.addSeparator() mainMenu.addSeparator() @@ -547,13 +547,13 @@ self.vcsDirMultiMenuActions.append(act) menu.addSeparator() menu.addAction(self.trUtf8('Select all local file entries'), - self.browser.selectLocalEntries) + self.browser.selectLocalEntries) menu.addAction(self.trUtf8('Select all versioned file entries'), - self.browser.selectVCSEntries) + self.browser.selectVCSEntries) menu.addAction(self.trUtf8('Select all local directory entries'), - self.browser.selectLocalDirEntries) + self.browser.selectLocalDirEntries) menu.addAction(self.trUtf8('Select all versioned directory entries'), - self.browser.selectVCSDirEntries) + self.browser.selectVCSDirEntries) menu.addSeparator() mainMenu.addSeparator()
--- a/Plugins/VcsPlugins/vcsMercurial/ProjectHelper.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/ProjectHelper.py Sat Oct 19 15:15:50 2013 +0200 @@ -319,10 +319,10 @@ self.actions.append(self.vcsStatusAct) self.hgSummaryAct = E5Action( - self.trUtf8('Show Summary'), - UI.PixmapCache.getIcon("vcsSummary.png"), - self.trUtf8('Show summary...'), - 0, 0, self, 'mercurial_summary') + self.trUtf8('Show Summary'), + UI.PixmapCache.getIcon("vcsSummary.png"), + self.trUtf8('Show summary...'), + 0, 0, self, 'mercurial_summary') self.hgSummaryAct.setStatusTip(self.trUtf8( 'Show summary information of the working directory status' ))
--- a/Plugins/VcsPlugins/vcsMercurial/QueuesExtension/HgQueuesDefineGuardsDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/QueuesExtension/HgQueuesDefineGuardsDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -313,7 +313,7 @@ self.trUtf8("Apply Guard Definitions"), self.trUtf8("""<p>The defined guards could not be""" """ applied.</p><p>Reason: {0}</p>""") - .format(error)) + .format(error)) else: self.__dirtyList = False self.on_patchSelector_activated(
--- a/Plugins/VcsPlugins/vcsMercurial/QueuesExtension/HgQueuesNewPatchDialog.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/QueuesExtension/HgQueuesNewPatchDialog.py Sat Oct 19 15:15:50 2013 +0200 @@ -58,7 +58,7 @@ enable = self.messageEdit.toPlainText() != "" else: enable = self.nameEdit.text() != "" and \ - self.messageEdit.toPlainText() != "" + self.messageEdit.toPlainText() != "" if self.userGroup.isChecked(): enable = enable and \ (self.currentUserCheckBox.isChecked() or
--- a/Plugins/VcsPlugins/vcsMercurial/QueuesExtension/queues.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/QueuesExtension/queues.py Sat Oct 19 15:15:50 2013 +0200 @@ -245,7 +245,7 @@ dlg = HgQueuesNewPatchDialog(HgQueuesNewPatchDialog.NEW_MODE) if dlg.exec_() == QDialog.Accepted: name, message, (userData, currentUser, userName), \ - (dateData, currentDate, dateStr) = dlg.getData() + (dateData, currentDate, dateStr) = dlg.getData() args = [] args.append("qnew") @@ -297,7 +297,7 @@ currentMessage) if dlg.exec_() == QDialog.Accepted: name, message, (userData, currentUser, userName), \ - (dateData, currentDate, dateStr) = dlg.getData() + (dateData, currentDate, dateStr) = dlg.getData() if message != "" and message != currentMessage: args.append("--message") args.append(message)
--- a/Plugins/VcsPlugins/vcsMercurial/RebaseExtension/ProjectHelper.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/RebaseExtension/ProjectHelper.py Sat Oct 19 15:15:50 2013 +0200 @@ -47,9 +47,9 @@ self.actions.append(self.hgRebaseAct) self.hgRebaseContinueAct = E5Action( - self.trUtf8('Continue Rebase Session'), - self.trUtf8('Continue Rebase Session'), - 0, 0, self, 'mercurial_rebase_continue') + self.trUtf8('Continue Rebase Session'), + self.trUtf8('Continue Rebase Session'), + 0, 0, self, 'mercurial_rebase_continue') self.hgRebaseContinueAct.setStatusTip(self.trUtf8( 'Continue the last rebase session after repair' )) @@ -61,9 +61,9 @@ self.actions.append(self.hgRebaseContinueAct) self.hgRebaseAbortAct = E5Action( - self.trUtf8('Abort Rebase Session'), - self.trUtf8('Abort Rebase Session'), - 0, 0, self, 'mercurial_rebase_abort') + self.trUtf8('Abort Rebase Session'), + self.trUtf8('Abort Rebase Session'), + 0, 0, self, 'mercurial_rebase_abort') self.hgRebaseAbortAct.setStatusTip(self.trUtf8( 'Abort the last rebase session' ))
--- a/Plugins/VcsPlugins/vcsMercurial/TransplantExtension/ProjectHelper.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/TransplantExtension/ProjectHelper.py Sat Oct 19 15:15:50 2013 +0200 @@ -63,9 +63,9 @@ self.actions.append(self.hgTransplantAct) self.hgTransplantContinueAct = E5Action( - self.trUtf8('Continue Transplant Session'), - self.trUtf8('Continue Transplant Session'), - 0, 0, self, 'mercurial_transplant_continue') + self.trUtf8('Continue Transplant Session'), + self.trUtf8('Continue Transplant Session'), + 0, 0, self, 'mercurial_transplant_continue') self.hgTransplantContinueAct.setStatusTip(self.trUtf8( 'Continue the last transplant session after repair' ))
--- a/Plugins/VcsPlugins/vcsMercurial/hg.py Sat Oct 19 14:05:26 2013 +0200 +++ b/Plugins/VcsPlugins/vcsMercurial/hg.py Sat Oct 19 15:15:50 2013 +0200 @@ -811,12 +811,12 @@ from .HgMultiRevisionSelectionDialog import \ HgMultiRevisionSelectionDialog dlg = HgMultiRevisionSelectionDialog( - self.hgGetTagsList(repodir), - self.hgGetBranchesList(repodir), - bookmarksList, - emptyRevsOk=True, - showLimit=True, - limitDefault=self.getPlugin().getPreferences("LogLimit")) + self.hgGetTagsList(repodir), + self.hgGetBranchesList(repodir), + bookmarksList, + emptyRevsOk=True, + showLimit=True, + limitDefault=self.getPlugin().getPreferences("LogLimit")) if dlg.exec_() == QDialog.Accepted: revs, noEntries = dlg.getRevisions() from .HgLogDialog import HgLogDialog @@ -1418,7 +1418,7 @@ """<tr><td><b>URL</b></td><td>{1}</td></tr>\n""" """{2}""" """</table></p>\n""" - ).format(self.versionStr, url, infoStr) + ).format(self.versionStr, url, infoStr) ########################################################################### ## Private Mercurial specific methods are below. @@ -1814,7 +1814,7 @@ self.trUtf8("Mercurial Side-by-Side Difference"), self.trUtf8( """<p>The file <b>{0}</b> could not be read.</p>""") - .format(name)) + .format(name)) return if self.sbsDiff is None: @@ -2916,7 +2916,7 @@ dlg = HgGraftDialog(self, revs) if dlg.exec_() == QDialog.Accepted: revs, (userData, currentUser, userName), \ - (dateData, currentDate, dateStr), log, dryrun = dlg.getData() + (dateData, currentDate, dateStr), log, dryrun = dlg.getData() args = [] args.append("graft") @@ -3061,7 +3061,7 @@ self.trUtf8( """<p>The sub-repositories file .hgsub could not""" """ be read.</p><p>Reason: {0}</p>""") - .format(str(err))) + .format(str(err))) return if entry in contents: @@ -3090,7 +3090,7 @@ self.trUtf8( """<p>The sub-repositories file .hgsub could not""" """ be written to.</p><p>Reason: {0}</p>""") - .format(str(err))) + .format(str(err))) return if needsAdd: @@ -3122,7 +3122,7 @@ self.trUtf8("Remove Sub-repositories"), self.trUtf8("""<p>The sub-repositories file .hgsub could not""" """ be read.</p><p>Reason: {0}</p>""") - .format(str(err))) + .format(str(err))) return from .HgRemoveSubrepositoriesDialog import \ @@ -3142,7 +3142,7 @@ self.trUtf8( """<p>The sub-repositories file .hgsub could not""" """ be written to.</p><p>Reason: {0}</p>""") - .format(str(err))) + .format(str(err))) return if deleteSubrepos:
--- a/install-i18n.py Sat Oct 19 14:05:26 2013 +0200 +++ b/install-i18n.py Sat Oct 19 15:15:50 2013 +0200 @@ -124,8 +124,7 @@ except SystemExit: raise except: - print( -"""An internal error occured. Please report all the output of the program, -including the following traceback, to eric5-bugs@eric-ide.python-projects.org. -""") + print("""An internal error occured. Please report all the output of""" + """ the program,\nincluding the following traceback, to""" + """ eric5-bugs@eric-ide.python-projects.org.\n""") raise
--- a/install.py Sat Oct 19 14:05:26 2013 +0200 +++ b/install.py Sat Oct 19 15:15:50 2013 +0200 @@ -225,7 +225,7 @@ '''start "" "{2}\\pythonw.exe"''' \ ''' "{0}\\{1}.pyw"''' \ ''' %1 %2 %3 %4 %5 %6 %7 %8 %9\n'''.format( - pydir, wfile, sys.exec_prefix) + pydir, wfile, sys.exec_prefix) else: wrapper = \ '''@"{0}\\python" "{1}\\{2}.py"''' \ @@ -238,20 +238,18 @@ if not os.path.exists(pyexec): pyexec = "{0}/bin/python3".format(sys.exec_prefix) wname = wfile - wrapper = ( -'''#!/bin/sh - -exec "{0}" "{1}/{2}.py" "$@" -'''.format(pyexec, pydir, wfile)) + wrapper = ('''#!/bin/sh\n''' + '''\n''' + '''exec "{0}" "{1}/{2}.py" "$@"\n''' + .format(pyexec, pydir, wfile)) # *nix systems else: wname = wfile - wrapper = ( -'''#!/bin/sh - -exec "{0}" "{1}/{2}.py" "$@" -'''.format(sys.executable, pydir, wfile)) + wrapper = ('''#!/bin/sh\n''' + '''\n''' + '''exec "{0}" "{1}/{2}.py" "$@"\n''' + .format(sys.executable, pydir, wfile)) copyToFile(wname, wrapper) os.chmod(wname, 0o755) @@ -500,7 +498,7 @@ # copy the various parts of eric5 copyTree( sourceDir, cfg['ericDir'], - ['*.py', '*.pyc', '*.pyo', '*.pyw'], + ['*.py', '*.pyc', '*.pyo', '*.pyw'], ['{1}{0}Examples'.format(os.sep, sourceDir)], excludePatterns=["eric5config.py*"]) copyTree( @@ -681,18 +679,16 @@ if pybin not in pathlist: pathlist.insert(0, pybin) path = os.pathsep.join(pathlist) - wrapper = ( -'''#!/bin/sh - -PATH={0} -exec "{1}" "{2}/{3}.py" "$@" -'''.format(path, starter, pydir, "eric5")) + wrapper = ('''#!/bin/sh\n''' + '''\n''' + '''PATH={0}\n''' + '''exec "{1}" "{2}/{3}.py" "$@"\n''' + .format(path, starter, pydir, "eric5")) else: - wrapper = ( -'''#!/bin/sh - -exec "{0}" "{1}/{2}.py" "$@" -'''.format(starter, pydir, "eric5")) + wrapper = ('''#!/bin/sh\n''' + '''\n''' + '''exec "{0}" "{1}/{2}.py" "$@"\n''' + .format(starter, pydir, "eric5")) copyToFile(wname, wrapper) os.chmod(wname, 0o755) @@ -700,30 +696,30 @@ os.path.join(dirs["icns"], "eric.icns")) copyToFile( -os.path.join(dirs["contents"], "Info.plist"), -'''<?xml version="1.0" encoding="UTF-8"?> -<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" - "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> -<plist version="1.0"> -<dict> - <key>CFBundleExecutable</key> - <string>eric5</string> - <key>CFBundleIconFile</key> - <string>eric.icns</string> - <key>CFBundleInfoDictionaryVersion</key> - <string>1.0</string> - <key>CFBundleName</key> - <string>{0}</string> - <key>CFBundleDisplayName</key> - <string>{0}</string> - <key>CFBundlePackageType</key> - <string>APPL</string> - <key>CFBundleSignature</key> - <string>????</string> - <key>CFBundleVersion</key> - <string>1.0</string> -</dict> -</plist>\n'''.format(macAppBundleName.replace(".app", ""))) + os.path.join(dirs["contents"], "Info.plist"), + '''<?xml version="1.0" encoding="UTF-8"?>\n''' + '''<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN"\n''' + ''' "http://www.apple.com/DTDs/PropertyList-1.0.dtd">\n''' + '''<plist version="1.0">\n''' + '''<dict>\n''' + ''' <key>CFBundleExecutable</key>\n''' + ''' <string>eric5</string>\n''' + ''' <key>CFBundleIconFile</key>\n''' + ''' <string>eric.icns</string>\n''' + ''' <key>CFBundleInfoDictionaryVersion</key>\n''' + ''' <string>1.0</string>\n''' + ''' <key>CFBundleName</key>\n''' + ''' <string>{0}</string>\n''' + ''' <key>CFBundleDisplayName</key>\n''' + ''' <string>{0}</string>\n''' + ''' <key>CFBundlePackageType</key>\n''' + ''' <string>APPL</string>\n''' + ''' <key>CFBundleSignature</key>\n''' + ''' <string>????</string>\n''' + ''' <key>CFBundleVersion</key>\n''' + ''' <string>1.0</string>\n''' + '''</dict>\n''' + '''</plist>\n'''.format(macAppBundleName.replace(".app", ""))) def createInstallConfig(): @@ -774,52 +770,53 @@ apis.append(os.path.basename(apiName)) fn = 'eric5config.py' - config = \ -"""# -*- coding: utf-8 -*- -# -# This module contains the configuration of the individual eric5 installation -# - -_pkg_config = {{ - 'ericDir': r'{0}', - 'ericPixDir': r'{1}', - 'ericIconDir': r'{2}', - 'ericDTDDir': r'{3}', - 'ericCSSDir': r'{4}', - 'ericStylesDir': r'{5}', - 'ericDocDir': r'{6}', - 'ericExamplesDir': r'{7}', - 'ericTranslationsDir': r'{8}', - 'ericTemplatesDir': r'{9}', - 'ericCodeTemplatesDir': r'{10}', - 'ericOthersDir': r'{11}', - 'bindir': r'{12}', - 'mdir': r'{13}', - 'apidir': r'{14}', - 'apis': {15}, -}} - -def getConfig(name): - ''' - Module function to get a configuration value. - - @param name the name of the configuration value (string). - ''' - try: - return _pkg_config[name] - except KeyError: - pass - - raise AttributeError('"{{0}}" is not a valid configuration value'.format( - name))\n""".format( - cfg['ericDir'], cfg['ericPixDir'], cfg['ericIconDir'], - cfg['ericDTDDir'], cfg['ericCSSDir'], - cfg['ericStylesDir'], cfg['ericDocDir'], - cfg['ericExamplesDir'], cfg['ericTranslationsDir'], - cfg['ericTemplatesDir'], - cfg['ericCodeTemplatesDir'], cfg['ericOthersDir'], - cfg['bindir'], cfg['mdir'], - cfg['apidir'], apis) + config = ( + """# -*- coding: utf-8 -*-\n""" + """#\n""" + """# This module contains the configuration of the individual eric5""" + """ installation\n""" + """#\n""" + """\n""" + """_pkg_config = {{\n""" + """ 'ericDir': r'{0}',\n""" + """ 'ericPixDir': r'{1}',\n""" + """ 'ericIconDir': r'{2}',\n""" + """ 'ericDTDDir': r'{3}',\n""" + """ 'ericCSSDir': r'{4}',\n""" + """ 'ericStylesDir': r'{5}',\n""" + """ 'ericDocDir': r'{6}',\n""" + """ 'ericExamplesDir': r'{7}',\n""" + """ 'ericTranslationsDir': r'{8}',\n""" + """ 'ericTemplatesDir': r'{9}',\n""" + """ 'ericCodeTemplatesDir': r'{10}',\n""" + """ 'ericOthersDir': r'{11}',\n""" + """ 'bindir': r'{12}',\n""" + """ 'mdir': r'{13}',\n""" + """ 'apidir': r'{14}',\n""" + """ 'apis': {15},\n""" + """}}\n""" + """\n""" + """def getConfig(name):\n""" + """ '''\n""" + """ Module function to get a configuration value.\n""" + """\n""" + """ @param name name of the configuration value (string)\n""" + """ '''\n""" + """ try:\n""" + """ return _pkg_config[name]\n""" + """ except KeyError:\n""" + """ pass\n""" + """\n""" + """ raise AttributeError('"{{0}}" is not a valid configuration""" + """ value'.format(name))\n""").format( + cfg['ericDir'], cfg['ericPixDir'], cfg['ericIconDir'], + cfg['ericDTDDir'], cfg['ericCSSDir'], + cfg['ericStylesDir'], cfg['ericDocDir'], + cfg['ericExamplesDir'], cfg['ericTranslationsDir'], + cfg['ericTemplatesDir'], + cfg['ericCodeTemplatesDir'], cfg['ericOthersDir'], + cfg['bindir'], cfg['mdir'], + cfg['apidir'], apis) copyToFile(fn, config) @@ -1217,8 +1214,7 @@ except SystemExit: raise except: - print(""" -An internal error occured. Please report all the output of the program, -including the following traceback, to eric5-bugs@eric-ide.python-projects.org. -""") + print("""An internal error occured. Please report all the output""" + """ of the program,\nincluding the following traceback, to""" + """ eric5-bugs@eric-ide.python-projects.org.\n""") raise
--- a/patch_modpython.py Sat Oct 19 14:05:26 2013 +0200 +++ b/patch_modpython.py Sat Oct 19 15:15:50 2013 +0200 @@ -157,8 +157,7 @@ except SystemExit: raise except: - print( -"""An internal error occured. Please report all the output of the program, -including the following traceback, to eric-bugs@die-offenbachs.de. -""") + print("""An internal error occured. Please report all the output of""" + """ the program,\nincluding the following traceback, to""" + """ eric-bugs@die-offenbachs.de.\n""") raise