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 764405 - Show document's filename/path in "Recent Documents" window
Show document's filename/path in "Recent Documents" window
Status: RESOLVED FIXED
Product: evince
Classification: Core
Component: general
3.18.x
Other Linux
: Normal normal
: ---
Assigned To: Evince Maintainers
Evince Maintainers
Depends on:
Blocks:
 
 
Reported: 2016-03-31 09:45 UTC by Stephan Bergmann
Modified: 2016-04-10 10:26 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
recent-view: show the document uri on a tooltip (3.20 KB, patch)
2016-03-31 10:11 UTC, Felipe Borges
committed Details | Review

Description Stephan Bergmann 2016-03-31 09:45:29 UTC
At least in evince on Fedora 23, the "Recent Documents" window only shows thumbnails and document titles, but no way to see a document's file name or path (when you hover the mouse over it, say).  For example, I often have different versions of the C++ Standard I want to read (with different file names/paths), but it is impossible to guess which thumbnail corresponds to which version.
Comment 1 Felipe Borges 2016-03-31 10:11:45 UTC
Created attachment 325070 [details] [review]
recent-view: show the document uri on a tooltip

This helps differentiate to documents which happen
to have the same title and author. URIs should be
unique.
Comment 2 Felipe Borges 2016-03-31 10:14:23 UTC
We might also discuss whether we want the full path (complete uri) for the documents or just the filename. I would go with the full uri (as it is on the patch above) because I guess it is a common case where you have a remote and a local copy of the same document. Opinions?
Comment 3 Germán Poo-Caamaño 2016-04-05 15:06:31 UTC
Do we show remote files in the recent view?

It does not seem so (I may be wrong):
https://git.gnome.org/browse/evince/tree/shell/ev-recent-view.c#n720

IIRC, the rationale to avoid remote files in the recent view is to avoid blocking the UI or something alike.

Other than that, I agree with the patch.

¿Carlos, Christian, José?
Comment 4 Felipe Borges 2016-04-05 15:57:58 UTC
(In reply to Germán Poo-Caamaño from comment #3)
> Do we show remote files in the recent view?
> 
> It does not seem so (I may be wrong):
> https://git.gnome.org/browse/evince/tree/shell/ev-recent-view.c#n720
> 
> IIRC, the rationale to avoid remote files in the recent view is to avoid
> blocking the UI or something alike.
> 
> Other than that, I agree with the patch.
> 
> ¿Carlos, Christian, José?

anyhow, it can be two files with the same title/author in the same folder.
Comment 5 Germán Poo-Caamaño 2016-04-06 12:40:46 UTC
(In reply to Felipe Borges from comment #4)
> anyhow, it can be two files with the same title/author in the same folder.

Perhaps I did not express myself properly.

I agree with the feature, and that is something we need. I have been beaten by this issue multiple times, almost every day.

What I tried to say is that I am unsure about showing the full uri (with scheme, etc) if the files shown in the recent view are all locals.
Comment 6 Carlos Garcia Campos 2016-04-10 08:06:45 UTC
Review of attachment 325070 [details] [review]:

This looks good to me, please fix the unneeded string duplication before pushing this. Thanks!

::: shell/ev-recent-view.c
@@ +216,3 @@
+                            -1);
+
+        text = g_strdup_printf ("%s", uri);

Why do you need g_strdup_printf if the format string is just %s? g_strdup should be enough.

@@ +217,3 @@
+
+        text = g_strdup_printf ("%s", uri);
+        gtk_tooltip_set_text (tooltip, text);

But why do you need to duplicate the uri string at all? You can just pass uri here and then free it.
Comment 7 Felipe Borges 2016-04-10 09:58:33 UTC
Thanks for your review. I made the changes mentioned above and pushed it to master.

Attachment 325070 [details] pushed as a1b2dac - recent-view: show the document uri on a tooltip

Any thoughts about whether it would be better to have just the filename instead of the full path?
Comment 8 Carlos Garcia Campos 2016-04-10 10:26:51 UTC
(In reply to Felipe Borges from comment #7)
> Thanks for your review. I made the changes mentioned above and pushed it to
> master.
> 
> Attachment 325070 [details] pushed as a1b2dac - recent-view: show the
> document uri on a tooltip
> 
> Any thoughts about whether it would be better to have just the filename
> instead of the full path?

Either way is fine with me, so whatever you guys find more useful.