Skip to content

System Integration

zufuliu edited this page Jan 5, 2024 · 15 revisions

⚠WARNING: modify system integration requires Administrator privileges. After run Notepad2.exe or metapath.exe as Administrator:

For Notepad2, click menu "Settings" -> "Advanced Settings" -> "System Integration...".

For metapath, click context menu "Options...", then click "Locations" (the last tab).

System Integration

Following system integration are based on the article Notepad2 ― Replacing Windows Notepad by Florian. See Command Line Switches for how to configure Notepad2 as external tool for other applications.

Add Notepad2 or metapath to Windows Explorer's Context Menu

For Notepad2, when checked, following registries are added:

HKEY_CLASSES_ROOT\*\shell\Notepad2
    (Default)               REG_SZ      Edit with Notepad2
    icon                    REG_SZ      Notepad2.exe
    command
        (Default)           REG_SZ      "Notepad2.exe" "%1"

for metapath, when checked, following registries are added:

HKEY_CLASSES_ROOT\Folder\shell\metapath
    (Default)               REG_SZ      Open in metapath
    icon                    REG_SZ      metapath.exe
    command
        (Default)           REG_SZ      "metapath.exe" "%1"

where Edit with Notepad2 or Open in metapath is the "Context menu text" field on System Integration dialog; Notepad2.exe or metapath.exe is the full path to Notepad2.exe or metapath.exe.

💡Note 1: Official Notepad2 and Notepad2-mod adds registries to HKEY_CLASSES_ROOT\*\shell\Notepad2.exe, which has .exe suffix. If you installed them before, you may end up with two "Edit with Notepad2" context menus.

💡Note 2: On Windows XP, app may fail to remove this integration when this option is unchecked, in this case, please run regedit.exe manually, then delete HKEY_CLASSES_ROOT\*\shell\Notepad2 or HKEY_CLASSES_ROOT\Folder\shell\metapath.

Enable Taskbar Jump List

For Notepad2, when checked, following registries are added:

HKEY_CLASSES_ROOT\Applications\Notepad2.exe
    AppUserModelID          REG_SZ      Notepad2 Text Editor
    FriendlyAppName         REG_SZ      Notepad2 Text Editor
    shell\open\command
        (Default)           REG_SZ      "Notepad2.exe" "%1"

for metapath, when checked, following registries are added:

HKEY_CLASSES_ROOT\Applications\metapath.exe
    AppUserModelID          REG_SZ      metapath File Browser
    FriendlyAppName         REG_SZ      metapath File Browser
    shell\open\command
        (Default)           REG_SZ      "metapath.exe" "%1"

where AppUserModelID is the ShellAppUserModelID preference (in Settings2 section), see https://docs.microsoft.com/en-us/windows/win32/shell/appids for the usage. FriendlyAppName is the "Application name" field on System Integration dialog.

💡Note 1: For Notepad2, enable Jump List will enable using system MRU (the ShellUseSystemMRU preference in Settings2 section, default enabled).

💡Note 2: Taskbar Jump List for metapath currently not work, but this option can be used to change app name for metapath's taskbar icon.

💡Note 3: On Windows XP, app may fail to remove this integration when this option is unchecked, in this case, please run regedit.exe manually, then delete HKEY_CLASSES_ROOT\Applications\Notepad2.exe or HKEY_CLASSES_ROOT\Applications\metapath.exe.

Replace Windows Notepad via registry

For Notepad2 only, when checked, following registries are added:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\notepad.exe
    (Default)                               REG_SZ      Notepad2.exe
    Debugger                                REG_SZ      "Notepad2.exe" /z
    UseFilter                               REG_DWORD   0