Community
Participate
Working Groups
The console view supports linking, but the links are only visible on mouse hover. StyledText has recently added support for underline and this support could be leveraged to render the links similar to links in a web browser. CCing Christof since he has some code that does this and could be used in the implementation.
released changes to: JavaConsoleTracker, JavaNativeConsoleTracker, JavaStackTraceHyperlink, jdt.debug.plugin.xml, TextConsoleViewer System.out was very close to the default hyperlink color changed System.out to black.
*** Bug 93405 has been marked as a duplicate of this bug. ***
Just a reminder: make sure that the new code (after fixing bug 92939) no longer calls StyledText.getLocationAtOffset(int) twice in a loop (see bug 65806) since this can take up quite some time (==> the PR I filed is related to performance instead of polish). Not sure what Christof's code does but the best thing would be to use either use - ITextPresentationListener and apply StyleRange.underline - define your own annotation type and simply add an annotation using underline drawing strategy
I built it into the IPresentationRepairer, which is kind-of hardwired. An ITextPresentationListener would incur a slightly smaller performance impact than the annotation approach.
TextConsoleViewer doesn't call getLocationAtOffset() at all anymore. It still uses LineStyleListener to apply StyleRanges. Will look at ITextPresentationListener. thanks for the tip.
Once the style is set we don't change it anymore - ie hyperlinks are always displayed in the hyperlink color and they are always underlined. ITextPresentationListener isn't necessary (in fact it never get any events).
Darin, please verify
Verified.