#1 Made the settings cashe buffer local.

Also commited to the folding standard many plugin use.