How To Add Selection Listener To Jtextarea Sunday, June 30, 2013 Swing Event Handling, Swing Hacks Edit Here is a helpful article on how to listen text selection changes in JTextArea , (ofcourse on any sub class of JTextComponent). With the b... Read More
How To Set Background Image In Jtextarea Saturday, June 29, 2013 Swing Hacks Edit Here is a very simple and working example on setting background image in JTextArea. It is very easy, when you do override the paintCompo... Read More
Why Is Main Public Static Void? Wednesday, June 26, 2013 Java Introduction Edit Here is a convincing post why main() is public static void. First of all it is important to know who executes the main(). The main() ... Read More
Why Don't We Need To Write Else Return? Tuesday, June 25, 2013 Good Practices Edit Many of the starter programmers might 'forget' a very small point in their programs when writing the return statements. For inst... Read More
How To Insert Image In Jtextpane Monday, June 24, 2013 Swing Components Edit We've worked with text till date. Let's now move to images. Here is a tutorial on inserting an image in JTextPane in the easiest wa... Read More
Reading And Writing A File In Jtextarea Swing Components Edit Well in this post i will introduce two methods that will read and write the JTextArea document to a file. Reading a file is as done in... Read More
Drag And Drop A File In Jtextarea Sunday, June 23, 2013 Abstract Window Toolkit, Drag and Drop, Swing Components Edit Here is a very simple example for dragging and dropping a file in JTextArea. The aim of the kegiatan is when a file from outside is dro... Read More
How To Compile Java Files To External Directory Tuesday, June 18, 2013 Tips Edit Here is a simple thing that you can do to compile your java source files to an external directory other than the java source directory. ... Read More
How To Take A Screenshot Using Robot Monday, June 17, 2013 Abstract Window Toolkit, Tips Edit Here is an example on taking a screenshot in Java using the AWT Robot class which is earlier discussed in this blog. You do not need to... Read More
How To Close Jdialog On Escape Monday, June 10, 2013 Swing Hacks Edit I am frustrated when i wanted to close JDialog on Escape method. Now finally i got it. I encountered a method which will do the thing. I ... Read More
Example On Awt Filedialog Abstract Window Toolkit Edit This illustrates a small example on the java.awt.FileDialog, the class that does the job of a JFileChooser in Swing i.e. opening and/or ... Read More
Add Custom Components To Jfilechooser Wednesday, June 5, 2013 Swing Components Edit Let me show you how to add custom components to JFileChooser in Swing. This is very easy and even you have a method for that. In this pos... Read More
Create A Dummy Screensaver Using Swing Saturday, June 1, 2013 Swing Hacks Edit The following kegiatan illustrates creating a dummy screensaver which is not at all a screensaver. I couldn't call it as a screensav... Read More