Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Alexander Mikhaylenko
libhandy
Commits
879cf300
Commit
879cf300
authored
May 21, 2020
by
Alexander Mikhaylenko
Browse files
header-bar: Account for box-shadow when clipping
Fixes
Librem5/libhandy#274
parent
87c0b2d6
Pipeline
#55455
passed with stages
in 14 minutes and 9 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/hdy-header-bar.c
View file @
879cf300
...
...
@@ -1431,6 +1431,7 @@ hdy_header_bar_size_allocate (GtkWidget *widget,
HdyHeaderBarPrivate
*
priv
=
hdy_header_bar_get_instance_private
(
self
);
GtkAllocation
*
allocations
;
GtkAllocation
title_allocation
;
GtkAllocation
clip
;
gint
nvis_children
;
GList
*
l
;
gint
i
;
...
...
@@ -1443,6 +1444,13 @@ hdy_header_bar_size_allocate (GtkWidget *widget,
GtkWidget
*
decoration_box
[
2
]
=
{
priv
->
titlebar_start_box
,
priv
->
titlebar_end_box
};
gint
decoration_width
[
2
]
=
{
0
};
gtk_render_background_get_clip
(
gtk_widget_get_style_context
(
widget
),
allocation
->
x
,
allocation
->
y
,
allocation
->
width
,
allocation
->
height
,
&
clip
);
gtk_widget_set_allocation
(
widget
,
allocation
);
if
(
gtk_widget_get_realized
(
widget
))
...
...
@@ -1557,6 +1565,8 @@ hdy_header_bar_size_allocate (GtkWidget *widget,
gtk_widget_size_allocate
(
priv
->
custom_title
,
&
title_allocation
);
else
if
(
priv
->
label_box
!=
NULL
)
gtk_widget_size_allocate
(
priv
->
label_box
,
&
title_allocation
);
gtk_widget_set_clip
(
widget
,
&
clip
);
}
static
void
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment