Skip to content

Commit bddee40

Browse files
committed
fix clippy
1 parent 8ebcd81 commit bddee40

1 file changed

Lines changed: 12 additions & 5 deletions

File tree

src/main.rs

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -564,11 +564,18 @@ fn main() -> std::io::Result<()> {
564564
let settings = cli::Cli::parse();
565565

566566
if settings.display_group {
567-
let extra_width = match settings.group.0.name {
568-
ezemoji::GroupKind::Custom("OpenSource") => true,
569-
ezemoji::GroupKind::Custom("ProgrammingLanguages") => true,
570-
_ => false,
571-
};
567+
// These two groups don't render right if they dont have enough space.
568+
// From what I have found Unicode characters with
569+
// U+FE0E = text style (forces small).
570+
// U+FE0F = emoji style (forces larger).
571+
// but for something in the opensource group char if there is an space next to the char it will
572+
// visibly expand.
573+
// example:  .
574+
let extra_width = matches!(
575+
settings.group.0.name,
576+
ezemoji::GroupKind::Custom("OpenSource")
577+
| ezemoji::GroupKind::Custom("ProgrammingLanguages")
578+
);
572579
for char in settings.group.0.iter() {
573580
print!("{char}");
574581
if extra_width {

0 commit comments

Comments
 (0)