Mac OS X 10.10 (Yosemite) Java Swing Look and Feel? - java

When I launch a java application using Swing for the GUI, I notice on Mac that Swing still renders the "old" Mac UI (10.9 and older). Since Oracle is now responsible to write the JRE for Mac OS X - where can I find any new UI?
Or are there any alternatives out there?

This spiked my curiosity since it also bothers me.
#MadProgrammer appears to be correct. Acoording to the Oracle's page about Look and Feels, HP, IBM and Apple provide their own Look and Feels.
To my understanding, this clears Oracle's responsability over the out of date L&F, and transfers it to Apple itself.
The only foreseeable option is to wait for updates...

Related

Java applications on Mac using Java7, have a limited window width

I'm developing a desktop application for Mac. When I run the application using Java6 it works fine, but when I run it using Java7, the application window seems to be limited to a width 1024 pixels (i.e. when it starts the window is 1024px wide, and can't be expanded/dragged to make it wider). I've tried all sorts of ways to adjust the size (setting window state to maximized, explicitly setting the width, etc.). I've also tried changing where I set the Window size, but so far no luck.
I have tried searching for anyone who has had similar problems, but have not had much luck. The only real hit I got was from an OTN discussion forum: https://community.oracle.com/thread/2617106, but there is no resolution and the discussion seems to be archived so I can't reply to it.
If anyone out there has come across this issue, I'd love to hear about it.
Environment:
Operating System: Mac OS X 10.7.5
Java Version: 1.7.0_55 (Oracle Corporation)
New Information:
Have found a related bug report in OpenJDK: https://bugs.openjdk.java.net/browse/JDK-8046008?page=com.atlassian.jira.plugin.system.issuetabpanels:changehistory-tabpanel
This seems to indicate that it is a problem for Mac OS X 10.7.5, which I am using.

Run JFrame in gui less linux os

Recently I switch to linux with no desktop os.
I have installed java successfull but when i run program of JFrame then it throws exception like
java.awt.HeadlessException
java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:159)
java.awt.Window.(Window.java:432)
java.awt.Frame.(Frame.java:403)
javax.swing.JFrame.(JFrame.java:202)
now I could not understand how can I fix this problem?
I want to run JFrame & even I dont want to remove os as well.
thanks in advance.
Well, if the OS doesn't have any desktop, only command line, where do you expect the window to be drawn? If the OS doesn't have desktop, then you can only use command line.
You can try Charva, as #BenjaminDale suggested, but that will offer only limited functionality.
Swing can only work with os supporting desktop (head / screen). In the case of headless os, I can't understand any use case of JFrame.
So you'll either have to get rid of JFrame from your program (which seems logical (there is no desktop)) or run it on an os with a head :)
Hope this helps.
The article Using Headless Mode in the Java SE Platform describes the limitations imposed on applications intended to run in headless mode. For applications that cannot be usefully converted, some alternatives are mentioned here, including xvfb and vnc.

downloading quaqua look and feel to integrate with the java application in windows

where can i download quaqua look and feel for java app in windows? What are the steps to integrate this look and feel with the project ?
I want to integrate this look and feel with my java application on windows.
http://www.randelshofer.ch/quaqua/ FAQ
Can I use Quaqua on other platforms than Mac OS X?
No, you can't, except for development purposes.
This is because the Aqua user interface can only be licensed from Apple for use on Mac OS X.
Anyhow, for development purposes only, here's a guide for using the Quaqua L&F:
http://www.randelshofer.ch/quaqua/guide/index.html

GUI sys tray app on Ubuntu with Clojure

I want to make a GUI application for Ubuntu written in Clojure (so using Java GUI libraries). I know how to write Swing apps, to run as 'normal' GUI apps. I want to do something a little different and am not sure how to approach it; I want to write a program to run in the sys tray, and every X minutes remind me something in a small window that shows near the sys tray.
Thanks for the help,
Alex
If you are targeting java 6 you can use,
http://java.sun.com/developer/technicalArticles/J2SE/Desktop/javase6/systemtray/
works cross platform.
You might want to look at Brian Carpers clj-qt4-mailtray
It uses Qt so should run cross platform as an added bonus. Brian has an explanatory article here.

Transparent Swing Windows

I have a little JWindow with a logo on it that users can drag stuff to.
I develop my application mainly on OS X. To get a transparent window i use
setBackground(new Color(0,0,0,0));
On a mac this works beautifully but I can't get the same effect on windows.
Is there any way to get a transparent window without using 1.6 specific features.
I need 1.5 compatibility.
Sadly, windows (previous to Vista at least) doesn't do this kind of compositing. There is however a workaround. Example code can be found at http://rabbit-hole.blogspot.com/2007/02/non-rectangular-windows-update.html
As of 1.5 Java does not support transparent windows.
This feature is introduced as part of 1.6.10 release.
See AWTUtilities class for more details.

Categories

Resources