diff --git a/voxygen/src/ui/widgets/slot.rs b/voxygen/src/ui/widgets/slot.rs index 3975bc1a62..9a9656220d 100644 --- a/voxygen/src/ui/widgets/slot.rs +++ b/voxygen/src/ui/widgets/slot.rs @@ -698,7 +698,12 @@ where // Draw amount if let Some(amount) = amount { - let amount = format!("{}", &amount); + let amount = match amount { + amount if amount > 1_000_000_000 => format!("{}G", amount / 1_000_000_000), + amount if amount > 1_000_000 => format!("{}M", amount / 1_000_000), + amount if amount > 1_000 => format!("{}K", amount / 1_000), + amount => format!("{}", amount), + }; // Text shadow Text::new(&amount) .font_id(amount_font)