Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Add Window::SetContentProtection (exclude from screen capture)

Open
#71 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
55/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Active
Tech stack
cpp

Research direction

Start by locating the Window API and its Windows, macOS, and Linux platform implementations. Review SetWindowDisplayAffinity and NSWindow.sharingType, including the stated version and ScreenCaptureKit limitations. Done means exposing Window::SetContentProtection(bool), applying the requested platform behavior, and documenting that Linux does not support it.

Written by the indexing model from the issue text.

Description

enhancement

Add Window::SetContentProtection(bool) so the window's content is excluded from screenshots and screen recording, like Electron's win.setContentProtection():

  • Windows: SetWindowDisplayAffinity(hwnd, WDA_EXCLUDEFROMCAPTURE) (Windows 10 2004+, else WDA_MONITOR)
  • macOS: NSWindow.sharingType = NSWindowSharingNone (note: not honoured by ScreenCaptureKit on recent macOS)
  • Linux: not available; document it

Background:

  • leanflutter/window_manager#215: equivalent of Electron's setContentProtection
Dominant language
C++
Stars
34
Forks
7
Avg merge
3d 1h
Merged PRs (30d)
1

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from libnativeapi/nativeapi

All issues in libnativeapi/nativeapi

Similar issues

More C++ issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.