> On Jul 8, 2021, at 8:15 PM, Akihiko Odaki <akihiko.od...@gmail.com> wrote:
>
> I tried [NSApp applicationIconImage] but had no luck. I suspect it is
> because Rez is for Carbon development and deprecated while NSApp is
> from AppKit. Loading from the filesystem is inevitable.
Totally disagree. I'm on a new MacBook Air and the rez command is available. I
will agree that Apple likes removing features but the rez command is not one of
them.
I did not try [NSApp applicationIconImage], but I did try using [[NSWorkspace
sharedWorkspace] iconForFile: program_path] and it worked.
> By the way, I knew Rez is from Carbon but didn't know it is
> deprecated, which I have figured out just now by reading man. Reading
> the icon file and assigning it to [NSApp applicationIconImage] is a
> possible solution, but it requires modifications for all graphical
> backends (cocoa, gtk, and sdl) and of course an external icon file. Do
> you think removing the dependency on Rez is worth it?
I do not think we should remove any code that depends on rez. I honestly think
the easiest and best thing to do is to go back to using my original patch for
displaying a picture in the About dialog.
> See "[PATCH 1/4] cutils: Introduce bundle mechanism" for a general fix
> of the problem when loading a "bundled" file.
>
> Regards,
> Akihiko Odaki
>
>
> On Fri, Jul 9, 2021 at 2:51 AM Peter Maydell <peter.mayd...@linaro.org> wrote:
>>
>> On Thu, 8 Jul 2021 at 17:28, Programmingkid <programmingk...@gmail.com>
>> wrote:
>>> The problem with e31746ecf8dd2f25f687c94ac14016a3ba5debfc is it requires a
>>> picture file to be found in a certain path. My original code used QEMU's
>>> icon to obtain a picture. The reason why the picture in the About dialog
>>> stopped appearing was because of the move to the meson build system.
>>> A new patch has just been committed that fixes the missing icon issue.
>>> Using 'git revert e31746ecf8dd2f25f687c94ac14016a3ba5debfc' fixes the
>>> missing picture issue in the About dialog.
>>
>> If the icon is the same (same resolution, etc) then just using it
>> does seem better than loading it off the filesystem. But we should
>> also sort out why get_relocated_path() isn't working, because if QEMU.
>> can't load files that way then other things will also be broken I think.
>>
>> -- PMM