[issue32129] Icon on macOS

2019-02-25 Thread Ned Deily


Change by Ned Deily :


--
pull_requests: +12064

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32129] Icon on macOS

2019-02-25 Thread Ned Deily


Change by Ned Deily :


--
pull_requests: +12061
stage:  -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32129] Icon on macOS

2019-02-25 Thread Kevin Walzer


Kevin Walzer  added the comment:

Is there any reason not to commit the patch I submitted to address this 
issue?As an alternative I can submit a high-res PNG that can be used, and will 
submit a different patch to incorporate it, which would work from either the 
standard app bundle or the command line. Either way, there is no reason to 
continue to have this visual artifact in IDLE on the Mac.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32129] Icon on macOS

2019-01-26 Thread Kevin Walzer


Kevin Walzer  added the comment:

Making the icon 512x512 pixels will make it look correct on Retina displays on 
the Mac.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32129] Icon on macOS

2019-01-26 Thread Terry J. Reedy

Terry J. Reedy  added the comment:

A Branch Seidenman posted 'Retina Icons' on idle-dev.  He posted a screenshot 
similar to Kevin's.  He says Apple recommends having all these sizes:
1024px × 1024px
512px × 512px
256px × 256px
128px × 128px
64px × 64px
32px × 32px
16px × 16px

Creating new icons larger that 48px is beyond me.  Besides which, I believe 
these are copies of files elsewhere in the repository.  (The icons directory 
should have a README explaining the files and their origin.  How many of these 
sizes would actually be useful?  Would larger icons be useful on hi-rex Linux 
(or even Windows) systems?

--
nosy: +taleinat

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32129] Icon on macOS

2017-11-25 Thread Serhiy Storchaka

Serhiy Storchaka  added the comment:

If on OS X only first picture is taken, what if change the order of pictures?

--
nosy: +serhiy.storchaka

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32129] Icon on macOS

2017-11-25 Thread Terry J. Reedy

Terry J. Reedy  added the comment:

Ned, do you agree that simply changing 'else' to 'elif not macosx.isAquaTk()' 
is the best resolution?

Backporting such a change to 3.6 would be trivial; to 2.7, not.  Is there any 
need for the latter?

Kevin, thanks for the explanation.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32129] Icon on macOS

2017-11-25 Thread Kevin Walzer

Kevin Walzer  added the comment:

Adding proposed patch.

--
keywords: +patch
Added file: https://bugs.python.org/file47293/pyshell.diff

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32129] Icon on macOS

2017-11-25 Thread Kevin Walzer

Kevin Walzer  added the comment:

wm_iconphoto is a no-op on Tk 8.5 on MacOS; the C function returns true with no 
action. That's why this has not cropped up before.

As implemented, the command on macOS only takes the first image in the 
parameters to use; the Cocoa mechanism in use for displaying images as app 
icons does not pack multiple sizes in the image. This will be documented in the 
man page for the next release of Tk. That's why the image currently looks very 
bad, because, as you note, it's scaling up a 16px image. The 48px would look 
better, albeit a bit jagged. 

The attached patch proposes to simply bypass this call in Tk-Mac. The 
wm_iconphoto command is most useful for a) replacing a generic Windows or X11 
icon with something more customized or b) displaying a change in application 
state. On Mac OS, option is already addressed by the bundled application icon 
that looks much more polished; most users will not be calling idle from the 
command line (where this call can make sense). Option b is not applicable in 
this context.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32129] Icon on macOS

2017-11-24 Thread Terry J. Reedy

Terry J. Reedy  added the comment:

Here is the current code in idlelib.pyshell.main.

# set application icon
icondir = os.path.join(os.path.dirname(__file__), 'Icons')
if system() == 'Windows':
iconfile = os.path.join(icondir, 'idle.ico')
root.wm_iconbitmap(default=iconfile)
else:
ext = '.png' if TkVersion >= 8.6 else '.gif'
iconfiles = [os.path.join(icondir, 'idle_%d%s' % (size, ext))
 for size in (16, 32, 48)]
icons = [PhotoImage(master=root, file=iconfile)
 for iconfile in iconfiles]
root.wm_iconphoto(True, *icons)

IDLE uses wm_iconbitmap on Windows and wm_iconphoto with PhotoImages from .gif 
or .png on everything else.  It appears that wm_iconphoto is already used on 
macOS with tk 8.5.

The uploaded PM.png looks like it might be idle16.png zoomed out at least 3x.  
Anything that does that instead of using the much sharper 32 or 48 bit versions 
is, to me, buggy.  The bigger images stay much sharper even when zoomed.

--
nosy: +ned.deily

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32129] Icon on macOS

2017-11-24 Thread Kevin Walzer

New submission from Kevin Walzer :

The trunk and 8.6.7 branch of Tk on macOS have recently implemented the 
wm_iconphoto command, which had not previously been supported on macOS. This 
means that versions of IDLE that link to this version of Tk will inherit the 
iconphoto behavior on Windows and X11, which results in a extremely blurry icon 
image in the Dock. It would probably be best to make this command conditional 
on macOS to just retain the standard app icon, or else add a sharper image.

--
assignee: terry.reedy
components: IDLE
files: Screen Shot 2017-11-24 at 11.44.31 PM.png
messages: 306941
nosy: terry.reedy, wordtech
priority: normal
severity: normal
status: open
title: Icon on macOS
type: behavior
Added file: https://bugs.python.org/file47288/Screen Shot 2017-11-24 at 
11.44.31 PM.png

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com