--- a/Plugins/CheckerPlugins/Pep8/Pep8Dialog.py Sat Sep 07 15:47:53 2013 +0200 +++ b/Plugins/CheckerPlugins/Pep8/Pep8Dialog.py Sun Sep 08 13:16:07 2013 +0200 @@ -24,6 +24,8 @@ import Preferences import Utilities +from .Pep8NamingChecker import Pep8NamingChecker + class Pep8Report(pep8.BaseReport): """ @@ -52,7 +54,10 @@ """ code = super().error_args(line_number, offset, code, check, *args) if code and (self.counters[code] == 1 or self.__repeat): - text = pep8.getMessage(code, *args) + if code in Pep8NamingChecker.Codes: + text = Pep8NamingChecker.getMessage(code, *args) + else: + text = pep8.getMessage(code, *args) self.errors.append( (self.filename, line_number, offset, text) ) @@ -106,6 +111,9 @@ self.__statistics = {} self.on_loadDefaultButton_clicked() + + # register the name checker + pep8.register_check(Pep8NamingChecker, Pep8NamingChecker.Codes) def __resort(self): """ @@ -143,6 +151,8 @@ ["{0:6}".format(line), code, message]) if code.startswith("W"): itm.setIcon(1, UI.PixmapCache.getIcon("warning.png")) + elif code.startswith("N"): + itm.setIcon(1, UI.PixmapCache.getIcon("namingError.png")) else: itm.setIcon(1, UI.PixmapCache.getIcon("syntaxError.png")) if fixed: