Several tweaks and fixes.