From: Paul Hänsch Date: Tue, 10 Dec 2019 03:37:11 +0000 (+0100) Subject: Improved line breaking hack for addresses X-Git-Url: https://git.plutz.net/?a=commitdiff_plain;h=2da546d1f8d234620abaa002fe4a417aad0e868c;p=lobster Improved line breaking hack for addresses --- diff --git a/cards/widgets.sh b/cards/widgets.sh index a3836bf..35086eb 100755 --- a/cards/widgets.sh +++ b/cards/widgets.sh @@ -133,9 +133,10 @@ card_item(){ done ;; *)[ $cnt -gt 0 ] && printf '[h3 %s]' "$(l10n "$item")" + shy="$(printf '\302\255')" seq 1 $cnt |while read c; do printf '[span .item .%s . %s]' "$item" \ - "$(pdi_value "$card" "$item" $c |unescape |HTML)" + "$(pdi_value "$card" "$item" $c |sed -r "s;(straße|weg|damm|allee|ufer);${shy}\1;g" |unescape |HTML)" done ;; esac