And of course, if you want to feed it a variable title like
Branch Delay did, you can do it like this (also stuffed into a function like he used):
PHP Code:
title() {
VAL="{\"titleBar\":{\"clientParams\":{\"primary\":\"$@\"}}}"
lipc-set-prop com.lab126.chromebar configureChrome "$VAL"
}
title Hello world!; sleep 3; title "This;is;quoted."
Much like 'echo', quotes are not needed except for some special chars like ';' or '$(', if we use the '$@' parameter instead of '$1'. But still safest to use quotes (and even then some things need a '\' to escape them);
I tried putting a
Lenny Face ( ͡° ͜ʖ ͡°) on the title bar, but it does not pack the combined characters together, so the face is broken. However, if you want to try it anyway, here:
PHP Code:
title "\u0028\u0020\u0361\u00B0\u0020\u0035C\u0296\u0020\u0361\u00B0\u0029"
My PW2 required those extra zeroes (4-digit UTF-8).