Skip to content

Commit

Permalink
Fixed incorrect X position of expanded rows in protocol analyzer hexd…
Browse files Browse the repository at this point in the history
…umps
  • Loading branch information
azonenberg committed Sep 6, 2024
1 parent 8dfc846 commit 75540e6
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/ngscopeclient/ProtocolAnalyzerDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -577,11 +577,17 @@ void ProtocolAnalyzerDialog::DoDataColumn(Packet* pack, ImFont* dataFont, vector
}
}

auto firstPos = ImGui::GetCursorScreenPos();
ImGui::TextUnformatted(firstLine.c_str());

//Multiple lines? Only show if open
if(open)
{
//align vertically to previous line
auto nextPos = ImGui::GetCursorScreenPos();
nextPos.x = firstPos.x;
ImGui::SetCursorScreenPos(nextPos);

ImGui::TextUnformatted(data.c_str());
ImGui::TreePop();
}
Expand Down

0 comments on commit 75540e6

Please sign in to comment.