In emacs use google's  c-style settings
add .emacs tweaks

tips from https://sites.google.com/site/steveyegge2/effective-emacs