This works to change the background color for the entire terminal with xterm:
printf '\033]10;%s\a\033]11;%s\a' Blue Red
It doesn't work in xfce4-terminal, tho. Is there something that will work? Note, I want a command line solution.
It's not possible with the current version of xfce-terminal (4.12), since it uses an ancient, Gtk+2-based vte for terminal emulation. You should wait until they port their code to the new, Gtk+3-based vte, or switch to another terminal emulator (e.g. gnome-terminal).