Re: [TDK-BETA] General usability - Tclapp and .icns icons
by Andreas Kupries other posts by this author
Dec 8 2006 9:34AM messages near this date
view in the new Beta List Site
[TDK-BETA] General usability - Tclapp and .icns icons
|
Re: [TDK-BETA] General usability - Tclapp and .icns icons
> -----Original Message-----
> From: tdk-beta-bounces@[...].com
> [mailto:tdk-beta-bounces@[...].com]On Behalf Of Peter
> Caffin
> Sent: Friday, December 08, 2006 2:42 AM
> To: tdk-beta@[...].com
> Subject: [TDK-BETA] General usability - Tclapp and .icns icons
>
>
> Hi guys.
>
> Another one:
>
> In the Wrapping tab, there's an entry for Custom Icon entry widget which
> is disabled with the tooltip error message:
>
> "A customisation of this icon is not possible. This is because the prefix
> file does not contain any icons to customise."
>
> Then in Merge Selected Files, we have a checkbox for Make an OS X
> Application Bundle.
>
> For the OS X version, it would make sense for the Custom Icon to control
> the .icns icon included if the user has chosen to create an Application
> Bundle.
Agreed in general. This however requires an extension providing an .icns photo
handler for Tk. Like we have img::ico for Windows .ico images. I have not seen
any such support yet.
> (As it is now, each time we wrap a program, we need to drop in the
> a copy of the icon in a separate step outside the Tclapp program.)
Not quite. Below a dump of some notes for our doc writer.
(The -metadata option is reflected in the GUI by the metadata panel)
(In the context of this mail osx,icon below is of interest)
Options:
-osxapp Activate generation of .app bundle.
-metadata Information from special keys
is used to fill in the OSX plist
when creating a .app bundle.
For missing special keys defaults are used.
See table (1) below.
Effects:
When -osxapp is given the specified -output is interpreted not
as the path to the executable, but as the path to the bundle
directory. A .app is added to the last path element if not
already present. The wrapped executable will be put into
`-output`.app/Contents/MacOS/
and its name is `basename -output .app`, i.e last path segment,
with .app stripped off, if present. It will replicate the
extension found in the -prefix file, if any.
Example:
-osxapp -output /foo
=> Result is directory /foo.app
Executable is /foo.app/Contents/MacOS/foo
TclApp Project Files:
Wrap/Output/OSXApp - 1 argument, boolean flag.
default false/0.
Metadata - 1 argument, dictionary of metadata.
default empty.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Table (1): Use of -metadata by -osxapp
All keys are optional, therefore no defaults. Yes, even the "version".
teapot metadata osx bundle Notes
--------------- ---------- -----------
osx,help CFBundleHelpBookFolder Directory containing the
help, under Contents/Resources/English.lproj
osx,id CFBundleIdentifier See OSX Info.plist
documentation
osx,info CFBundleGetInfoString See OSX Info.plist
documentation
osx,region CFBundleDevelopmentRegion See OSX Info.plist
documentation
osx,shortversion CFBundleShortVersionString See OSX Info.plist
documentation
osx,sign CFBundleSignature See OSX Info.plist
documentation [*]
osx,version CFBundleVersion See OSX Info.plist
documentation
--------------- ---------- -----------
[*] Has to be four characters long. TclApp will pad the string with
'?' if it is shorter than that. It will also convert the string
to upper-case.
--------------- ---------- -----------
osx,icon CFBundleIconFile Path to external icon
file, to be copied into the bundle!
--------------- ---------- -----------
The key above (osx,icon) is here only because the regular icon setting
of TclApp (see Panel 'Wrapping') is not able to handle .icns files,
i.e. Apple's icon format. Chokes on the display. Without that we
could modify the regular UI, and wrap engine to handle OSX icon stuff
too, instead of only Windows.
--
Andreas Kupries <andreask@[...].com>
Developer @ http://www.ActiveState.com
Tel: +1 778-786-1122
Thread:
peterc+activestate
Jeff Hobbs
Peter Caffin
Peter Caffin
Peter Caffin
Peter Caffin
Peter Caffin
jeffh
peterc+activestate
jeffh
peterc+activestate
Jeff Hobbs
Peter Caffin
Jeff Hobbs
Peter Caffin
Andreas Kupries
Peter Caffin
Andreas Kupries
Peter Caffin
Jeff Hobbs
|