Hi Julian,
Just today I noted that you added Zooming using Ctrl + MouseWheel (wpZoomWithMouseWheel in EditOptionsEx), but unfortunately I saw a different behavior from others applications, like MSWord, IE and Firefox. In your code, it will fire the zooming change if Ctrl is pressed, instead of if ONLY Ctrl is pressed. It means that if I use Ctrl + Shift + Alt + MouseWheel it will also fire the zooming change.
I don't know if it was the intentional behavior or just a miss but, anyway, is it something that could be changed, or overwritten, maybe using another $IFDEF?
You have this:
if not Result and (wpZoomWithMouseWheel in EditOptionsEx) and (GetAsyncKeyState(VK_CONTROL) < 0) then begin
Should be this (only Ctrl):
Or this (using $IFDEF):
if not Result and
(wpZoomWithMouseWheel in EditOptionsEx) and
{$IFNDEF CTRL_ONLY_MOUSEWHEEL_ZOOMING}(GetAsyncKeyState(VK_CONTROL) < 0){$ELSE}(Shift = [ssCtrl]){$ENDIF}
then
begin
I also noted that the zooming change is not as smooth it appears. In your code you update the zooming by 2, if it smaller than 100%, and by 10 if greater. But instead of this, it fires a lot more. In my tests, it updates by 14 if smaller than 100% and by 70 if greater! MSWord for instance uses 10, always. Besides solving this problem, these values could be made properties, or creating global variables so I could use my own values?
And also, if I'm using other zooming than wpAutoZoomOff, it doesn't fire the changing. I guess this was intentional.
Thanks for your help
Alessandro Fragnani