jtulach opened a new pull request, #7483:
URL: https://github.com/apache/netbeans/pull/7483

   We at [Enso](http://enso.org) are finally adding _VSCode outline view_ into 
[Enso VSCode 
extension](https://marketplace.visualstudio.com/items?itemName=Enso.enso4vscode):
   
   - https://github.com/enso-org/enso/pull/7054
   
   We had to write our own [EnsoStructure 
provider](https://github.com/enso-org/enso/pull/7054/files#diff-48e5e6c6cd09cd1d1398cb39973470e4d85a212d0df83d8240186235e55fb483R19).
 As the snapshots in the [pull request 
demonstrate](https://github.com/enso-org/enso/pull/7054) it is _working fine in 
VSCode_.
   
   However: I also **want it to work in NetBeans** and IGV!
   
   I see little point writing own navigator implementation and registering it 
in the Enso NBM. Especially when my _original vision_ of the [LSP 
API](https://bits.netbeans.org/22/javadoc/org-netbeans-api-lsp/) saw it as a 
way to hook into VSCode **as well as** NetBeans by _writing one implementation_ 
and _using it in both_ systems. This PR is my attempt to contribute to that 
vision.
   
   - Existing `lsp.client` module now checks for presence of 
[StructureProvider](https://bits.netbeans.org/22/javadoc/org-netbeans-api-lsp/org/netbeans/spi/lsp/StructureProvider.html)
   - When found, it extracts the `StructureElement` hierarchy and builds nodes 
for the elements
   
   The functionality is very close to the already existing functionality that 
works via LSP4J interfaces. Maybe there is a way to _share the navigators_ - 
either by abstracting the functionality to common interfaces or by bridging 
(now deprecated) `org.eclipse.lsp4j.SymbolInformation` to `StructureElement` - 
what do you think?
   
   In any case, I'd be thankful if NetBeans recognized various  [LSP API 
providers](https://bits.netbeans.org/22/javadoc/org-netbeans-api-lsp/) and used 
them in the classical UI where appropriate. This is how NetBeans look with this 
PR and [Enso4Igv NBM version 
v1.36.114](https://github.com/enso-org/enso/actions/runs/9509862775?pr=7054):
   
   ![Enso Structure in NetBeans 
22+](https://github.com/apache/netbeans/assets/1842422/2ab8ce08-b6b5-4516-87db-3753c27f30c9)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to