PrestoSoft Blog :: Home

Thursday, December 02, 2021

ExamDiff Pro 13.0: Scope Bar

ExamDiff Pro 13.0 will introduce an exciting and long-awaited new feature: the ability to navigate through classes, functions, and other code blocks, via a new scope bar.

This feature is powered by the open-source Tree-sitter library, and will be available for all major programming language doctypes defined in ExamDiff Pro, including C++, C#, Java, JavaScript, and more.

As an example, let's compare two C# files:

When we navigate inside a class or function, the new scope bar control at the top of the diff pane displays where we are, through a series of "breadcrumbs".

Clicking on a breadcrumb opens a nested scope explorer. Scopes that are different (added, changed, or removed) between the two files are highlighted in bold. We can click on any of the scope names here to jump to the corresponding part of the file:



The scope bar automatically updates itself whenever the file changes. For example, we can rename this property, and the scope bar quickly changes to reflect this:

You can control visibility of scope bars by using the View | Scope Bars menu command:

Note that the scope bars will only appear for document types supported by the scope parser (this includes most built-in doctypes in the Document Types options dialog). If a file extension isn't recognized by default, you can use the Set Document Type feature manually to enable all doctype-related features (scope bar, syntax highlighting, etc).

For example, in the screenshot below, the JavaScript files being merged wouldn't be recognized as JavaScript by default because they do not have the expected *.js file extension. But after clicking Set Document Type | JavaScript in one pane's context menu, we override the doctype for all panes to be JavaScript, causing scope bars (as well as syntax highlighting) to appear everywhere:

This new scope bar functionality will make navigating through source code easier than ever in ExamDiff Pro.

Labels: , ,

0 Comments:

Post a Comment

<< Home