migrated functionality to Spreadsheet::getSelectedExtent