aboutsummaryrefslogtreecommitdiff
path: root/src/layout
diff options
context:
space:
mode:
Diffstat (limited to 'src/layout')
-rw-r--r--src/layout/tab_indicator.rs11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/layout/tab_indicator.rs b/src/layout/tab_indicator.rs
index 182934ad..08bde63c 100644
--- a/src/layout/tab_indicator.rs
+++ b/src/layout/tab_indicator.rs
@@ -10,7 +10,9 @@ use crate::animation::{Animation, Clock};
use crate::niri_render_elements;
use crate::render_helpers::border::BorderRenderElement;
use crate::render_helpers::renderer::NiriRenderer;
-use crate::utils::{floor_logical_in_physical_max1, round_logical_in_physical};
+use crate::utils::{
+ floor_logical_in_physical_max1, round_logical_in_physical, round_logical_in_physical_max1,
+};
#[derive(Debug)]
pub struct TabIndicator {
@@ -77,12 +79,13 @@ impl TabIndicator {
scale: f64,
) -> impl Iterator<Item = Rectangle<f64, Logical>> {
let round = |logical: f64| round_logical_in_physical(scale, logical);
+ let round_max1 = |logical: f64| round_logical_in_physical_max1(scale, logical);
let progress = self.open_anim.as_ref().map_or(1., |a| a.value().max(0.));
- let width = round(self.config.width.0);
- let gap = round(self.config.gap.0);
- let gaps_between = round(self.config.gaps_between_tabs.0);
+ let width = round_max1(self.config.width.0);
+ let gap = round_max1(self.config.gap.0);
+ let gaps_between = round_max1(self.config.gaps_between_tabs.0);
let position = self.config.position;
let side = match position {