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 751683 - Add support for hidpi displays in the overview
Add support for hidpi displays in the overview
Status: RESOLVED FIXED
Product: bijiben
Classification: Applications
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: Bijiben maintainer(s)
Bijiben maintainer(s)
: 742365 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2015-06-29 21:33 UTC by Cosimo Cecchi
Modified: 2015-07-01 20:09 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
bijiben: don't call gtk_init() (713 bytes, patch)
2015-06-29 21:33 UTC, Cosimo Cecchi
none Details | Review
bijiben: add own CSS style for notebooks (4.23 KB, patch)
2015-06-29 21:33 UTC, Cosimo Cecchi
none Details | Review
Update libgd (551 bytes, patch)
2015-06-29 21:33 UTC, Cosimo Cecchi
none Details | Review
Use cairo surfaces for drawing (22.29 KB, patch)
2015-06-29 21:33 UTC, Cosimo Cecchi
none Details | Review
notebook: don't fetch list of surfaces twice (951 bytes, patch)
2015-06-29 21:33 UTC, Cosimo Cecchi
none Details | Review
note-obj: move frame rendering to CSS (1.37 KB, patch)
2015-06-29 21:33 UTC, Cosimo Cecchi
none Details | Review
empty-results-box: fix blurry icon in hi-dpi (3.63 KB, patch)
2015-06-29 21:33 UTC, Cosimo Cecchi
none Details | Review
search-provider: don't return invalid results (1.12 KB, patch)
2015-06-29 21:33 UTC, Cosimo Cecchi
none Details | Review
bijiben: don't call gtk_init() (713 bytes, patch)
2015-06-30 00:43 UTC, Cosimo Cecchi
committed Details | Review
bijiben: add own CSS style for notebooks (4.23 KB, patch)
2015-06-30 00:43 UTC, Cosimo Cecchi
committed Details | Review
Update libgd (551 bytes, patch)
2015-06-30 00:43 UTC, Cosimo Cecchi
committed Details | Review
Use cairo surfaces for drawing (20.97 KB, patch)
2015-06-30 00:44 UTC, Cosimo Cecchi
committed Details | Review
notebook: don't fetch list of surfaces twice (951 bytes, patch)
2015-06-30 00:44 UTC, Cosimo Cecchi
committed Details | Review
empty-results-box: fix blurry icon in hi-dpi (3.63 KB, patch)
2015-06-30 00:44 UTC, Cosimo Cecchi
committed Details | Review
search-provider: don't return invalid results (1.12 KB, patch)
2015-06-30 00:44 UTC, Cosimo Cecchi
committed Details | Review
manager: rework how the manager is constructed (25.24 KB, patch)
2015-06-30 00:44 UTC, Cosimo Cecchi
committed Details | Review

Description Cosimo Cecchi 2015-06-29 21:33:11 UTC
See attached patchset.
Comment 1 Cosimo Cecchi 2015-06-29 21:33:14 UTC
Created attachment 306335 [details] [review]
bijiben: don't call gtk_init()

GtkApplication does this for us.
Comment 2 Cosimo Cecchi 2015-06-29 21:33:17 UTC
Created attachment 306336 [details] [review]
bijiben: add own CSS style for notebooks

Since Adwaita moved to GTK+, it doesn't hold CSS for applications.
Well-behaved applications will only load the Adwaita CSS when the theme
is set to Adwaita; this code was originally written by Matthias Clasen
and is imported from Nautilus.
Comment 3 Cosimo Cecchi 2015-06-29 21:33:20 UTC
Created attachment 306337 [details] [review]
Update libgd

In preparation for next commit.
Comment 4 Cosimo Cecchi 2015-06-29 21:33:23 UTC
Created attachment 306338 [details] [review]
Use cairo surfaces for drawing

Instead of pixbufs. This enables crisp rendering of overview thumbnails
on hidpi displays.
Comment 5 Cosimo Cecchi 2015-06-29 21:33:26 UTC
Created attachment 306339 [details] [review]
notebook: don't fetch list of surfaces twice
Comment 6 Cosimo Cecchi 2015-06-29 21:33:29 UTC
Created attachment 306340 [details] [review]
note-obj: move frame rendering to CSS
Comment 7 Cosimo Cecchi 2015-06-29 21:33:32 UTC
Created attachment 306341 [details] [review]
empty-results-box: fix blurry icon in hi-dpi

Just put the icon in our GResource instead of loading it from disk. Also
don't use the pixbuf loader directly, or we won't get scaling factor and
CSS styling.
Comment 8 Cosimo Cecchi 2015-06-29 21:33:35 UTC
Created attachment 306342 [details] [review]
search-provider: don't return invalid results

Both ID and name have to be non-NULL. Ensure they are.
Comment 9 Cosimo Cecchi 2015-06-30 00:43:18 UTC
Created attachment 306348 [details] [review]
bijiben: don't call gtk_init()

