set-window-document-icon

set-window-document-icon is a command for coding agents from Ganbin/4d-development-skill. It costs 0 tokens per session (941 once invoked), scanned A, original, MIT.

A 4D command that sets the icon shown for an application window and, in some cases, on the Windows taskbar. The icon can come from an image or a file.

In plain words
What is it for?
Use it to assign window icons in multi-window 4D applications.
Why use it?
It helps users tell different application windows apart.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/ganbin/4d-development-skill/set-window-document-icon
Clone the repo
git clone --depth 1 https://github.com/Ganbin/4d-development-skill

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for set-window-document-icon

README.md
[![agentmods](https://agentmods.dev/badge/commands/ganbin/4d-development-skill/set-window-document-icon.svg)](https://agentmods.dev/commands/ganbin/4d-development-skill/set-window-document-icon)
Your own site
<a href="https://agentmods.dev/commands/ganbin/4d-development-skill/set-window-document-icon"><img src="https://agentmods.dev/badge/commands/ganbin/4d-development-skill/set-window-document-icon.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 941 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00941
Opus 5 $0.00000 $0.00470
Sonnet 5 $0.00000 $0.00188
Haiku 4.5 $0.00000 $0.00094

Measured yesterday against content hash 7bd93e104ac2, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

set-window-document-icon scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

docs/commands/set-window-document-icon.md · 82 lines

How it starts

The opening of the file, as written. The whole thing — 82 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Parameter Type Description
winRef Integer Window reference number
image Picture Custom icon
file 4D.File, 4D.Folder File path or folder path
Release Changes
20 R7 Added

Description

The SET WINDOW DOCUMENT ICON command allows you to define an icon for windows in multi-window applications using either an image and/or file with the window reference winRef. The icon will be visible within the window itself and on the windows taskbar to help users identify and navigate different windows.

In the case of an MDI application on Windows, you can pass -1 in winRef to set the icon of the main window. In other contexts (macOS or SDI application on Windows), using -1 does nothing.

  • If only file is passed, the window uses the icon corresponding to the file type and the file’s path is displayed in the window’s menu.
  • If only image is passed, 4D does not show the path and the passed image is used for the window icon.
  • If both file and image are passed, the file’s path is displayed in the window’s menu and the passed image is used for the window icon.
  • If only winRef is passed or image is empty, the icon is removed on macOS and the default icon is displayed on Windows (application icon).

Example

In this example, we want to create four windows:

  1. Use the application icon on Windows and no icon on macOS (default state when no image or file is used).
  2. Use a "user" icon.
  3. Associate a document with the window (this uses its file type icon).
  4. Customize the icon associated with the document.

Read the full file on GitHub · 82 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 82 lines · 0 tokens per session scan A 7bd93e104ac2

Subscribe to this mod's changes

set-window-document-icon is a command published in the GitHub repository Ganbin/4d-development-skill (9 stars, last pushed 6mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 941 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.