Fixed problem with "preview" command: regeneration was erratic