Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 9 years ago.
Improve this question
Lately I have learned a lot of Java;
Currently I am using Swing for GUI;
And I want to use Synthetica's L&F's ;
I need help on where to start, some comprehensive tutorials may help,
I also wonder that if I wasted time by learning swing.
Cause I know Synthetica does not require writing code, or am I wrong ?
Thanks.
Synthetica is a Look and Feel (LaF) for the Java Swing GUI Library/Toolkit. Think of it as a skin to change the default look of a Java GUI app.
Here's some reading on how to integrate a different LaF into your app:
http://docs.oracle.com/javase/tutorial/uiswing/examples/lookandfeel/
http://docs.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html
http://www.javasoft.de/synthetica/faq/#general-1
Using a pre-built LaF will save you the time and code of making the LaF yourself, but you will still have to code the actual GUI (the frame, buttons, text boxes, etc). Synthetica will just make them look different than normal. I would say to effectively use Java Swing LaF's, you will still need to know a little about Swing.
If you do not like Swing, it's worth looking into JavaFX. It's the Swing replacement and is included in Java 8 by default. You can hand-code the GUI using Java code just like with Swing, or you can use something called FXML to basically write the GUI in a special XML document which is much faster. JavaFX also uses CSS to style the LaF to look however you want.
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 1 year ago.
Improve this question
Can we use material UI in java?
Basically, I am making a calculator in eclipse using swing and awt and I want to try materialUI, so I want to use the material button in it.
Is it possible?
Yes. You could use Material UI with Java. Implement your calculator as a webapp and use Material UI components to implement the calculator (web) UI to run in the user's web browser.
But it doesn't make sense to use Material UI with Swing / AWT.
Material UI is a Javascript component library that runs in the user's web browser.
Swing / AWT are for implementing user interfaces on the user's desktop.
(Trying to use Material UI with Swing / AWT would be like trying to put wheels on a fish.)
There is nothing preventing you from designing and implementing cool buttons (e.g. buttons that look like Material buttons) in Java using Swing / AWT as the foundation. It would "just" be a Java coding exercise; see Andrew Thompson's answer for some a starting point.
But my advice: don't bother. It would be a waste of effort ... IMO.
.. looks cool ..
If it is purely about the look of Swing GUI controls, that could be implemented using a custom look-and-feel. See the Modifying the Look and Feel lesson in the tutorial for details. Note there are also many 3rd party look and feel implementations that might come close to what you think is 'cool'.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
Im quite good with writing text based programs using Java and ill like to proceed to writing GUI programs and animations ive checked several youtube playlists and they dont seem do helpful so i would appreciate any tips on where to start.
For desktop applications, You should start with Java Swing.
Swing API is a set of extensible GUI Components to ease the
developer's life to create JAVA based Front End/GUI Applications.
There are some good tutorials, I would suggest the following:
JavaTPoint and TutorialsPoint
After completing swing, you can move on to JavaFX.
JavaFX is a set of graphics and media packages that enables developers
to design, create, test, debug, and deploy rich client applications
that operate consistently across diverse platforms.
For that, you may follow to begin with
code.makery
Sounds as a great question, but not self explanatory. Before making assumptions just ask your self -
Do I feel myself as Web developer or a Desktop(Core) developer?
From a prospective of Desktop developer - take a look at Swing - it allows to make GUI forms and etc. If you decide to learn web, then take a look at Vaadin (which is made on top of GWT, and easier to dive in)..
Both of them have simlar syntax, so it would be always easier re-qualify...
UPDATE: While you still decide where to go, see this humble example of Vaadin Application
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I am a C# .NET developer and I always use Visual Studio to create my applications. Now I am studying Java with the netbeans IDE and I have no clue of how to create a Form Application?
I have used Jform etc. But this is just annoying. I was trying for 3 hours just to relocate a button while resizing my window.
Does anyone have any suggestions on how to make this easier?
Unfortunately, IMHO, creating GUI applications in Swing is a pain, especially coming from .NET.
Whenever I need to create Swing apps I find it easier to just hand code it. Although it involves much more work than in .NET, and also has a pretty steep learning curve, I find I have more control over my code that way.
BTW, once you get the hang of how things work in Swing, hand coding is pretty manageable.
Good Luck!
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 8 years ago.
The community reviewed whether to reopen this question 9 months ago and left it closed:
Duplicate This question has been answered, is not unique, and doesn’t differentiate itself from another question.
Improve this question
Is Java Swing still in use? is the most recent post I found, and it is 4 years old (now 12 years old), so...
Is Swing used at all in a professional environment? I am a student, and wondering if it is worth learning, or if its day has passed.
(I am not asking about a Swing-AWT comparison...just whether or not Swing is obsolete in the workforce.)
Majority of existing GUI java codebases are Swing and likely will stay that way until the codebase rots and nobody maintains it anymore.
Majority of new GUI java codebases are using JavaFX, which is the Swing replacement in Java8 and is part of the standard java library now. It allows for CSS skinning, HTML5 elements, and also has a very nice FXML (a dialect of XML/HTML) which allows non-programmers to "get in there" and work on the GUI layout, etc. It also has SceneBuilder which is a free/standard GUI drag-n-drop builder which auto-generates FXML for your program.
I kid not when I say FXML can replace 3,000 lines of extended JFrame class code for a Swing GUI, with 50 lines of FXML. (recent project I helped migrate).
Swing is still used heavily, and will continue to be for a long while -- after all, it was the only choice for Java for a loooong time. JavaFX, however, is refreshingly nice, and very-much-so worth learning.
As an aside -- Swing builds ontop of AWT - AWT has a lot of problems, most of which are marked as "wont-fix" by the java project (OpenJDK/Oracle). Swing was built to replace/fix AWT, however sometimes you will marry AWT objects into your Swing application. Heck, you will sometimes marry Swing objects into your JavaFX application. I would not bother with learning AWT, if you learn Swing, you are learning AWT for the most part. The largest difference with Swing vs AWT is Swing components start with the letter J. EX: JFrame vs Frame, etc.
Well, Intellij IDEA uses Swing for its UI, so I would not say that it is obsolete. Granted, I really think it could use a huge overhaul (read: something not full of spaghetti code).
Absolutely yes. Legacy swing applications are still supported and enhanced. There is no alternative for that. And if you are making applications like IDE's, SWING is still preferred. New application will of course have web-interfaces , but that really depends on the nature of the application. No generic rules.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I read about the advantages of JavaFX over Swing(that is not the point of discussion) and I would like to learn JavaFX.
But later I got confused between the JavaFX script and other things like XML, etc...
I don't have a clear picture of it yet.
I want to know what all things like basic information and programming/markup languages one must know before giving a try at JavaFX.
Well, as far as I am concerned, I would say nothing is mandatory, before you start learning Javafx. Just a small knowledge of JAVA would be enough (just the basics)
For Javafx learning resources, Oracle has one of the best available resources, enriched with lucrative examples, which will make your Journey of learning Javafx fantastic.
The fxml files are basically the UI which can be written using XML and can be loaded in your code. This makes your application follow the MVC rule. Though initially, I would recommend to spend sometime constructing your UI using java code only.
For more info on FXML
Java vs JavaFX Script vs FXML. Which is better way of programming in JavaFX?
Tutorials on Javafx
http://docs.oracle.com/javase/8/javase-clienttechnologies.htm
For Beginners, Getting Started with JavaFX is very important !
http://docs.oracle.com/javase/8/javafx/get-started-tutorial/jfx-overview.htm#JFXST784
Tutorial on Scene Builder i.e. making fxml files for your application,
http://docs.oracle.com/javase/8/scene-builder-2/get-started-tutorial/overview.htm
Tutorial on FXML
https://docs.oracle.com/javase/8/javafx/fxml-tutorial/
I started learning JavaFX last summner and it is really great and easy to use. I don't think you should know anything before start learning. A little bit xml knowladge can be beneficial but I don't think it is necassary because JavaFX secene builder generates .fxml files generically. So you can directly start using it.