java_swt on Mac OS X 10.2.8 menu bar [message #443512] |
Mon, 27 September 2004 02:06  |
Eclipse User |
|
|
|
Does anyone know how to remove the "SWT" menu bar on Mac OS X 10.2.8 or at
least change the name from "SWT" to my application title.
My application does not display a mac menu bar when run on 10.3.5.
My Info.plist looks like this:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist SYSTEM
"file://localhost/System/Library/DTDs/PropertyList.dtd">
<plist version="0.9">
<dict>
<key>CFBundleName</key>
<string>ManageSoft</string>
<key>CFBundleIdentifier</key>
<string>com.managesoft.client</string>
<key>CFBundleVersion</key>
<string>7.2</string>
<key>CFBundleIconFile</key>
<string>ManageSoft.icns</string>
<key>CFBundleAllowMixedLocalizations</key>
<string>true</string>
<key>CFBundleExecutable</key>
<string>selector</string>
<key>CFBundleDevelopmentRegion</key>
<string>English</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>LSMultipleInstancesProhibited</key>
<true/>
<key>LSPrefersCarbon</key>
<true/>
<key>LSEnvironment</key>
<dict>
<key>java_swt_dock_icon</key>
<string> /System/Library/ManageSoft/ManageSoft.app/Contents/Resources /Man
ageSoft.icns</string>
</dict>
<key>LSUIElement</key>
<string>0</string>
</dict>
</plist>
This works well on Mac OS X 10.3.5 however it gives me an unwanted menu
bar with the label "SWT" on Mac OS X 10.2.8. I think java_swt may be the
cause but I'm not entirely sure.
Any assistance will be greatly appreciated.
Cheers,
Arthur.
|
|
|
|
|
|
Re: java_swt on Mac OS X 10.2.8 menu bar [message #443684 is a reply to message #443562] |
Wed, 29 September 2004 04:13   |
Eclipse User |
|
|
|
Thanks Andre,
> Be aware: SWT for 3.0 is not supported on 10.2.8
Thanks for the info, I'll pass it on to our team.
> SWT from 3.1 can be launched from /usr/bin/java or from a standard
> application bundle if you are using a 1.4.2_04 JVM.
Yes I noticed this, but since the java_swt method also works here (and
therefore in all our supported environments) I'll stick with that until
I'm forced to change should Apple or Eclipse drop the use of the
CPSEnableForegroundOperation() API.
> Please try to set the application name with Display.setAppName(...) before
> creating the Display.
Cool stuff, this did the trick. A worthy note though, it only looks like
the window title cannot be reset once the display is initialised, so you
have to run this API early, preferably before the construction of the
display. I think this behaviour may have more to do with Mac OS X than SWT.
> Could you give me a hint what Jellyscript does and how it fails with
> Eclipse?
jellyscript is an apache commons framework for referencing object methods
and properties from an xml type script. We use it to construct our GUI (we
also call SWT APIs from it too). Unfortunately this issue ruined the
elegance of this solution because I was forced to make the
Display.setAppName() call way before the jelly stuff initialised and
outside the jelly framework. Oh well.
I know jellyscript GUIs can be debugged from within Eclipse (Marcus
Crafter, a regular contibutor to these forums has managed it), but I
believe it's currently quite a challenge.
Many thanks Andre for helping me sort out this issue.
All the best
Arthur.
|
|
|
Re: java_swt on Mac OS X 10.2.8 menu bar [message #443748 is a reply to message #443684] |
Wed, 29 September 2004 16:23   |
Eclipse User |
|
|
|
On 29.9.2004 10:13 Uhr, in article cjdqrd$nhp$1@eclipse.org, "Arthur Gouros"
<Arthur.Gouros@managesoft.com> wrote:
>> Please try to set the application name with Display.setAppName(...) before
>> creating the Display.
> Cool stuff, this did the trick. A worthy note though, it only looks like
> the window title cannot be reset once the display is initialised, so you
> have to run this API early, preferably before the construction of the
> display. I think this behaviour may have more to do with Mac OS X than SWT.
Yes, it is supposed to work like this on all platforms, so there seems to be
no way to change the app name after the Display has been created.
However, at least on MacOS X Apple introduced two command line options
-Xdock:name=<application name>
and
-Xdock:icon=<path to icon file>
Today they only have an effect if AWT is used.
But I've already proposed to support the latter option from within SWT too.
Now I'm convinced that the first option should be supported too. With this
you could set the app's name via the command line or from the application
bundle.
>
>> Could you give me a hint what Jellyscript does and how it fails with
>> Eclipse?
> jellyscript is an a....
Thanks for the intro.
--andre
|
|
|
|
|
Re: java_swt on Mac OS X 10.2.8 menu bar [message #444958 is a reply to message #444956] |
Fri, 22 October 2004 04:34  |
Eclipse User |
|
|
|
On 22.10.2004 1:32 Uhr, in article cl9gtm$vp2$1@eclipse.org, "Arthur Gouros"
<Arthur.Gouros@managesoft.com> wrote:
> Some feedback on java_swt:
>
> With the introduction of java 1.4.2 on Mac OS X came a new java option
> -XStartOnFirstThread giving application developers a alternate method of
> installing their java applications. Eclipse's java_swt binary effectively
> does the same thing but with a different implementation method.
>
> My testing with the java_swt from swt-3.1M2-macosx-carbon.zip found that
> my SWT GUI app can be installed and run consistantly across the following
> Mac OS X/Java versions:
>
> Java 1.3.1 -> Mac OS X 10.2.0->10.2.6
> Java 1.4.1 -> Mac OS X 10.2.6->10.2.8 and 10.3.2->10.3.5
> Java 1.4.2 -> Mac OS X 10.3.5->10.3.6
>
> I couldn't test all Mac OS X/Java combinations, but the above results give
> me enough confidence to say that Eclipse's java_swt solution will work for
> us using just one packaging and installation methodology for all our
> supported versions of Mac OS X and java. This is great for us as the news
> I got Apple's devcentre is that Java 1.4.2 (-XstartonFirstThread) will not
> be supported on Mac OS X 10.2.8 (i.e. old G3's that cannot be updated to
> 10.3.x)
>
> Cheers,
> Arthur.
>
Just be aware, that pecific versions of SWT or Eclipse components require a
specific version of MacOS X and/or JVM. So for instance SWT Browser widget
isn't supported on Jaguar (10.2.x) and won't run on a 1.3.1 VM. The same is
true for SWT's font and color dialogs.
--andre
|
|
|
Powered by
FUDForum. Page generated in 0.07026 seconds