aboutsummaryrefslogtreecommitdiff
path: root/alacritty/src/renderer/mod.rs
diff options
context:
space:
mode:
authorChristian Duerr <contact@christianduerr.com>2021-07-03 03:06:52 +0000
committerGitHub <noreply@github.com>2021-07-03 03:06:52 +0000
commit4dd70ba3a155d1eebe38bcd5a5c4c03ca09f2fea (patch)
tree5fd25b77c2d46279cf3e23b699d47e06f02d43e4 /alacritty/src/renderer/mod.rs
parentb0bc2a2440287268ca47ecf618c73766db9a2586 (diff)
downloadr-alacritty-4dd70ba3a155d1eebe38bcd5a5c4c03ca09f2fea.tar.gz
r-alacritty-4dd70ba3a155d1eebe38bcd5a5c4c03ca09f2fea.tar.bz2
r-alacritty-4dd70ba3a155d1eebe38bcd5a5c4c03ca09f2fea.zip
Fix clippy warnings
Diffstat (limited to 'alacritty/src/renderer/mod.rs')
-rw-r--r--alacritty/src/renderer/mod.rs10
1 files changed, 5 insertions, 5 deletions
diff --git a/alacritty/src/renderer/mod.rs b/alacritty/src/renderer/mod.rs
index 48fcbf20..5f71ddf5 100644
--- a/alacritty/src/renderer/mod.rs
+++ b/alacritty/src/renderer/mod.rs
@@ -191,7 +191,7 @@ impl GlyphCache {
let size = font.size();
// Load regular font.
- let regular_desc = Self::make_desc(&font.normal(), Slant::Normal, Weight::Normal);
+ let regular_desc = Self::make_desc(font.normal(), Slant::Normal, Weight::Normal);
let regular = Self::load_regular_font(rasterizer, &regular_desc, size)?;
@@ -233,7 +233,7 @@ impl GlyphCache {
error!("{}", err);
let fallback_desc =
- Self::make_desc(&Font::default().normal(), Slant::Normal, Weight::Normal);
+ Self::make_desc(Font::default().normal(), Slant::Normal, Weight::Normal);
rasterizer.load_font(&fallback_desc, size)
},
}
@@ -372,7 +372,7 @@ impl GlyphCache {
/// Calculate font metrics without access to a glyph cache.
pub fn static_metrics(font: Font, dpr: f64) -> Result<crossfont::Metrics, crossfont::Error> {
let mut rasterizer = crossfont::Rasterizer::new(dpr as f32, font.use_thin_strokes)?;
- let regular_desc = GlyphCache::make_desc(&font.normal(), Slant::Normal, Weight::Normal);
+ let regular_desc = GlyphCache::make_desc(font.normal(), Slant::Normal, Weight::Normal);
let regular = Self::load_regular_font(&mut rasterizer, &regular_desc, font.size())?;
rasterizer.get_glyph(GlyphKey { font_key: regular, character: 'm', size: font.size() })?;
@@ -1306,12 +1306,12 @@ impl Atlas {
}
// If there's not enough room in current row, go onto next one.
- if !self.room_in_row(&glyph) {
+ if !self.room_in_row(glyph) {
self.advance_row()?;
}
// If there's still not room, there's nothing that can be done here..
- if !self.room_in_row(&glyph) {
+ if !self.room_in_row(glyph) {
return Err(AtlasInsertError::Full);
}