• Login
Community
  • Login

I want to prevent the font size from changing with the mouse wheel

Scheduled Pinned Locked Moved General Discussion
4 Posts 3 Posters 576 Views
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S
    s s
    last edited by Nov 28, 2022, 11:37 AM

    I am using a fast scrolling mouse.
    While using the shortcut key that uses the Ctrl button, scrolling is moving, and it often happens that the character size of Notepad++ changes.

    Is it possible to fix the font size?

    M 1 Reply Last reply Nov 28, 2022, 12:12 PM Reply Quote 0
    • M
      Michael Vincent @s s
      last edited by Nov 28, 2022, 12:12 PM

      @s-s

      Zoom Disabler

      Cheers.

      A S 2 Replies Last reply Nov 28, 2022, 1:26 PM Reply Quote 3
      • A
        Alan Kilborn @Michael Vincent
        last edited by Nov 28, 2022, 1:26 PM

        @Michael-Vincent

        I had a look at the Zoom Disabler plugin code.
        It’s logic seems to be:

        • get notified that user has changed the zoom level
        • correct for that by setting a different zoom level

        I tried duplicating that in a PythonScript and, although it works, it is a bit visually glitchy:

        # -*- coding: utf-8 -*-
        
        from Npp import Editor, SCINTILLANOTIFICATION
        
        #-------------------------------------------------------------------------------
        
        class ZoomDisabler(object):
        
            def __init__(self):
                editor.callback(self.zoom_callback, [SCINTILLANOTIFICATION.ZOOM])
        
            def zoom_callback(self, args):
                editor.setZoom(0)
        
        #-------------------------------------------------------------------------------
        
        if __name__ == '__main__': ZoomDisabler()
        

        I’m not going to try the actual Zoom Disabler plugin, but I’d think it would be visually glitchy as well.

        1 Reply Last reply Reply Quote 2
        • S
          s s @Michael Vincent
          last edited by Nov 29, 2022, 5:07 PM

          @Michael-Vincent
          Wow, I didn’t know there was such a plugin.
          thank you very much. solved.

          1 Reply Last reply Reply Quote 0
          4 out of 4
          • First post
            4/4
            Last post
          The Community of users of the Notepad++ text editor.
          Powered by NodeBB | Contributors