I've been watching since season 1 and I too was wondering how they were going to write a season 5 with Dexter "stuck" in a family situation. Another year of him dodging Rita would have been pretty repetitive. But I never expected her to get killed off. My jaw hit the floor when that happened. I actually thought it was another dream sequence until the end credits rolled.
Unless the writers come up with something big, I can't see Dexter going to a season 7. Next year is pretty easy - he deals with the loss. But what are they going to do for season 7? After the dramatic changes to Dexter's character from seasons 1 - (upcoming) 5, I'm not sure where else he can go other than full circle and starting over again, and I don't expect many people to stick around for that.
I love Dexter and I thought this season was the best by far. But with Rita's murder, I think the show has jumped the shark. Not in the cheesy Fonzie way, but I think the show has peaked. I hope I'm wrong, though.