コード例 #1
0
ファイル: addr2line.py プロジェクト: lupine37/gps
 def __init__(self, executable):
     self.executable = executable
     self.name = "addr2line -e " + os.path.basename(self.executable)
     Console.__init__(self, self.name, on_input=Addr2line.on_input)
     self.create_link(file_line_re, self.onclick)
     self.clear()
     self.write("Backtrace ?")
     self.enable_input(True)
     MDI.get(self.name).raise_window()
コード例 #2
0
def show_unused_entities(where, globals_only):
    """List all unused global entities from WHERE in the locations window"""
    Editor.register_highlighting("Unused_Entities", "blue")
    Locations.remove_category("Unused entity")
    MDI.get("Messages").raise_window()

    for e in UnusedIterator(where, globals_only=globals_only):
        Locations.add(category="Unused entity",
                      file=e.declaration().file(),
                      line=e.declaration().line(),
                      column=e.declaration().column(),
                      message="unused entity " + e.name(),
                      highlight="Unused_Entities",
                      length=len(e.name()))

    Console().write("Done searching for unused entities\n")
コード例 #3
0
def update_project_view_title(t):
    new_name = Project.root().file().name()
    new_short_name = Project.root().name()
    view = MDI.get("Project View")

    if view is not None:
        view.rename(new_name, new_short_name)
        t.remove()
コード例 #4
0
ファイル: addr2line.py プロジェクト: lupine37/gps
 def on_exit(self, process, status, full_output):
     MDI.get(self.name).raise_window()
     self.write("\n\nBacktrace ?")
     self.enable_input(True)