A rewrite of MS Paint for Windows 95 in Angular
翻译准备中
开发工具TypeScript · HTMLGitHub @jgosar自行安装运营者未确认
试用过了吗? 点一下就好,无需登录。
尚未检测到更新。GitHub 发布版本后会显示在这里。
个人 GitHub 账号下公开仓库的所有者可以登录并验证所有权,自行管理介绍,无需管理员批准。
登录并生成验证文件,在 30 分钟内将其提交到此仓库的默认分支。其他分支或分叉仓库中的文件无效。然后在下方检查文件,即可无需管理员批准直接管理项目。请保留文件以维持管理权限。
如需登录,将前往登录页面。登录后请回到此处,再次点击所选的验证按钮。
安装型项目无需部署域名也可验证。个人仓库可通过 GitHub 登录验证,组织仓库可使用上方的仓库验证文件。
制作者的介绍仅有上面的一句话。 更多详情请阅读仓库 README。 仓库 README ↗
正在加载完整 README。
查看完整 README ↗A rewrite of MS Paint for Windows 95 in Typescript and Angular
Screenshot:
Live version:
https://jgosar.github.io/ts-paint/
The project is still at an early stage of development, but the general roadmap is:
TS Paint is a Progressive Web App. Open the live version in a browser that supports installing web apps (Chrome, Edge, Safari) and use the browser's install option to add it to your desktop or home screen. Once installed it works offline, and new versions are picked up automatically the next time you launch it.
In Chromium-based browsers the installed app also registers as a handler for image files, so you can right-click a .png, .jpg, .gif, .bmp or .webp file and choose Open with TS Paint. Files opened this way (or via File > Open, or by dragging them into the window) are saved back in place with File > Save.
The UI always renders with a whole number of device pixels per CSS pixel. Fractional OS display scaling (such as 125% or 150% on Windows) is snapped to the nearest integer, so the Windows 95 look stays pixel-perfect on high-DPI screens. Browser zoom (Ctrl +/-) is snapped to integer steps as well.
On a touchscreen, one finger uses the selected tool like the left mouse button: it draws as it moves, and a tap is a click, so the fill and magnifier tools work with a single tap. Two fingers scroll the image and pinch to zoom in and out, one 2x step at a time; the point between the fingers stays where it is.
Everything below runs from the ts-paint directory.
Unit tests use Vitest in browser mode, running in a real Chromium (the app draws on canvases, which jsdom cannot do):
npm test # watch mode
npm run test:ci # single run with coverage
End-to-end and visual tests use Playwright against the production build:
npx playwright install --with-deps chromium # once
npm run test:e2e # functional tests, natively
npm run test:e2e:docker # functional + visual tests in the pinned Playwright Docker image
npm run test:e2e:update # regenerate the visual baselines (Docker only)
The visual baselines are exact-match screenshots generated only on Linux inside Docker; never commit snapshots taken on macOS or Windows. See ts-paint/e2e/README.md for the details and conventions. Every pull request runs lint, unit and e2e tests, and the GitHub Pages deploy only runs after they pass on master.
As a fun exercise, I have also implemented an extension for Google Chrome. It uses Manifest V3, so it works in current versions of Chrome. It adds the option 'Edit in TS Paint' to the context menu when you right-click on an image on any website, which loads the image into TS Paint in a new tab. To install the extension, follow these steps:
ts-paint\ts-paint-chrome-extension directory