コード例 #1
0
    def __init__(self, master):
        MemoryFrame.__init__(self, master, ("id", "value"))

        self.tree.column("id", width=100, anchor=tk.W, stretch=False)
        self.tree.column("value", width=150, anchor=tk.W, stretch=True)

        self.tree.heading("id", text="ID", anchor=tk.W)
        self.tree.heading("value", text="Value", anchor=tk.W)

        get_workbench().bind("get_heap_response", self._handle_heap_event, True)

        get_workbench().bind("DebuggerResponse", self._request_heap_data, True)
        get_workbench().bind("ToplevelResponse", self._request_heap_data, True)
        # Showing new globals may introduce new interesting objects
        get_workbench().bind("get_globals_response", self._request_heap_data, True)

        self.bind("<Map>", self._on_map, True)
        self.bind("<Unmap>", self._on_unmap, True)
        info_icon = get_workbench().get_image("information")
        self.info_label = ttk.Label(
            get_workbench().get_toolbar(),
            text=tr("Heap mode is on.\nClose Heap view to turn it off."),
            image=info_icon,
            compound="left",
            background="#F4FFBA",
            foreground="green",
            padding=(3, 0),
        )
コード例 #2
0
ファイル: heap.py プロジェクト: aivarannamaa/thonny
 def __init__(self, master, workbench):
     MemoryFrame.__init__(self, master, workbench, ("id", "value"))
     
     self.tree.column('id', width=100, anchor=tk.W, stretch=False)
     self.tree.column('value', width=150, anchor=tk.W, stretch=True)
     
     self.tree.heading('id', text='ID', anchor=tk.W)
     self.tree.heading('value', text='Value', anchor=tk.W) 
コード例 #3
0
ファイル: heap.py プロジェクト: byache/thonny
    def __init__(self, master):
        MemoryFrame.__init__(self, master, ("id", "value"))

        self.tree.column('id', width=100, anchor=tk.W, stretch=False)
        self.tree.column('value', width=150, anchor=tk.W, stretch=True)

        self.tree.heading('id', text='ID', anchor=tk.W)
        self.tree.heading('value', text='Value', anchor=tk.W)

        get_workbench().bind("Heap", self._handle_heap_event, True)

        get_workbench().bind("DebuggerProgress", self._request_heap_data, True)
        get_workbench().bind("ToplevelResult", self._request_heap_data, True)
        # Showing new globals may introduce new interesting objects
        get_workbench().bind("Globals", self._request_heap_data, True)
コード例 #4
0
    def __init__(self, master):
        TypeSpecificInspector.__init__(self, master)
        MemoryFrame.__init__(self, master, ('key_id', 'id', 'key', 'value'))
        self.configure(border=1)
        #self.vert_scrollbar.grid_remove()
        self.tree.column('key_id', width=100, anchor=tk.W, stretch=False)
        self.tree.column('key', width=100, anchor=tk.W, stretch=False)
        self.tree.column('id', width=750, anchor=tk.W, stretch=True)
        self.tree.column('value', width=750, anchor=tk.W, stretch=True)

        self.tree.heading('key_id', text='Key ID', anchor=tk.W)
        self.tree.heading('key', text='Key', anchor=tk.W)
        self.tree.heading('id', text='Value ID', anchor=tk.W)
        self.tree.heading('value', text='Value', anchor=tk.W)

        self.update_memory_model()
コード例 #5
0
    def __init__(self, master):
        MemoryFrame.__init__(self, master, ("id", "value"))

        self.tree.column("id", width=100, anchor=tk.W, stretch=False)
        self.tree.column("value", width=150, anchor=tk.W, stretch=True)

        self.tree.heading("id", text="ID", anchor=tk.W)
        self.tree.heading("value", text="Value", anchor=tk.W)

        get_workbench().bind("get_heap_response", self._handle_heap_event,
                             True)

        get_workbench().bind("DebuggerResponse", self._request_heap_data, True)
        get_workbench().bind("ToplevelResponse", self._request_heap_data, True)
        # Showing new globals may introduce new interesting objects
        get_workbench().bind("get_globals_response", self._request_heap_data,
                             True)
コード例 #6
0
    def __init__(self, master):
        TypeSpecificInspector.__init__(self, master)
        MemoryFrame.__init__(self, master, ('index', 'id', 'value'))
        self.configure(border=1)

        #self.vert_scrollbar.grid_remove()
        self.tree.column('index', width=40, anchor=tk.W, stretch=False)
        self.tree.column('id', width=750, anchor=tk.W, stretch=True)
        self.tree.column('value', width=750, anchor=tk.W, stretch=True)

        self.tree.heading('index', text='Index', anchor=tk.W)
        self.tree.heading('id', text='Value ID', anchor=tk.W)
        self.tree.heading('value', text='Value', anchor=tk.W)

        self.elements_have_indices = None
        self.update_memory_model()

        get_workbench().bind("ShowView", self.update_memory_model, True)
        get_workbench().bind("HideView", self.update_memory_model, True)