From 6e894a1e60fd0f6796fa812ca74eba7e50c36776 Mon Sep 17 00:00:00 2001 From: Lorenzo Santangelo <48159385+lorsanta@users.noreply.github.com> Date: Sun, 1 Dec 2024 21:21:44 +0100 Subject: [PATCH] Add nicer displaying of 1 instruction loops (#3396) * fix #3369 --- src/widgets/DisassemblyWidget.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/widgets/DisassemblyWidget.cpp b/src/widgets/DisassemblyWidget.cpp index 946a2d35..d74c1427 100644 --- a/src/widgets/DisassemblyWidget.cpp +++ b/src/widgets/DisassemblyWidget.cpp @@ -984,6 +984,11 @@ void DisassemblyLeftPanel::paintEvent(QPaintEvent *event) int arrowLineNumber = offsetToLine(arrow.jmpToffset()); int lineArrowY = lineToPixels(arrowLineNumber); + if (lineStartNumber == arrowLineNumber) { + currentLineYPos += lineHeight / 4; + lineArrowY -= lineHeight / 4; + } + // Draw the lines p.drawLine(rightOffset, currentLineYPos, rightOffset - lineOffset, currentLineYPos); // left p.drawLine(rightOffset - lineOffset, currentLineYPos, rightOffset - lineOffset,