changes internal option handling + some fixes