Tx we should have a class to do it for us. On Fri, Feb 2, 2018 at 11:42 PM, Eliot Miranda <eliot.miranda@gmail.com> wrote:
Hi Stef,
On Fri, Feb 2, 2018 at 11:32 AM, Stephane Ducasse <stepharo.self@gmail.com> wrote:
Would it be possible to change the icon without having to compile a new VM?
Through an AppleScript:
e.g. https://www.sethvargo.com/replace-icons-osx/
To me the current setup looks so monolithic and dated. I would expect that somebody can deploy a application with its own logo by just providing some new resources.
And that's indeed possible. Take the .app bundle and change the .icns file as described above.
Stef
On Wed, Jan 31, 2018 at 11:17 PM, Eliot Miranda <eliot.miranda@gmail.com> wrote:
Hi Vincent,
On Wed, Jan 31, 2018 at 12:07 PM, <Vincent.Blondeau@lamresearch.com> wrote:
Hi,
I would like to know how to change the main Pharo window icon. I saw that there is a primitive for the title: DisplayScreen class >> primitiveWindowTitle:string: ; primitive: 'primitiveHostWindowTitle' module:'HostWindowPlugin' but I cannot find one for the icon. Should another primitive need to be implemented?
The icon is baked into the VM executable. So to change it one has to build a VM with a different icon.
On Windows it is in {build.win32x86,build.win64x64}/pharo.cog.spur/Pharo.ico and the file that specifies to use Pharo.ico is {build.win32x86,build.win64x64}/pharo.cog.spur/Pharo.rc
On Mac OS X it is in platforms/iOS/vm/OSX/Pharo.icns (alongside three others such as PharoImage.icns) and the file that specifies to use Pharo.icns is {build.macos32x86,build.macos64x64}/pharo.cog.spur/Makefile in setting the VM variable. The file that associates the other icons with specific file types is platforms/iOS//vm/OSX/Pharo-Info.plist
If you're changing the Pharo icon let me suggest you update the icon files themselves in the opensmalltalk-vm source tree.
If you're creating a new variant of the VM for some new purpose (say a special Lam VM) then let me suggest you add the icons to the opensmalltalk-vm source tree, creating special build directories for these VMs, such as {build.macos32x86,build.macos64x64}/lam.pharo.cog.spur/
If you want to do this privately, then take either of the approaches above and simply don't publish the edits. You can write a script that takes an updated checked-out opensmalltalk-vm source tree and edits it with files from a specific repository. I have such scripts and can help you with them. Hint, pax is a very convenient directory hierarchy copying tool available at least on Mac OS X. pax -rwlk will copy the trees under a sequence of directories into their corresponding places in a target tree.
Thanks!
Vincent
-- _,,,^..^,,,_ best, Eliot
-- _,,,^..^,,,_ best, Eliot