GtkApplication does this for us.
Comment 10 Cosimo Cecchi 2015-06-30 00:43:22 UTC
Created attachment 306349 [details] [review]
bijiben: add own CSS style for notebooks

Since Adwaita moved to GTK+, it doesn't hold CSS for applications.
Well-behaved applications will only load the Adwaita CSS when the theme
is set to Adwaita; this code was originally written by Matthias Clasen
and is imported from Nautilus.
Comment 11 Cosimo Cecchi 2015-06-30 00:43:55 UTC
Created attachment 306350 [details] [review]
Update libgd

In preparation for next commit.
Comment 12 Cosimo Cecchi 2015-06-30 00:44:00 UTC
Created attachment 306351 [details] [review]
Use cairo surfaces for drawing

Instead of pixbufs. This enables crisp rendering of overview thumbnails
on hidpi displays.

This commit also removes the abilty to load and save icons to disk,
since we don't want to cache them while their appearance changes e.g.
due to the theme.
The only consequence for now is that we won't get full icons in the
search provider, but that will be fixed in a later commit.
Comment 13 Cosimo Cecchi 2015-06-30 00:44:04 UTC
Created attachment 306352 [details] [review]
notebook: don't fetch list of surfaces twice
Comment 14 Cosimo Cecchi 2015-06-30 00:44:09 UTC
Created attachment 306353 [details] [review]
empty-results-box: fix blurry icon in hi-dpi

Just put the icon in our GResource instead of loading it from disk. Also
don't use the pixbuf loader directly, or we won't get scaling factor and
CSS styling.
Comment 15 Cosimo Cecchi 2015-06-30 00:44:13 UTC
Created attachment 306354 [details] [review]
search-provider: don't return invalid results

Both ID and name have to be non-NULL. Ensure they are.
Comment 16 Cosimo Cecchi 2015-06-30 00:44:18 UTC
Created attachment 306355 [details] [review]
manager: rework how the manager is constructed

We want to use the manager from the shell search provider, to be able to
load note thumbnails now that we don't save them to disk anymore.
Split it in sync and async constructors using GInitable, and have the
main application still use the async constructor. The search provider
wants all the information loaded upfront so it will use the synchronous
constructor.
Along the way, code was ported to use g_icon_serialize() and many leaks
were fixed.
Comment 17 Cosimo Cecchi 2015-06-30 00:44:41 UTC
Attached a better patchset that also takes care of the search provider icons.
Comment 18 Pierre-Yves Luyten 2015-06-30 22:43:58 UTC
(In reply to Cosimo Cecchi from comment #11)
> Created attachment 306350 [details] [review] [review]
> Update libgd
> 
> In preparation for next commit.

Into libgd, i'm seeing the new method in icon-utils.c, but is the header not updated?

https://git.gnome.org/browse/libgd/commit/?id=1e049c22660d70132a3735d61d7a7daa957b59fc
Comment 19 Pierre-Yves Luyten 2015-06-30 23:00:22 UTC
(In reply to Cosimo Cecchi from comment #6)
> Created attachment 306340 [details] [review] [review]
> note-obj: move frame rendering to CSS

is this one still alive? (because next comment is an obsolete one)
if so, it does add

+ gtk_style_context_add_class (style, "note-emblem");

but 'style' arg is not defined, or I did miss one patch
Comment 20 Pierre-Yves Luyten 2015-06-30 23:01:12 UTC
*** Bug 742365 has been marked as a duplicate of this bug. ***
Comment 21 Cosimo Cecchi 2015-07-01 06:12:02 UTC
(In reply to Pierre-Yves Luyten from comment #18)
> Into libgd, i'm seeing the new method in icon-utils.c, but is the header not
> updated?

Yes sorry, just fixed this. I will update the "Update libgd" patch to include this new commit when pushing this patchset.

(In reply to Pierre-Yves Luyten from comment #19)
> is this one still alive? (because next comment is an obsolete one)
> if so, it does add
> 
> + gtk_style_context_add_class (style, "note-emblem");
> 
> but 'style' arg is not defined, or I did miss one patch

Yeah my bad again. It was indeed obsoleted with the second patchset I attached.
Comment 22 Pierre-Yves Luyten 2015-07-01 09:11:59 UTC
(In reply to Cosimo Cecchi from comment #21)
> (In reply to Pierre-Yves Luyten from comment #18)
> > Into libgd, i'm seeing the new method in icon-utils.c, but is the header not
> > updated?
> 
> Yes sorry, just fixed this. I will update the "Update libgd" patch to
> include this new commit when pushing this patchset.
> 

Since you fixed libgd, I can update bijiben to latest.

Actually first tests yesterday without the recently updated commit went fine. I'm only testing using GDK_SCALE but I shall push this tonight.
Comment 23 Pierre-Yves Luyten 2015-07-01 20:09:27 UTC
this is now pushed, thanks also for the additional improvements you did work on.

(I'm not sure I can test shell provider icons using GDK_SCALE but anyway this is using the same function now, which is quite a great fix!)