The function draw_label_in_box have logic to chose the rigth side
to call the draw_text, so use it instaed of forcing the cordinates
of the right side.

Signed-off-by: Jose Quaresma <[email protected]>
---
 scripts/pybootchartgui/pybootchartgui/draw.py | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/scripts/pybootchartgui/pybootchartgui/draw.py 
b/scripts/pybootchartgui/pybootchartgui/draw.py
index ddfa9a6192..10f6783d38 100644
--- a/scripts/pybootchartgui/pybootchartgui/draw.py
+++ b/scripts/pybootchartgui/pybootchartgui/draw.py
@@ -682,10 +682,9 @@ def render_processes_chart(ctx, options, trace, curr_y, w, 
h, sec_w):
                 draw_fill_rect(ctx, col, (x, y, w, proc_h))
             draw_rect(ctx, PROC_BORDER_COLOR, (x, y, w, proc_h))
 
-            draw_label_in_box(ctx, PROC_TEXT_COLOR, process, x, y + proc_h - 
4, w, proc_h)
-
             # Show elapsed time for each task
-            draw_text(ctx, elapsed_time, PROC_TEXT_COLOR, x + w + 4, y + 
proc_h - 4)
+            process = "%ds %s" % (elapsed_time, process)
+            draw_label_in_box(ctx, PROC_TEXT_COLOR, process, x, y + proc_h - 
4, w, proc_h)
 
             y = y + proc_h
 
-- 
2.34.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#184102): 
https://lists.openembedded.org/g/openembedded-core/message/184102
Mute This Topic: https://lists.openembedded.org/mt/100068051/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to