[GH-ISSUE #579] [feature implement sharing]Fix system screenshots missing & add support for PNG/JPG formats #390

Open
opened 2026-03-03 01:12:07 +03:00 by kerem · 1 comment
Owner

Originally created by @pokocat on GitHub (Jan 7, 2026).
Original GitHub issue: https://github.com/Clipy/Clipy/issues/579

I forked and did some updates as following... https://github.com/pokocat/Clipy/releases/tag/2.0.0

Title:
Fix system screenshots missing & add support for PNG/JPG formats

Description:

Summary

This PR restores the missing system screenshot monitoring functionality and significantly improves image clipboard support for modern applications (e.g., WeChat, Lark/Feishu, Web Browsers). It also resolves stability issues caused by overly aggressive clipboard polling.

Key Changes

1. Restore System Screenshot Monitoring

  • Re-implemented ScreenShotObserverDelegate in AppDelegate.swift.
  • Replaced the removed RxScreeen dependency with a native delegate implementation, ensuring system screenshots (Cmd+Shift+3/4) are automatically detected and saved to history.

2. Enhanced Image Format Support

  • Added native support for public.png, public.jpeg, and public.tiff pasteboard types.
  • Problem: Previously, Clipy relied on the deprecated NSTIFFPboardType. This caused it to ignore images copied from apps that write modern standard formats (like Chrome "Copy Image" or IM apps).
  • Solution: Updated CPYClipData, MenuManager, and ClipService to recognize these types as valid images and generate thumbnails/titles correctly.

3. Stability & Performance Improvements

  • Fix Polling Interval: Corrected ClipService polling interval from 750 microseconds to 750 milliseconds.
    • Impact: The previous microsecond interval was too aggressive, causing race conditions where Clipy would try to read the clipboard before the writing app finished, resulting in "hit or miss" capture behavior.
  • Improved Deduplication: Updated CPYClipData.hash to include image dimensions (width ^ height).
    • Impact: Prevents different images that happen to have similar data sizes from being incorrectly treated as duplicates and discarded.
  • Robust Thumbnail Generation: Updated NSImage+Resize.swift to add a fallback drawing mechanism when NSBitmapImageRep is nil, ensuring thumbnails are generated for all image types.

Verification

  • System screenshots are now automatically saved to history.
  • Images copied from (PNG/JPG) are correctly saved and displayed.
  • Fixed stability issues where clipboard updates were sometimes missed.
  • Thumbnails are correctly generated for all supported image types.

Originally created by @pokocat on GitHub (Jan 7, 2026). Original GitHub issue: https://github.com/Clipy/Clipy/issues/579 I forked and did some updates as following... https://github.com/pokocat/Clipy/releases/tag/2.0.0 **Title:** Fix system screenshots missing & add support for PNG/JPG formats **Description:** ## Summary This PR restores the missing system screenshot monitoring functionality and significantly improves image clipboard support for modern applications (e.g., WeChat, Lark/Feishu, Web Browsers). It also resolves stability issues caused by overly aggressive clipboard polling. ## Key Changes ### 1. Restore System Screenshot Monitoring - Re-implemented `ScreenShotObserverDelegate` in `AppDelegate.swift`. - Replaced the removed `RxScreeen` dependency with a native delegate implementation, ensuring system screenshots (Cmd+Shift+3/4) are automatically detected and saved to history. ### 2. Enhanced Image Format Support - Added native support for `public.png`, `public.jpeg`, and `public.tiff` pasteboard types. - **Problem:** Previously, Clipy relied on the deprecated `NSTIFFPboardType`. This caused it to ignore images copied from apps that write modern standard formats (like Chrome "Copy Image" or IM apps). - **Solution:** Updated `CPYClipData`, `MenuManager`, and `ClipService` to recognize these types as valid images and generate thumbnails/titles correctly. ### 3. Stability & Performance Improvements - **Fix Polling Interval:** Corrected `ClipService` polling interval from `750 microseconds` to `750 milliseconds`. - *Impact:* The previous microsecond interval was too aggressive, causing race conditions where Clipy would try to read the clipboard before the writing app finished, resulting in "hit or miss" capture behavior. - **Improved Deduplication:** Updated `CPYClipData.hash` to include image dimensions (`width` ^ `height`). - *Impact:* Prevents different images that happen to have similar data sizes from being incorrectly treated as duplicates and discarded. - **Robust Thumbnail Generation:** Updated `NSImage+Resize.swift` to add a fallback drawing mechanism when `NSBitmapImageRep` is nil, ensuring thumbnails are generated for all image types. ## Verification - [x] System screenshots are now automatically saved to history. - [x] Images copied from (PNG/JPG) are correctly saved and displayed. - [x] Fixed stability issues where clipboard updates were sometimes missed. - [x] Thumbnails are correctly generated for all supported image types. ---
Author
Owner

@kumarav1nash commented on GitHub (Feb 16, 2026):

i don't think this project is actively managed, we can start separate fork if we found couple of active contributer @pokocat

<!-- gh-comment-id:3908800402 --> @kumarav1nash commented on GitHub (Feb 16, 2026): i don't think this project is actively managed, we can start separate fork if we found couple of active contributer @pokocat
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Clipy#390
No description provided.