Skip to content

Commit

Permalink
Merge pull request #245 from umurgdk/fix-x11-hidpi
Browse files Browse the repository at this point in the history
Fixes window inner size calc for hidpi windows X11
  • Loading branch information
tomaka authored Jul 27, 2017
2 parents 3b7dbd0 + d65d995 commit 45c5568
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/platform/linux/x11/window.rs
Original file line number Diff line number Diff line change
Expand Up @@ -535,7 +535,7 @@ impl Window {

#[inline]
pub fn get_inner_size(&self) -> Option<(u32, u32)> {
self.get_geometry().map(|(_, _, w, h, _)| (w, h))
self.get_geometry().map(|(_, _, w, h, _)| ((w as f32 / self.hidpi_factor()) as u32, (h as f32 / self.hidpi_factor()) as u32))
}

#[inline]
Expand Down

0 comments on commit 45c5568

Please sign in to comment.