Bug 566550

Summary: CompareUI.findContentViewer should return text compare viewer in TextEditChangePreviewViewer
Product: [Eclipse Project] Platform Reporter: Christopher Hendrich <christopher.hendrich>
Component: TextAssignee: Platform-Text-Inbox <platform-text-inbox>
Status: NEW --- QA Contact:
Severity: normal    
Priority: P3    
Version: 4.17   
Target Milestone: ---   
Hardware: PC   
OS: Windows 10   
Whiteboard:

Description Christopher Hendrich CLA 2020-09-01 08:22:11 EDT
When searching an replacing text via the file search dialog in Eclipse, the CompareViewer within the class TextEditChangePreviewViewer asks via "CompareUI.findContentViewer" for a matching compare viewer with respect to the underlying file. 

If you have a custom compare viewer registered for this file (since it is a structured, complex object that requires special treatment), the corresponding specific viewer will be used.
This viewer can - however - not work with text snippets. Therefore, the only meaningful compare viewer would be the generic text based one and this would make perfectly sense since we are in a text search and replace scenario. 

Is there any chance to force this class to use the generic text compare viewer for the search and replace preview?
Comment 1 Noopur Gupta CLA 2020-09-04 03:20:03 EDT
I think this should be handled in Platform Compare or Text to return the expected viewer via "CompareUI.findContentViewer".