记事本状态栏不会自动
The status bar in Windows’ Notepad displays the current line number and column number of the cursor location. However, if you find that the Status Bar option on the View menu is grayed out, it may be because you have Word Wrap enabled.
Windows记事本中的状态栏显示光标位置的当前行号和列号。 但是,如果您发现“视图”菜单上的“状态栏”选项显示为灰色,则可能是因为您启用了“自动换行”功能。
If you’ve enabled word wrap, which keeps your columns restricted to the Notepad window, you cannot also enable the status bar. That is because word wrap screws up line breaks, making the line number and column number on the status bar not accurate all the time.
如果启用了自动换行,使您的列限制在“记事本”窗口中,则也无法启用状态栏。 这是因为自动换行会打断换行符,从而使状态栏上的行号和列号始终不准确。
However, if you want to enable the status bar anyway, despite its possible inaccuracy, we’ll show you an easy trick to make the status bar option available even when word wrap is on.
但是,如果您仍然想启用状态栏,尽管它可能存在误差,我们将向您展示一个简单的技巧,即使打开自动换行功能,也可以使状态栏选项可用。
Standard warning: This procedure involves making changes to the Registry Editor, which is a powerful tool. Using the Registry Editor incorrectly can render your system unstable or even inoperable. This is a pretty simple hack and as long as you follow the instructions carefully, you shouldn’t have any problems. That said, if you’ve never worked with it before, consider reading about how to use the Registry Editor before you get started. And definitely back up the Registry (and your computer!) before making changes.
标准警告:此过程涉及更改注册表编辑器,它是一个功能强大的工具。 错误地使用注册表编辑器会使您的系统不稳定甚至无法运行。 这是一个非常简单的技巧,只要您仔细按照说明进行操作,就不会有任何问题。 也就是说,如果您以前从未使用过它,请在开始之前考虑阅读有关如何使用注册表编辑器的信息。 并在进行更改之前一定要备份注册表(和您的计算机!)。
Open the Registry Editor by clicking on Start and typing “regedit.” Press Enter to open Registry Editor, or click on regedit under Best match.
通过单击开始并键入“ regedit”,打开注册表编辑器。 按Enter打开注册表编辑器,或单击“最佳匹配”下的regedit。
Give regedit permission to make changes to your PC.
授予regedit权限以对您的PC进行更改。
NOTE: You may not see this dialog box, depending on your User Account Control settings.
注意:根据您的“用户帐户控制”设置,您可能看不到此对话框。
In the tree structure on the left, navigate to the following key:
在左侧的树结构中,导航到以下键:
HKEY_CURRENT_USER\Software\Microsoft\Notepad
The Notepad key stores all the settings for Notepad. In Notepad’s initial state, the only values for that key are window position values. Notice that there are no values for the word wrap and status bar settings. Leave the Registry Editor open.
记事本键存储记事本的所有设置。 在记事本的初始状态下,该键的唯一值是窗口位置值。 请注意,自动换行和状态栏设置没有任何值。 使注册表编辑器保持打开状态。
Open Notepad and turn on “Word Wrap” in the Format menu. This adds the word wrap ( fWrap
) and status bar ( StatusBar
) values to the Notepad key in the registry.
打开记事本,然后在“格式”菜单中打开“自动换行”。 这会将自动换行( fWrap
)和状态栏( StatusBar
)值添加到注册表中的记事本项。
Notice that the status bar goes away and the “Status Bar” option in the View menu is grayed out. Close Notepad to save these settings into the Notepad registry key.
请注意,状态栏消失了,“视图”菜单中的“状态栏”选项显示为灰色。 关闭记事本以将这些设置保存到记事本注册表项中。
Now, the fWrap
and StatusBar
keys have been added to the Notepad key. Currently, the StatusBar
value has zero as it’s value data, indicating it’s disabled. Double-click on the StatusBar
value.
现在, fWrap
和StatusBar
键已添加到记事本键。 当前, StatusBar
值的值数据为零,表示已禁用。 双击StatusBar
值。
On the Edit DWORD (32-bit) Value dialog box, enter 1
in the “Value data” edit box and click “OK”.
在“编辑DWORD(32位)值”对话框中,在“值数据”编辑框中输入1
,然后单击“确定”。
Close the Registry Editor by selecting “Exit” from the File menu.
通过从文件菜单中选择“退出”,关闭注册表编辑器。
Now, word wrap and the status bar are enabled at the same time. However, If you turn off word wrap and then turn it back on, the status bar will be disabled again. You must set the StatusBar
value to 1
again to be able to have both enabled.
现在,自动换行和状态栏同时启用。 但是,如果关闭自动换行然后再打开,状态栏将再次被禁用。 您必须再次将StatusBar
值设置为1
才能同时启用它们。
If you want to put word wrap and the status bar back to their normal settings, reset Notepad. Simply changing the value of the StatusBar value back to zero only seems to confuse Notepad and the values and what’s set in Notepad won’t necessarily match.
如果要将自动换行和状态栏恢复为正常设置,请重置记事本。 仅将StatusBar值的值更改回零似乎只会使记事本感到困惑,并且记事本中的值和设置不一定会匹配。
翻译自: https://www.howtogeek.com/256491/how-to-enable-the-status-bar-and-word-wrap-at-the-same-time-in-notepad/
记事本状态栏不会自动