Application Icon/ja: what changed
Revision 2 to 3. Removed lines have a minus sign; added lines have a plus sign.
| Old | New | Line | |
|---|---|---|---|
| 1 | 1 | アプリケーションアイコンは通常アプリケーションのメインウインドウに表示されます。Application.Iconを設定することで制御することができます。 | |
| 2 | 2 | ||
| 3 | 3 | 実行ファイルのアイコンを変更するには、OSに依存したテクニックを使う必要があります。 | |
| 4 | 4 | ||
| 5 | 5 | ## Windowsでアプリケーションアイコンを設定する | |
| 6 | 6 | ||
| 7 | 7 | 1\. 例えば"project.rc"と名前をつけて、次のようなアイコンを含む新しいリソースファイルを作ります。: | |
| 8 | 8 | ||
| 9 | - | ||
| 9 | + | ```text | |
| 10 | 10 | MAINICON ICON "editor.ico" | |
| 11 | 11 | ``` | |
| 12 | 12 | ||
| 13 | 13 | 2\. プロジェクトの *.lprファイルに次の命令を入れます。 | |
| 14 | 14 | ||
| 15 | - | ||
| 15 | + | ```text | |
| 16 | 16 | {$R project.rc} | |
| 17 | 17 | ``` | |
| 18 | 18 | ||
| 19 | 19 | version 0.9.24 以上で動作します。 | |
| 20 | 20 | ||
| 21 | 21 | ## Mac OS Xでアプリケーションアイコンを設定する | |
| 22 | 22 | ||
| 23 | 23 | Mac OS XではApplicationに付随したアイコンを設定する必要があります。 次のようにInfo.plistファイルにフィールドを追加します。 | |
| 24 | 24 | ||
| 25 | 25 | ||
| 26 | 26 | ||
| 27 | - | ||
| 27 | + | ```text | |
| 28 | 28 | <key>CFBundleIconFile</key> | |
| 29 | 29 | <string>iconfile.icns</string> | |
| 30 | 30 | ``` | |
| 31 | 31 | ||
| 32 | 32 | iconfile.icnsの場所はMyBundle.app/Contents/Resourcesの中に入れます。 icnsファイルを作るためには、[このページ](http://www.macinstruct.com/node/59) が参考になるでしょう。 | |
| 33 | 33 | ||
| 34 | 34 | ## Linuxでアプリケーションアイコンを設定する | |
| 35 | 35 | ||
| 36 | 36 | Linuxアプリケーションでのアイコンはそれぞれのウインドウマネージャごとに別々の、特別なディレクトリにあります。 しかしながら、そのディレクトリの中は[Icon Theme Specification](http://www.freedesktop.org/Standards/icon-theme-spec)で標準化されています。 | |
| 37 | 37 | ||
| 38 | 38 | ### K Desktop Environment (KDE)でアプリケーションアイコンを設定する | |
| 39 | 39 | ||
| 40 | 40 | すべてのユーザーで使うアプリケーションのアイコン、あるいはそれぞれのユーザーが使うアイコンのフォルダを次のコマンドで見つけることができます。 | |
| 41 | 41 | ||
| 42 | - | ||
| 42 | + | ```text | |
| 43 | 43 | kde-config --path icon | |
| 44 | 44 | ``` | |
| 45 | 45 | ||
| 46 | 46 | コロンで区切られたパスがstdoutに出力されます。 | |
| 47 | 47 | ||
| 48 | 48 | ### GNOMEでアプリケーションアイコンを設定する | |
| 49 | 49 | ||
| 50 | 50 | すべてのユーザーで使うアプリケーションのアイコン、あるいはそれぞれのユーザーが使うアイコンのフォルダを次のコマンドで見つけることができます。 | |
| 51 | 51 | ||
| 52 | - | ||
| 52 | + | ```text | |
| 53 | 53 | gnome-config --datadir | |
| 54 | 54 | ``` | |
| 55 | 55 | ||
| 56 | 56 | stdoutにパスを出力します。その中身はアイコンテーマ定義のpixmapsと呼ばれるディレクトリを見つけます。 | |
| 57 | 57 | ||
| 58 | 58 | --- | |
| 59 | 59 | *From the Free Pascal wiki, page "Application Icon/ja", as it stood on 2008-07-18 after a change by Saeka-jp, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's [[Licensing]] page. If you have concerns about this material, [message the admin](/wiki-contact).* |
