various features and fixes