MalpenZibo / ashell

A ready to go Wayland status bar for Hyprland
MIT License
48 stars 4 forks source link

Fix title panic #65

Closed leftas closed 1 week ago

leftas commented 1 week ago

Sadly, I can make this diff a little bit nicer (just merging into my previous branch, instead of the main one) as I cannot put this PR in your repo when targeting my other PR, so you will have to ignore that noise, haha.

There was this special case when the substring was made in the middle of the symbol's codepoint(s) - rust just panics and returns an error: "byte index X is not a char boundary". As I understand that's the easiest way to solve this (numbering by codepoints and then taking the symbol's byte index). Pardon me, if that's not the right way - Rust is not my main language.

leftas commented 1 week ago

Fixed in https://github.com/MalpenZibo/ashell/pull/64