在记事本++中立即更改标签大小 [英] In notepad++ change tab size instantly

查看:104
本文介绍了在记事本++中立即更改标签大小的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用的是notepad ++(v6.5.3),我经常需要更改选项卡的大小才能查看一些结果.并不是每次都要花很多时间手动进行操作,但是如果我可以对其进行优化,那就太好了.
有办法吗?宏将是解决方案,还是仅用于输入内容?

I'm using notepad++ (v6.5.3) and I constantly have to change the size of the tab for viewing some results. Not that it's taking me a lot of time to do it manually everytime, but it would be great if I could optimize that.
Is there a way to do so? Would a macro be the solution, or are they just for typing stuff?

非常感谢!

推荐答案

好的,有一种简单的方法可以实现此目的-我现在已经对其进行了测试:

Ok, there's an easy way how you can achieve this - I have tested it right now:

  1. 安装 AutoHotKey (或启动无需安装即可运行的便携式版本)
  2. 在Windows 7及更高版本中,请确保您以管理员身份启动了 (否则,您的行为会出现不一致的情况)-如果不确定,请退出并以管理员身份重新启动
  3. 右键单击自动热键任务栏图标,然后选择Edit This Script
  4. 在AutoHotKey脚本文件的末尾导入此列表下方的宏并保存文件
  5. 右键单击自动热键任务栏图标,然后选择Reload This Script.
    -这是常规步骤的结尾,现在让我们使用您的宏:-

  1. Install AutoHotKey (or start portable version which runs without installation)
  2. In Windows 7 and above, ensure you launched AutoHotKey as Administrator (otherwise you get inconsistencies in its behavior) - if not sure, exit it and restart it as administrator
  3. Right click Autohotkey tray icon and select Edit This Script
  4. Import the macro below this list at the end of the AutoHotKey script file and save the file
  5. Right click Autohotkey tray icon and select Reload This Script.
    –– This was end of general steps, now let's go with your macro: ––

在N ++中,显示Preferences窗口,然后按其底部的关闭按钮 1 (不位于右上角)

In N++, display Preferences window and press its Close button1 at the bottom (NOT at the top-right corner)

现在您可以使用快捷键 Win + F2 Win + F3 即时切换不同的选项卡大小

Now you can use shortcuts Win+F2 and Win+F3 to switch different tab sizes instantly


    SendMode Input
    DetectHiddenWindows, On
    SetTitleMatchMode, RegEx

    ;--------------------------------- Hotkeys for Notepad++ only
    #IfWinActive ahk_class Notepad\+\+

    #F2::Send {F10}{Right 6}{Down}{Enter}{Tab 2}{Space}16{Enter}{Tab 3}{Space}
    #F3::Send {F10}{Right 6}{Down}{Enter}{Tab 2}{Space}4{Enter}{Tab 3}{Space}

    #IfWinActive

1 )重要:对话框中提供的N ++用户体验绝对是糟糕.使用键盘时,没有可以固定焦点的锚点.因此,您总是需要在离开Preferences对话框时手动执行step 4 ,否则宏会将键发送到错误的窗口页面或正确的页面,但控制不正确. Preferences对话框窗口会记住所选的页面和控件.因此,我为您创建的宏假定已经列出了正确的页面,并且按钮关闭最近已着眼.
好消息是,具有这种奇怪行为的Notepad ++窗口在一般用户体验中很少出现.在N ++(或其他应用程序)的其他地方,用户界面组件(菜单,对话框等)总是从同一点开始,您不需要采取任何特殊的预防措施,例如步骤中的预防措施4 .

1) Important: N++ user experience provided in dialog boxes is absolutely terrible. There are no anchors where you can fix focus when using keyboard. Thus you always need to perform step 4 manually when leaving Preferences dialog box otherwise the macros would send keys into incorect window page OR at correct page but incorrect control. Preferences dialog window remembers selected page and control. Macros I created for you therefore assume that correct page is already listed and button Close was recently focused.
Good news is Notepad++ windows with this weird behavior are rare exception from general user experience. In other places in N++ (or in other apps) where user interface components (menus, dialogs etc.) always start from the same point you do not need any special precautions like the one in step 4.

根据需要调整宏:

  • 您可以创建更多的
  • 您可以调整在标签大小输入框中键入的数字"16"和"4"
  • 您可以将快捷键更改为其他内容
  • 您可以将发送键替换为在所需的屏幕/窗口位置发送鼠标点击
  • 您可以在N ++和所有其他应用程序中实现许多其他有用的快捷方式–深入检查AHK!

这篇关于在记事本++中立即更改标签大小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