Jump to content

Porting Snipping Tool to Windows 7 from Windows 10


InterLinked

Recommended Posts

Any thoughts on porting the Snipping Tool from Windows 10 to Windows 7?

Pretty much everything about Windows 10 sucks in comparison to Windows 7, but the nifty "Delay" feature of its snipping tool is quite useful, have to hand it to them. I'll commend them when they do something well and criticize them when they screw literally everything else up.

Obviously, the delay feature isn't worth downgrading to Windows 10 for, so is there any feasible way of porting it that people have figured out?

I went down the Dependency Walker rabbit hole a while back but when I copied everything over it, it didn't work, and just said it was not a valid Win32 application. So I'm unsure what they've done or how they could have modded the tool so much that it's not even recognized as Win32 anymore.

Link to comment
Share on other sites


Assuming dependencies are satisfied, you have to modify the .exe so it doesn't specify minimum required OS version as 10.0 using a tool such as CFF Explorer. If I remember correctly, you're looking for MajorOSVersion/MinorOSVersion and MajorSubsystemVersion/MinorSubsystemVersion, they have to be modified to target 6.1 instead of 10.0.

It'll probably also need MUI files carried over before it'll work, but I can't say more ATM as I'm not on computer.

PS: that error message is misleading, you have to upgrade to Windows 95 to get more accurate error message.

Edited by UCyborg
Link to comment
Share on other sites

6 hours ago, UCyborg said:

Assuming dependencies are satisfied, you have to modify the .exe so it doesn't specify minimum required OS version as 10.0 using a tool such as CFF Explorer. If I remember correctly, you're looking for MajorOSVersion/MinorOSVersion and MajorSubsystemVersion/MinorSubsystemVersion, they have to be modified to target 6.1 instead of 10.0.

 

I guess that would make sense... so all I need to mod is the exe? No DLLs or anything?

 

6 hours ago, UCyborg said:

It'll probably also need MUI files carried over before it'll work, but I can't say more ATM as I'm not on computer.

 

What are these? I don't use different language packs, just English

 

6 hours ago, UCyborg said:

PS: that error message is misleading, you have to upgrade to Windows 95 to get more accurate error message.

Huh?

Link to comment
Share on other sites

1 hour ago, Dylan Cruz said:

What are these? I don't use different language packs, just English

Since Vista, Windows system files are language-neutral, with all language-specific resources being stored in .mui files. For the files in system32, you will find these in the en-US folder.

1 hour ago, Dylan Cruz said:

Huh?

Windows 9x displayed a message like "this program expects a newer Windows version. upgrade your Windows version." instead of falsely claiming that the program is not win32.

Link to comment
Share on other sites

4 hours ago, Dylan Cruz said:

I guess that would make sense... so all I need to mod is the exe? No DLLs or anything?

Turns out it's not so simple...it's linked to APIs that don't exist in Windows 7.

Link to comment
Share on other sites

Yes, it's definitely possible to extend the DLLs much like I've done for Vista. And perhaps something will be done for 7 as software continues to drop support for it.

But starting with Windows 8 and especially with 10, things get weird with those One-Core API set DLLs. They make everything look very stubby.

Edited by win32
Link to comment
Share on other sites

17 minutes ago, win32 said:

Yes, it's definitely possible to extend the DLLs much like I've done for Vista. And perhaps something will be done for 7 as software continues to drop support for it.

But starting with Windows 8 and especially with 10, things get weird with those One-Core DLLs. They make everything look very stubby.

Any thoughts on what I might try, then?

Snipping Tool is all I want, I don't give a hoot about any other Win10 stuff

Link to comment
Share on other sites

2 minutes ago, Dylan Cruz said:

Any thoughts on what I might try, then?

Extending DLLs by adding functions and new code will be the way to go. Anything else will typically result in failure.

Link to comment
Share on other sites

3 hours ago, win32 said:

Extending DLLs by adding functions and new code will be the way to go. Anything else will typically result in failure.

I'm afraid this is way beyond my level already. I only half follow ;)

Is this a project you'd be able to help with, or are you too buy with your Vista dev?

Hey, in theory we can port this to W7 *and* Vista!

Link to comment
Share on other sites

1 hour ago, Dylan Cruz said:

