When the user is looking at a given month in the calendar, you want all events that overlap that month. For example, if you have a non-repeating event that starts in the previous month and ends on the following month, it overlaps the month that is between.
The way I would do it is get the set of events that (1) start before the end of the month to be displayed, and (2) end after the beginning of the month to be displayed. For the purposes of this query, repeating events should be considered to start on their first instance and end at the end of their last instance. If they are repeating "forever", then you can treat the last instance as some date in the far future.
The disadvantage of this approach is that you can end up having to examine every repeating event (e.g. every birthday) on every search. Expanding the set of repeating event instances works too, but it can be more complicated.