Fixing up the code for persistent style, removed all realtime stuff for now as they break the code.