Exploring Tk::JComboBox Perl module contains a tutorial for usage of the Tk::JComboBox widget.
This tutorial assumes a familiarity with basic Perl/Tk concepts. It is meant to be used alongside the JComboBox class reference.
What is it and what is it good for?
JComboBox is yet another combo box implementation for use with the Perl/Tk Toolkit. A combo box is a widget that can activate a popup (or dropdown) listbox with a number of selectable items. After an item is selected, the listbox disappears and that item appears on the widget. This is a space-saving alternative to having a full list in the interface, or having a very long Frame or Menu full of radio buttons. In addition to providing a way of selecting one item from a list of options, a Combo Box can also allow a user to add an entry that does not necessarily appear within the list.
This implementation is named for the JComboBox component in the Java Swing classes, and those familiar with that component should have no problem using this because both share several superficial similarities including method names and general behavior -- its a passing resemblance at best.
When compared to other similar Perl/Tk widgets, JComboBox is probably the most bloated or to put it another way, feature-rich. It has a slightly larger overhead associated with it than any of the others. Simply put, there is more code required to support the extra options and methods it offers. In applications I have used it in, I've found that the cost is negligible and that the benefits outweigh the cost, but since requirements and constraints vary, it's probably best to determine this for yourself, and to check out the alternatives.
Two Modes of Operation
Like other Combo Box implementations, the JComboBox has more than one mode of operation: uneditable and editable. The mode can only be set once, at creation time. To better distinguish the two modes, the uneditable mode is called readonly. Unlike other similar Combo box implementations, each mode is distinctive and like having two different Widgets bundled as one. Each mode has a separate default visual appearance, and can affect how options are processed. This is done to emphasize the differences between the two. The basic question is why should an element that looks like a text field, not be editable like a text field and vice versa? So, when a JComboBox is editable it resembles a text field. A user can edit it directly like other text fields, or select one of the items from the list of choices. In readonly mode, the JComboBox resembles a Button, that displays the selected item on its face.