Bug 831056
Summary: | RFE: [Translation Memory] Option for highlight only the search terms | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | [Retired] Zanata | Reporter: | Ding-Yi Chen <dchen> | ||||||
Component: | Component-UI | Assignee: | Patrick Huang <pahuang> | ||||||
Status: | CLOSED CURRENTRELEASE | QA Contact: | Ding-Yi Chen <dchen> | ||||||
Severity: | medium | Docs Contact: | |||||||
Priority: | medium | ||||||||
Version: | 1.6-SNAPSHOT | CC: | mkim, pahuang, sflaniga, zanata-bugs | ||||||
Target Milestone: | --- | ||||||||
Target Release: | 2.1 | ||||||||
Hardware: | Unspecified | ||||||||
OS: | Unspecified | ||||||||
Whiteboard: | |||||||||
Fixed In Version: | 2.1-SNAPSHOT (20121206-1113) | Doc Type: | Bug Fix | ||||||
Doc Text: | Story Points: | --- | |||||||
Clone Of: | Environment: | ||||||||
Last Closed: | 2013-02-26 04:06:14 UTC | Type: | Bug | ||||||
Regression: | --- | Mount Type: | --- | ||||||
Documentation: | --- | CRM: | |||||||
Verified Versions: | Category: | --- | |||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||
Embargoed: | |||||||||
Attachments: |
|
Description
Ding-Yi Chen
2012-06-12 06:06:40 UTC
Created attachment 591099 [details]
Screenshot that demonstrates the issue
The attachment does not seem to have a search item in the search box. However the error can be replicated. Requesting for technical evaluation. The screenshot is demonstrating the automatic TM search you get when clicking on any text flow. I think we need to provide an alternative mode for the highlighter, so that non-matching/missing text is hidden, matching text is highlighted, and added text is shown plain. It should just require a bit of CSS class tweaking, and a checkbox to turn it on and off. highlighting search term only make sense when there is 100% match. If it's not, i.e. fuzzy search, how do we want to highlight? Picking out matching words? Ok got the meaning. Basically we just use diff result. Created attachment 654812 [details] Current diff can not cope with fuzzy search See attachment. Search term: Fedora is an open Item number three: Visit the Fedora community Wiki at <ulink url="http://fedoraproject.org/wiki/" />. Entire string is showing as missing(diff delete) and added(diff insert). There is no diff equal. Back to the question I asked in Comment 4 I don't think we want to make a big thing of this RFE. Just highlight the matching bits, according to diffmatchpatch, hide the missing bits, and show the added bits unhighlighted. Some edge cases may not highlight well, but they may not be worth worrying about. If we really wanted to, we could tell diffmatchpatch not to do "semantic cleanup" (see org.zanata.webtrans.client.ui.Highlighting.diff(String, String)), but this will probably make the highlighting uglier in most cases. I suppose it could be useful to turn off semantic cleanup only in the cases where it makes a complete mess (eg one big deletion, and one big insertion). But it's probably not worth the effort. Or you could try turning off semantic cleanup whenever term highlighting is active, and we could see if we like the results. Turning semantic cleanup off when doing match term highlight. Semantic cleanup is on in normal diff mode. committed into master: https://github.com/zanata/zanata/commit/4b1d06485090490c8bd297f1d67ffbd8db5601ad According to Hedda adding a user option that can be persisted is helpful committed again into master: https://github.com/zanata/zanata/commit/83974ebe0a822173bd6d464df691a08a74e7ce09 VERIFIED with Zanata version 2.1-SNAPSHOT (20121206-1113) |