From d59b80514e15d26f280a9b0dbd18afac08578638 Mon Sep 17 00:00:00 2001 From: Filip Dutescu Date: Wed, 29 Mar 2023 06:52:19 +0300 Subject: feat(debug): highlight current line (#5957) Add new theme highlight keys, for setting the colour of the breakpoint character and the current line at which execution has been paused at. The two new keys are `ui.highlight.frameline` and `ui.debug.breakpoint`. Highlight according to those keys, both the line at which debugging is paused at and the breakpoint indicator. Add an indicator for the current line at which execution is paused at, themed by the `ui.debug.active` theme scope. Update various themes to showcase how the new functionality works. Better icons are dependent on #2869, and as such will be handled in the future, once it lands. Closes: #5952 Signed-off-by: Filip Dutescu --- helix-dap/src/client.rs | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'helix-dap') diff --git a/helix-dap/src/client.rs b/helix-dap/src/client.rs index ff727d00..7efb72d8 100644 --- a/helix-dap/src/client.rs +++ b/helix-dap/src/client.rs @@ -512,4 +512,10 @@ impl Client { self.call::(args) } + + pub fn current_stack_frame(&self) -> Option<&StackFrame> { + self.stack_frames + .get(&self.thread_id?)? + .get(self.active_frame?) + } } -- cgit v1.2.3-70-g09d2