Is this a project you'd be able to help with, or are you too buy with your Vista dev?

There is some other non-Vista stuff I'm working on, and this would fit right in with it. :sneaky: But it would take longer because of the Vista stuff.

And yes, everything from that "other" project will go back to Vista.

Link to comment
Share on other sites

16 minutes ago, win32 said:

There is some other non-Vista stuff I'm working on, and this would fit right in with it. :sneaky: But it would take longer because of the Vista stuff.

And yes, everything from that "other" project will go back to Vista.

Awesome! HT on Vista would be swell.

Here's another port project... albeit in the other direction.

I've been using HyperTerminal on Windows 7 for a while, like many, and it's awesome. Only problem is no icons.

I found on some forum that you also need hticons.dll in system32, so I found that and copied it in. But, even after a reboot, no icons :(

I ran Dependency Walker and I got these files as missing:

API-MS-WIN-CORE-WINRT-ERROR-L1-1-0.DLL
API-MS-WIN-CORE-WINRT-L1-1-0.DLL
API-MS-WIN-CORE-WINRT-ROBUFFER-L1-1-0.DLL
API-MS-WIN-CORE-WINRT-STRING-L1-1-0.DLL
DCOMP.DLL
GPSVC.DLL
IESHIMS.DLL

 

Everything else looks good. Not even sure where I would find these, should I port them from XP to W7? If so, would just putting them in the same directory as hypertrm.exe be the way to go?

FWIW, XP ain't perfect either - these are missing there:

IESHIMS.DLL
WER.DLL
 

Edited by Dylan Cruz
Link to comment
Share on other sites

  • 1 year later...

It has been done. The delay functionality is working. Works on Vista and 7 (and probably 8, 8.1 as well).

This Snipping Tool is from Windows 10 1507 (the RTM release). The SHA-256 hash of the original SnippingTool.EXE is "fccf231e0e4437baba86f64752e13562c9a2aa2d699a8dae7fafc85b48da4aa8"
Porting requires 2 hex edits: one to change the NT version from 10.0 to 6.0 in order to trick Windows into running it, and the second to bypass some licensing/permission check that Microsoft put in.
Dunno if it's fine to distribute the .EXE here (probably not), hence why I only include instructions.
These instructions ONLY WORK FOR x64 Snipping Tool. If there is a big demand I can also work out how to do it for the 32-bit Snipping Tool as well.

1. Obtain Windows 10 1507 RTM x64 ISO, open with 7-Zip, then open sources\install.wim with 7-zip
2. Go to Windows\system32 and drag SnippingTool.exe to desktop (or some other location)
3. Next to SnippingTool.exe, make a folder called "en-US" (or whatever your language code)
4. From your 7-zip window, go to Windows\system32\en-US (or whatever your language code) and drag SnippingTool.exe.mui into the "en-US" folder you made in step 3
5. Open SnippingTool.exe in HxD or some other hex editor
6. At offset 0x120, change "0A 00 00 00 0A 00 00 00 0A 00 00 00" to "06 00 00 00 06 00 00 00 06 00 00 00"
7. At offset 0x1D19C, change "40 55 41 54 41 55" to "B8 01 00 00 00 C3"
8. At offset 0xF6B0, change "B8 FA 00 00 00" to "B8 2C 01 00 00"
9. Save file and exit hex editor

At this point, you can simply open the edited SnippingTool.exe and get the Windows 10 snipping tool as pictured. You may also replace the Windows Vista/7 stock snipping tool with this one if you desire.
For reference, the SHA-256 hash of the modified SnippingTool.exe is supposed to be "c60898fb4ea6984aaee1f2d3c9b73560bf0aaff64b9855e3d58e9855f3836433"

"It runs but only displays an error box with no text!"
This is caused by incorrect MUI file, or incorrect placement of the MUI file.
As in picture, en-US folder should be next to SnippingTool.exe, and SnippingTool.exe.mui should be inside that folder. And keep in mind, everywhere I say "en-US", this means the language code used by your system. For example, ja-JP or fr-FR for Japanese and French respectively.

DSC_0217.JPG

Edit: Add bug fix for ghost menu entries in certain circumstances (this bug happens in win10 as well)

Edited by vxiiduu
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...