pombreda / pybootchartgui

Automatically exported from code.google.com/p/pybootchartgui
GNU General Public License v3.0
0 stars 0 forks source link

patch: print [pid] of processes #12

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago

patch below prints out [pid] numbers for each process, a useful piece of
information to get an idea how many processes are spawned in between
displayed processes.

Index: pybootchartgui/draw.py
===================================================================
--- pybootchartgui/draw.py      (revision 131)
+++ pybootchartgui/draw.py      (working copy)
@@ -302,7 +302,7 @@

        draw_process_activity_colors(ctx, proc, proc_tree, x, y, w, proc_h,
rect)
        draw_rect(ctx, PROC_BORDER_COLOR, (x, y, w, proc_h))
-       draw_label_in_box(ctx, PROC_TEXT_COLOR, proc.cmd, x, y + proc_h -
4, w, rect[0] + rect[2])
+       draw_label_in_box(ctx, PROC_TEXT_COLOR, proc.cmd + " [" +
str(proc.pid) + "]", x, y + proc_h - 4, w, rect[0] + rect[2])

        next_y = y + proc_h
        for child in proc.child_list:

Original issue reported on code.google.com by parallel...@gmail.com on 12 Jun 2009 at 6:18

GoogleCodeExporter commented 9 years ago
Looks fine to me. Henning, what do you think?

Original comment by anders.n...@gmail.com on 14 Jun 2009 at 1:28

GoogleCodeExporter commented 9 years ago
Hi Auke

I put the printing of pid's like you suggest behind the option --show-pid in 
r133

Best
Anders

Original comment by anders.n...@gmail.com on 22 Jul 2009 at 7:33