slightly better attribute selection logic but still pretty b0rked

Don't merge yet, mostly here for reference.
could it be that there's more than one line selected here? e.g. `selStart = [0,5]; selEnd = [1,5]`