Subject: Re: bug#78298: [PATCH] Scroll with mouse wheel in calendar

From: Manuel Giraud <[email-masked]>
Date: Wed, 14 May 2025 13:50:54 +0200

Juri Linkov <[email-masked]> writes:

>>> Or was it not even consistent before your patch?  I see that <next> is
>>> bound to `calendar-scroll-left-three-months' and C-x ] to
>>> `calendar-forward-year'.  Your patch didn't touch these.  Did these
>>> already behave differently?
>>
>> Yes, they behave differently.  AFAIU, for scrolling: while the date
>> under the cursor is visible, the cursor is placed there after the
>> scroll.  When the date is not visible anymore, the cursor is placed on
>> the first day of the month.
>
> With placing the cursor on the first day of the month
> the behavior makes sense.  But only for months, not years.
>
> When scrolling years the need is to put the cursor
> exactly on the same day/month in another year.

Yes that also makes sense.  Any other opinion on this matter?  To
summarize the choices are:

          1) More code (new commands) but make year scrolling consistent
             with other scrolling (i.e. place the cursor on the first
             day of the month when the date is not visible anymore
             (note: this is always the case for year scroll))

          2) Less code (reuse calendar-[for|back]ward-year) but year
             scrolling is not consistent with other scrolling
-- 
Manuel Giraud