fixed codemirror styles + function to calculate sql editor size