diff options
| author | MaxVerevkin <maxxverrr@gmail.com> | 2022-08-25 16:40:44 +0300 |
|---|---|---|
| committer | MaxVerevkin <maxxverrr@gmail.com> | 2022-08-25 16:46:43 +0300 |
| commit | 39cc147656e2f61f7467f4b67b4c76fd9207c2f6 (patch) | |
| tree | f3108c44cfc24896787b6067a710d8556a85e459 /src/bar.rs | |
| parent | b154262dcbf0d1a5686921f24eb0b0c41ed95f29 (diff) | |
| download | i3bar-mango-39cc147656e2f61f7467f4b67b4c76fd9207c2f6.tar.gz | |
do not clone fonts
Diffstat (limited to 'src/bar.rs')
| -rw-r--r-- | src/bar.rs | 11 |
1 files changed, 4 insertions, 7 deletions
@@ -129,11 +129,8 @@ impl Bar { if self.tags_computed.is_empty() { // TODO make configurable for text in ["1", "2", "3", "4", "5", "6", "7", "8", "9"] { - self.tags_computed.push(compute_tag_label( - text, - ss.config.font.clone(), - &cairo_ctx, - )); + self.tags_computed + .push(compute_tag_label(text, &ss.config.font, &cairo_ctx)); } } self.tags_btns.clear(); @@ -225,7 +222,7 @@ fn render_blocks( text::ComputedText::new( &block.full_text, text::Attributes { - font: config.font.clone(), + font: &config.font, padding_left: 0.0, padding_right: 0.0, min_width, @@ -241,7 +238,7 @@ fn render_blocks( text::ComputedText::new( short_text, text::Attributes { - font: config.font.clone(), + font: &config.font, padding_left: 0.0, padding_right: 0.0, min_width, |
