Add Shape Optimization frequency option, fix bug

Fix focus drawing bug.