This question already has answers here:
Closed 11 years ago.
Possible Duplicate:
Drag and Drop Java GUI
Hi about 3 months ago I started learning programming for the first time using Java as my first programming language and recently I started learning SWING and AWT for GUI.My aim is building a board game RISK for my final exam at college.Last week a friend of mine suggested I should try to switch to C# because building the GUI is very easy by using Visual Studio and learning it is easy if you know Java and OOP concepts.
To be honest the idea dosen't really intrigues me because at some point I would like to learn to build websites using JSP and Android applications.From what I know it is not posible in C# , but the idea of building fast GUI's is something I would like considering of course it is recommended for a beginner to do that.
Are there any IDE's for Java that can be used to program GUI's visually in C# ?I should also mention the fact that I'm in a bit of a hurry to finish my game project so I can start learning what I really like , like web development and application for smart phones.
Should I use a visual GUI builder for java if I'm in the process of learning programming? I already know how to use most swing objects in small programms but never tryed to build any large scale applications
Both .NET and Java have several extremely powerful GUI designers, but to answer you question directly - if you really do not have time/will to learn yet another language (C# in this case), then stick to Java and do GUI design using:
NetBeans (http://www.netbeans.org , free)
Eclipse WindowBuilder (http://www.eclipse.org, free)
IntelliJ IDEA (http://www.jetbrains.com/idea/, "free")
ANY of these can be used for development of the game you mentioned in the original post.
Eclipse has some nice Visual editors but I personally recommend NetBeans
Good luck
Regards
There are a number of Java IDEs that allow you to visually create GUIs, so I can't see that there's a need to switch to C# so that you can use Visual Studio (though, in my experience, the editor in Visual Studio was slightly better than the Java ones).
However, if you really wanted to (I wouldn't suggest it, especially if you've already dedicated some development time to your project already), Java and C# are similar enough that you shouldn't struggle to make the switch, assuming you have reasonably good Java programming skills.
Related
I want to learn android game development. I don't have any programing knowledge. So should I learn JAVA and eclipse to develop games for android.
Or should I learn Unity 3d. And is knowledge of java programing is necessary to develop android games in unity? Or knowledge of Javascript/UnityScript will do. Can I develop android games in unity with just JavaScript knowledge??
what are the benefits of unity over Java/eclipse and vice versa when talking of android game dev??
Unity 3D Mainly uses two Programming languages: C# and Javascript
Your Question is whether do you really need to know Java programming to develop games in Unity3D
The Answer would be a YES and a NO
Yes because, If you have already studied Java, Programming in C# would be a lot easier.
If you search the web, most of the post comparing C# and java says that C# is somewhat similar to Java aside from both of them being Object Oriented.
No because, although they are somewhat similar C# is another programming language that Evolve from Java and Developers and apps today mostly use C# in developing android Applications.
Here is a quote from one of Microsoft's Documentation:
Naturally, Java came before C#, and C# was not created in a vacuum. It is quite natural that C# learned from both the strengths and weaknesses of Java, just as Java learned from Objective-C, which learned from C. So, C# should be different than Java. If Java were perfect, then there would have been no reason to create C#. If C# is perfect, then there is no reason to create any new programming language. The job would then be done. However, the future is unclear, and both C# and Java are good object-oriented programming languages in the present, so they beg to be compared.
It is important to note that not everything can be covered here. The
subject matter is simply too large. The goal is to give enough
information so as to help managers and software developers make a
better-informed choice about which language to use in certain
situations. Maybe some little language quirk in C# may make someone
choose Java. Maybe some blemish in Java will influence someone to pick
C#. Either way, this document will attempt to dive deep enough into
details to dig up some hidden treasures that aid in our goal.
For a more in depth explanation, here is a Documentation on programming languages, comparing C# and Java
If you will be learning either C# or Javascript it is better to know what their differences are first.
Here is a post about Syntax differences in C# and Javascript
For in depth tutorials
here is an Ebook on Learning C# programming in Unity 3D. You can also visit Unity3D's website for their own collection of tutorials.
Android Game Development using unity involves learning C# or a butchered version of javascript(which i don't recommend). As apposed to using java with eclipse.
Advantages of unity
-HUGE amount of people use it, ie lots of examples.
-Can port to other environment easily if you're careful about platform specific code.
-comes with most of the instructions you need
Advantages of Java/eclipse.
-maybe less people use it?(not sure as i use unity for the most part)
-AFAIK can not port to some environments(AKA Apple Devices)
Either way you need to learn a programming language, and both eclipse's java(not javascript) and Unity's c# are both popular and SIMILAR in a lot of ways, so after learning one it would not be too difficult to learn the other. BUT just as the comment says, if your brand new to scripting, then it's better to learn generic information about how and why both languages work.
IMHO i would choose to use unity (but i'm very biased) i find that most problems have been gone over and answers are handily available.
Hope this helps... let me know if you need further insight into unity.
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 9 years ago.
Improve this question
I was figuring out on the net, how to create a desktop application with Java. I found I can do it through NetBeans IDE. Is there a better IDE?
Can you suggest me a suitable eBook for learning Java NetBeans?
There are three major IDEs for Java:
NetBeans - https://netbeans.org/
Eclipse - http://www.eclipse.org/
IntelliJ - http://www.jetbrains.com/idea/ (This one is a commercial product.)
Pick your religion.
Actually, you can create desktop application with Java Swing GUI Toolkit, which is a part of the Java JDK, regardless of the IDE. #Lee Meador gives you some to choose from.
Here is a tutorial on making a simple desktop application with NetBeans.
There are also tons of YouTube tutorials for beginners. Search for "Java tutorials" and you'll be all set.
IDE preferences are fairly subjective. Netbeans is not bad. Eclipse is also a good IDE. My favorite one, though, is IntelliJ IDEA. They have a free Community Edition which lets you do a lot of things, but I paid for it to get full functionality.
As far as eBooks for learning about the IDEs, I would suggest just looking on the website of whatever IDE you end up choosing.
Here's how I see things when it comes to IDE's:
NetBeans is fantastic for beginners, but the code it generates for the Swing WYSIWYG editor looks like absolute garbage. If you're okay with keeping the code in NetBeans and not worrying about how the code for you GUI looks, it's an excellent way to go if you don't feel like hard-coding Swing.
Eclipse is a very professional and powerful tool, but it's a bit daunting at times as well, and it's not quite as quick and easy to get things up and running. It has no built-in drag and drop Swing editor (although Google provides an excellent one called the Google Plugin for Eclipse) but it's got far and away the most powerful debugger I've ever used.
I don't know a lot about IntelliJ other than that it's also a good choice for beginners and professionals alike, but I haven't seen as much community support for it. That may just be because I've been an Eclipse die-hard for ages, but that's just how I see it.
What's more important than your IDE choice is that you figure out early on how to use it to its full potential. All three are excellent pieces of software, and all three will help you do whatever it is you want to build. But they can only help you if you learn to use their organizational tools, their editor/template options, their respective debuggers, etc. Honestly, I would say if you have any friends that are Java developers, choose whatever they're using at least for now so you have someone to go to when you don't understand how to use a particular option.
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
I am looking to start developing applications for Android and i was wondering if you could fill me in on the know how's and the requirements on a technical viewpoint.
I have the SDK, Eclipse and Java installed and even a handset to "real" test on.
My question is being a complete amateur to Java and having never used the language how much java would i have to learn to develop Android Applications ?
I would say you can just start with some tutorials the same way you would when starting with just Java. You'll learn along the way, just use a lot tutorials.
There is not much difference for the language, but there is a great difference in the framework, ie. the way you set up applications.
So just Java you would learn:
public static void main(String[] args){
System.out.println("Hello World");
}
In Android it would be:
public void onCreate(Bundle savedInstanceState){
super.onCreate(savedInstanceState);
System.out.println("Hello World");
// Or:
Log.v("MyActivity", "Hello World");
}
to print "Hello World" to the console respectively the log.
The short answer is no since nobody has a "complete" understanding of Java anyway.
The longer answer is the complexity of your Android apps will be limited by your knowledge of Java. You can probably learn to write a "Hello, world!" app on day one, but it will take several months before you can write simple but useful apps. It also depends on how whether you are new to Java or new to programming in general.
My suggestion is to get a good introductory book on Java and maybe another on Android apps and start there.
Barry
For basic applications - no, a "complete" understanding ist not essential. What you'll have to learn is to use the android framework, and I think, if you grab some android related tutorials and books, then it should be OK even if you start with basic Java knowledge.
(I assume, that you already know some other language and have a decent experience with object oriented programming)
You should have a good understanding of both Java and object-oriented programming.
You should have a firm grip of how Polymorphism and Inheritance work in java. These are pretty central to Android development. Also, having an understanding of java memory optimization and Threading are useful skills for writing more advanced applications.
Learn java up to understanding within reason the following concepts/implementations:
Object Orientation (this is a biggie)
Interfaces
Superclassing / Extending
Some ultra-common java APIs and syntax
Our good friend, mr. garbage collector.
Then you'll be ready to go in Android dev. I wish I had read the book "Head First" java development before starting with Android, it would have helped me immensely.
You would benefit immensely by learning Java first. All of the "Android" code is Java-based so you will handicap yourself by not going through a few tutorials (at the least) to get caught up on Java.
I would suggest NOT starting with Java first, as others have said the framework is so different you will be learning syntax that you will not use writing Android Apps. Get a good book on Android development for beginners and start from there. I've found Android Application Development for Dummies to actually be a very good book, as well as O'Rielly's Learning Android. As you come across the need for Java knowledge, then hit the Java Tutorials over at oracle.com, pick up what you need and then back to Android specific documentation.
You aren't going to be using System.out.println in a real Android App, you will be setting a textView either programmaticly or in XML, so learning the Java way won't be all that helpful.
Start here: http://developer.android.com/resources/browser.html?tag=tutorial and do all the tutorials.
You need to be familiar with the basic Java tasks
knowing what is a package, a class, some inheritance
understand the building of your app (compile, link and packaging)
debugging
You can start with building the tutorial sample, then going down in Java code progressively.
It depends on the complexity of your app. If you will be building complex and high quality apps like Google Maps or Angry Birds you do need to know Java very well. I would suggest you to learn Java because you can make lots of things with it not only make apps for Android. Good luck!
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
Most of the desktop application development I do is in Swing, and I'm curious to hear people's thoughts on using JavaFX and/or Adobe Flex for building desktop applications. Have you had success building desktop apps with these? Or would you stick with Swing for now and use tools to help make Swing development more productive?
If you're making desktop apps, I'd stick to Swing. JavaFX/Flex/Silverlight would be more appropriate for RIA - rich internet apps. Although I'd argue that none of them would be a choice for the long term - looks to me like HTML5/CSS3/Ajax are winning the day, but thats a pretty subjective area. But for desktop apps - I'm a big fan of Swing (also Java Web Start is a very underrated technology)
I would say that JavaFX can be seen as a kind of extension of Swing with a new way of developing a Java GUI by using a declarative programming language: the JavaFX Script. JavaFX Script code looks exactly like a JSON script, unlike Adobe Flex or Microsoft Silverlight which uses an XML syntax.
JavaFX Script can interface with Java and therefore can call Swing components easily. It's really a new generation of GUI API, like Swing was for AWT: nice graphical components, new easy ways to manage layouts, really nice features to build dynamic interfaces: bindings, timers (to build animations), etc. Have a look here: http://www.javafx.com/samples/ and to the tutorials and see how fast you can build a kind of Google Picasa application... The API even contains some tools to use easily web services: you can find plenty of samples of GUI built in JavaFX connected to some public web services (like a Weather Forecast tool).
And the best... is the deployment part. You can embed your application within an html page, like an applet, and the user can drag and drop the application to her/his desktop to use it whenever she/he wants (without returning to its browser)!
Really, I think JavaFX, at its early stage though (v1.2), is a really good tool and represents the first step for Java toward the next generation of applications: the Rich Internet Applications (RIA).
Java Swing is an established and mature technology for desktop development. You'll be able to find lots of information online and plenty of sample programs. With that said, however, you might want to consider Adobe AIR. AIR is basically a runtime that lets you run your Flex apps on the desktop, and gives them access to local resources such as the file system. I've written Java Swing apps for 10 years and I am amazed at how much more productive I am using Flex/Adobe AIR. One nice aspect of Flex is that you can create your GUIs declaritively, much like how you use HTML to declare the layout of a webpage. It's a much more concise way to specify a GUI, and much faster and easier to maintain than the reams of Java Swing code you need to do the same thing. I wouldn't recommend JavaFX since it is so late to the party and hasn't really gotten with mainstream developers.
You should try them all and see which one fits best with your requirements. If you want to see what you can do with Flex and how to do it then check out Tour de Flex.
Some of the advantages of Flex are that it is mature (over 5 years old now) and a significant area of investment for Adobe. You can also find numerous examples of AIR apps built with Flex in the Adobe AIR Marketplace.
Swing can look good with Substance L&F.
However, if you are developing alone (as opposed to with a team), trying JavaFX might be a good idea.
Please read the about this, write extremely lightweight swing applications and with the same code base move it to web.
demos
runtime
I had evaluated these for desktop application and finally desided to go for JavaFx . This have very good media library and hardware accelerated graphics and media capabilities . With Jdk 7 update 6 onwards contains JavaFx totally I integrated no separate installation is required . Java swing is very good technology and will be continued but I see JavaFx is the future for GUI and Internet application to some extent. Biggest advantage for me was that JavaFx app could be converted to exe files with native packaging
Also try scenebuilder for drag and drop component designer
I feel that I do not have enough information to answer this question. There are many applications in which an AIR approach is a better choice, other applications use other technologies better. I am primarily an AS3/Flex developer, but I know there are many instances where one of the Java platforms is a better choice. Now that Flex is no longer an Adobe product but rather a Apache product, it will either improve the product as the users will create the roadmap, or kill it off completely.
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.
Improve this question
For "best" I intend that the code shouldn't need, or need very few, platform specific tweaks.
I strongly recommend Java for cross-platform GUI development. In particular, I recommend the GUI builder that comes with the Netbeans IDE. It's very simple and very powerful. You can point and click and drag and drop to create a GUI, and easily customize the actions which various buttons and other components take.
I much prefer Python as a language, but none of the free tools for GUI development come anywhere close to this, and the same thing seems to be true for the other languages I've used. (I should point out that QT has wonderful GUI developers for various languages such as C and Python, but it's only free when used on open source projects.)
EDIT: QT has recently been relicensed as LGPL, so you're free to use it in commercial applications. The Python bindings for this (PyQT) have not been re-licensed, but another project called PySide has been created to provide Python QT bindings.
I personally despise the whole concept of emulating the native GUI that is where the Java GUIs are rooted. Instead of being at home wherever you go, it makes you a tourist everywhere, often needing an interpreter. The Eclipse GWT is a better toolkit that makes much better use of local resources, but it still holds that people love to write Java code, and hate to use Java applications, think of it: which Java applications you love on your desktop?
Tk is just as ugly and limited on any operating system you choose to run it onto, and the same goes for Qt, in my opinion.
Mono would need a good try, as it is a way to answer the question "why Linux sucks", if you remember that old post bi Miguel de Icaza. Mono comes with a mature set of widgets and Apis and does not try to limit what you can do in order to give you portability.
Silverlight is close to portable and has a great interface definition language, but lacks access to the system, you have to split the application between a server and UI even on the same machine to overcome it.
Adobe AIR is a dog and local system acces is not easy.
If I am able to choose, I tend to avoid GUIs altogether and try to use a web server, even a local web server, and Json, JQuery and all that stuff. I found out that I can have many more choices and am more productive than with native widgets. This combines the strengths of the use of a real language server side and the wonderful disordered geniality of JavaScript in the GUI.
Yes: use Eclipse RCP. You can write not only cross-platform, but e.g. multilingual applications with it. SWT provides the native look-and-feel for multiple platforms and windowing systems.
So as I understand it, there is currently NO truly cross-platform high level language & GUI toolkit right now.
Java is cross-platform, GUIs in both SWT and Swing can look good, when you really try hard to tweak them pixel-precise and provide modifications to the look to supported platforms. There are currently some good GUI designers, but nothing as great as OpenStep 15 years ago.
QT is now LGPL'ed so long as you only link to it dynamically. Well but QT has its own set of problems and is a superset of C++. You have to compile against QT-hacked compiler, not the generic C++ one.
didn't try the wxWidgets, but from the looks of it, it can work, but is NOT high level toolkit at all!
There seems to be an option to write in C# and opensourced .NET and run it via Mono in other platforms than Windows... Didn't try, but it seems to me, that is just porting Microsoft on other platforms.
There is GNUstep, but for now it looks for me, like it is only developped by some opensource geek fans. It would be really interesting to see the OpenStep stack outside of the Mac OS X, but for now this looks to me as not viable.
Even Java, while it is self-contained, does not currently provide great GUI designer capabilities. I used the GUI designer tool once when starting to learn how to code with SWT, and now I find myself coding it by hand, which is really not bad, but it really should not be necessary. But that was few years ago, I will have to try again.
You can of course create your cross-platform application core and service code in one language (Java, or C/C++ if you want speed), creating something like a server or unix tool and just connecting to it from the GUI that you create on each desired platform using its own tools. The result is that the GUI is platform native, taking advantages of the features of the platform, and should be fairly simple to create for each desired platform. (Cocoa on Mac and .Net on windows provide rich features for the platform they are native to).
We will have to look into the robustness and matureness of such ideal solution. It should have good commercial and comunity backing and be fairly evolved right now, so as the future implementations of such tools will provide us with more than the mere LOWEST COMMON DENOMINATOR for all the supported platforms, but to leverege the cross-platform tools to include and adopt well-designed concepts and rich features native to the relevant platforms and distribute them cross-platform.
Only than can be cross-platform development truly viable and adoptable in great numbers.
Suggestions?
Java is certainly nice, but I've been doing just fine with Python and Qt via PyQt4 lately. I find that I get things done faster than I did in Swing or SWT, too.
So far, no platform-specific tweaks have been necessary, and Qt4 widgets look nice on different platforms. The Qt GUI builder is very nice, and using Python has enabled easy integration with some other cross-platform frameworks (notably VTK, scipy-cluster, and some SWIG-wrapped objects for interfacing with files output from a performance tool).
Note that Qt is not free unless you use it on open source projects.
As long as someone defines "platform independence" correctly, Java is the best.
Some people argue that C# is the best, but those people seem to misunderstand the term
"platform independence" ;)
Note: I refer to the fact that C# is ported to Linux/Unixes only as long as Microsoft and Novel keep up their treaty. The community itself would never be able to maintain such huge platform as .NET
These days there are many languages that allow you to create cross-platform GUI applications efficiently. Java, Python, Tcl/tk, C#...
I think you need to define the requirements of your application a bit more, for instance:
Will the UI be Web-based, or desktop-based?
Is the application going to be a large or a small?
Will it feature some sort of "extension" feature (e.g. plug-ins)?
Will it function over a network, and is it likely to be distributed/load balanced?
The list can go on forever, work out the defining points about your application, and start researching the language based on the whole.
I would also consider Mono as serious contender for platform independence and a good IDE tool.
Java's performance sucks on the desktop. Just check http://www.codeproject.com/KB/dotnet/RuntimePerformance.aspx
For native binaries, wxWidgets is a convenient solution.
I would tell you that is even better than Java for the user experience side. Even though you can make the presentation layer look pretty much the same for all platforms in Java, they all look like Java. On the other hand, wxWidgets make the user feel like a platform specific build (and it is, indeed), but you can use the same code to compile for several platforms (at least the major ones).
I would think that it depends on what kind of platforms you plan on targeting. Java will have the most platforms with a VM. However, if you just want to use Windows and Linux, you can use C# (using mono on linux).
Based on your definition, no. Even wit the newest graphical libraries you can expect to do a bunch of testing on different platforms.
Flash would probably be the best. Wide spread and better at looking the same across different platforms.