Posts Tagged "Swing"

Tracking the Caret in a JTextArea with Java

A lot of people on the board right now are making their own little text editors. It is a great little project to start when you are breaking into a language like Java. They are not exactly original with the names though like "nText" and "pText" and "zText" and "wtfText". Usually their main focus is on highlighting or trying to mimic the functionality of some of the great text editors ...

Add an Icon to the System Tray Using Java 6

So you may have wondered "How do I get a nifty little icon in the system tray for my Java App?" and after 20 minutes of banging your head against the wall you got dizzy, fell down, and probably passed out to only wake up and forget what you were doing. Then you go on your merry way to play some Nintendo Wii Fit. Yeah right! We all know you ...

Introduction to a Java JTree

Monkeys and Koalas are not the only things that climb trees, Programmers do too! But our trees are a bit more virtual. In Java (and many other languages) there is a control known as a Tree or Treeview. It is used to create a hierarchy display much like you see in Windows Explorer in the left hand pane. You can see nodes and how they relate to one another much ...

Speaking Mouse to Hunt Down a Popup Menu

The mouse is one of the most abused input devices on today's computers. Second to maybe the keyboard, it is essential for gathering input from the user. We tell it what to do but what if we stopped a second and had our application listen to it? I mean, REALLY listen to it and not just that listening you do when your favorite show is on TV and your girl ...