BTS

Message3731

Author btittelbach
Recipients btittelbach, uli1
Date 2011-04-19.20:41:39
Content
.zshrc's info_print concatenates strings and always appends a space at each
string. Consequently, there is one space too many at the end of the resulting
window or screen title.

In screen this additional space per windows eats up a lot of space on the
hardstatus line, when lot's of windows are in use.

the for loop in info_print should propably be replaced by a
printf '%s' "${(j: :)@}"
or a
printf '%s' "$*"
if that doesn't break anything else..

e.g.:
function info_print () {
     local esc_begin esc_end
     esc_begin="$1"
     esc_end="$2"
     shift 2
     printf '%s' ${esc_begin}
-    for item in "$@" ; do
-        printf '%s ' "$item"
-    done
+    printf '%s' "${(j: :)@}"
     printf '%s' "${esc_end}"
History
Date User Action Args
2011-04-19 20:41:40btittelbachsetrecipients: + btittelbach, uli1
2011-04-19 20:41:40btittelbachsetmessageid: <1303245700.22.0.5368349828.issue979@bts.grml.org>
2011-04-19 20:41:40btittelbachlinkissue979 messages
2011-04-19 20:41:39btittelbachcreate