After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 626406 - Smarter/prettier highlighting of text
Smarter/prettier highlighting of text
Status: RESOLVED OBSOLETE
Product: evince
Classification: Core
Component: general
2.31.x
Other Linux
: Normal normal
: ---
Assigned To: Evince Maintainers
Evince Maintainers
Depends on:
Blocks:
 
 
Reported: 2010-08-09 07:23 UTC by Tobias Wolf
Modified: 2018-05-22 13:58 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Differences in search term highlighting between Okular and Evince (230.63 KB, image/png)
2013-02-19 07:44 UTC, Florian Moretz
Details
test PDF (63.63 KB, image/png)
2013-03-01 19:42 UTC, Tobias Wolf
Details
Differences in search term highlighting under different themes and in comparison to Okular (162.88 KB, image/jpeg)
2013-03-01 20:34 UTC, Florian Moretz
Details

Description Tobias Wolf 2010-08-09 07:23:23 UTC
I’m wondering if it is possible to use Cairo to highlight text and boxes in a smarter way.

One possibility is to use a flood fill and an XOR composite mode. This would make it possible to use theme colors and still be robust across white-on-black or black-on-white (and in-between) documents.
Comment 1 André Klapper 2012-05-19 12:39:12 UTC
Which problem do you try to solve here, as "prettier" is subjective?
Comment 2 Tobias Wolf 2012-05-19 12:50:55 UTC
The point was that it’s always a light-blue alpha-composited highlight, which reduces visibility in many situations. A different compositing mode would alleviate that.
Comment 3 Florian Moretz 2013-02-19 07:44:59 UTC
Created attachment 236726 [details]
Differences in search term highlighting between Okular and Evince

I think "prettier" might be the wrong word here. Evince's highlighting is currently very hard to see, especially when compared to Okular (see attached Screenshot). A default color change or at least a related configuration option is very much necessary, more from a functional than an aesthetic standpoint.
Comment 4 Germán Poo-Caamaño 2013-03-01 09:35:26 UTC
It seems to me this depends on the theme installed.
Comment 5 Florian Moretz 2013-03-01 17:10:37 UTC
I would argue then that this theme dependency should be changed. Your choice of system theme should not impede search functionality in evince. In this regard aesthetics should take a step back for function, I think.

When working with physical documents you don't choose neon colours because you particularly like them, but because they provide the best visibility. The same principle should apply to digital documents as well.
Comment 6 Germán Poo-Caamaño 2013-03-01 17:49:29 UTC
(In reply to comment #5)
> I would argue then that this theme dependency should be changed. Your choice of
> system theme should not impede search functionality in evince. In this regard
> aesthetics should take a step back for function, I think.
>
> When working with physical documents you don't choose neon colours because you
> particularly like them, but because they provide the best visibility. The same
> principle should apply to digital documents as well.

A theme is not only a matter of aesthetics.  Themes allows better accessibility support for color-blinded people, or who need high-contrast, etc.

If the there were the issue (which I do not know, but it seems so), then the theme should be fixed.  As far as I see in the screenshot, it is not the default theme (Adwaita) because it looks totally different to what I have in my computer.
Comment 7 Tobias Wolf 2013-03-01 19:42:09 UTC
Created attachment 237736 [details]
test PDF

It's not just the theme. Any particular color can lead to problems if it's just overlaid like a transparency.

Normally for text selection you XOR the colors. If the background is dark, you make the text light, if the background is light you make the text dark. It's not about the subjective hue, it's about contrast.
Comment 8 Florian Moretz 2013-03-01 20:34:18 UTC
Created attachment 237743 [details]
Differences in search term highlighting under different themes and in comparison to Okular

I agree with Tobias Wolf. The coulours themselves aren't as much of an issue as the way in which they are applied to the document. The attached test case shows how highlighted search terms render under four different themes (including Greybird, Ambiance, Clearlooks and HighContrast) in evince as compared to Okular. You can see that the XOR method, which Okular employs, results in the most visible highlighting. Out of the five renderings it is the only one that immediately leaps out at you.
Comment 9 José Aliste 2013-03-02 00:13:59 UTC
The reason is mostly historic. Cairo didn't use to support the "XOR" method as described in the last comments. But newer versions of cairo do support it, so I don't see a reason to not change it. That being said, this does not have a very high priority, so you could probably try to cook a patch by your self.
Comment 10 GNOME Infrastructure Team 2018-05-22 13:58:16 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/evince/issues/168.