 |
| |
| META TOPICPARENT | name="SwingLabs" |
Home | Changes | Index | Search | Go <-- This creates the navigation links to : Home | Help | Index | etc. --> | | | In reality, however, that's a risk I'm willing to make. It won't cause that many problems, and will make many more developers lives easier.
JXSplitButton?/JXMenuButton | |
< < | We've seen these crop up on the web in the past, and there are equivilent components in Winforms. I consider this one of the basic missing components. Especially in Microsoft Vista, where Menus seem to have disappeared entirely in favor of menu buttons and popup menus. We're going to want to make this behavior available. | > > | We've seen these crop up on the web in the past, and there are equivilent components in Winforms. I consider this one of the basic missing components. Especially in Microsoft Vista, where Menus seem to have disappeared entirely in favor of menu buttons and popup menus. We're going to want to make this behavior available. Tim B. has one from netbeans/contrib. Need to look into this! | | | JXToolBar?
Extends JToolBar? so that if the bar is too short for the buttons on it, some scrolling indicator will exist on the toolbar to allow the user to see all the buttons (or perhaps a button at the end that will drop down a menu with the hidden actions). | | | The basic design NetBeans and FireFox? use are good
JXPropertiesSheet? | |
< < | Cool, and Fred already has a great one  | > > | Cool, and Fred already has a great one :). Josh has also been working on one with an API I really dig. | | | JXHeader | |
< < | We talked about this quite a bit, Romain has a good starting point (plus, it looks really good). Probably have Title and description area, where the Title is a JLabel and the description is a JXEditorPane? or something. | > > | We talked about this quite a bit, Romain has a good starting point (plus, it looks really good). Probably have Title and description area, where the Title is a JLabel and the description is a JXEditorPane? or something. -- DONE | | | JXVerticalTabbedPane?
On the lines of JXVerticalLabel?, a JTabbedPane? which does not look strange (with flags sticking out of a panel unsupported) when in the EAST or WEST orientation. | | | JFileCopyPane?/JFileDeletePane/JFileMovePane
Having some prebuilt components that handle moving, deleting, and copying files would be nice. Generally this is a specific dialog look and feel on different plaforms, and it would be nice for Swing applications to look/feel like their native counterparts in this case. | |
> > | OS X Widgets
Various widget/painter ideas here: http://mattgemmell.com/source need to be explored for SwingX?.
JFileChooser? replacement
There is no good file chooser option under Java6, Windows XP. File Dialog uses the Win2k L&F instead of Win2k one and JFileChooser? has the following highly visible flaws:
- There is no auto complete while typing paths.
- Hitting ENTER while a directory is selected closes the dialog, as opposed to drilling down into the directory as the native dialog does.
- There are other minor visual and keyboard navigation mismatches when compared to the native dialog.
|
| |
| META TOPICPARENT | name="SwingLabs" |
Home | Changes | Index | Search | Go <-- This creates the navigation links to : Home | Help | Index | etc. --> | | | JXFrame/JXDialog: animate resize
In MacOSX?, there are times when a window (probably a dialog most of the time) will change its size based on a selection. For example, properties dialogs do this a lot. When you open a property dialog the contents of each sheet can be different sizes. So what OSX does is when a new property sheet/pane is shown, the dialog resizes to match. This would be really easy to accomplish, I think. What they do is that the new page is shown, and then the dialog has an animated resize to match the new page. This means the layout manager has to cooperate. Its kind of the inverse of what we normally do. Normally we have the layout manager adjust the contents to match the dialog -- what we sometimes want is for the dialog to match the layout manager. This should be possible by getting the preferred size of everything from the layout manager and then adjusting the dialog to that. | |
> > | JXPanel/others?: add components using varargs
When hand-coding GUIs and putting together a panel of components, each component you add requires its own call to add(). Since we have varargs in JDK 5, we could add a version of add() which would take a vararg number of components, such that the entire list of components could be added in one go: panel.add(button1, button2, button3). Additionally, the panel constructor itself could have a vararg, so the panel could be constructed and populated in a single line: JXPanel panel = new JXPanel(button1, button2, button3). | | | JXGlassPane?
Simplified component to make it easier to write GlassPanes?. Romain has some tips for this (like managing opacity, etc). It would be good to have several default JXGlassPane? implementations/properties as well, such as FadeIn?/FadeOut GlassPane? (or properties on JXGlassPane?), JXInfiniteProgress? (extends JXGlassPane?), etc. |
| |
| META TOPICPARENT | name="SwingLabs" |
Home | Changes | Index | Search | Go <-- This creates the navigation links to : Home | Help | Index | etc. --> | | | Common Translations
It'd be awesome if we had a jar containing resource bundles for common items such as "Cut", "Copy", "Paste", "Exit", "Start", "Run", "Open File", "Save As", etc etc, translated into as many different languages as possible. | |
> > | Common Translations
We need to include a common set of cell editors/renderers for trees, tables, and lists. We should include:
- Date Renderer/Editor
- Currency Renderer/Editor
- Formatted Renderer/Editor (based on locale)
- This needs to take advantage of the AbstractFormatterFactory? enhancements listed on this page so we can support ip addresses, zip codes, numbers, etc
- Slider RendererEditor?
- Progress RendererEditor? (this one is iffy due to the dynamic nature of it -- need to solve the problem sooner or later though)
| | | Report Maker
A different/unique approach to creating reports in Java. Whereas other frameworks (JasperReports?, in particular) take the approach of defining a new UI component heirarchy (vi XML, usually), this tool would use Swing directly. This has several advantages:
- Rich UI (gradients, opacity, borders, fonts, icons, images, etc etc)
|
| |
| META TOPICPARENT | name="SwingLabs" |
Home | Changes | Index | Search | Go <-- This creates the navigation links to : Home | Help | Index | etc. --> | | | JXFrame/JXDialog: setWaitPaneVisible(boolean b)
Shows the wait pane, if there is one (if b = true), or hides it (if b = false). This method could also call setEnabled(b), and setWaitCursorVisible(b). Or, there should be another method that accomplishes this so that these 3 calls can occur by default together (which seems like a reasonable, common use case) | |
> > | JXFrame/JXDialog: animate resize
In MacOSX?, there are times when a window (probably a dialog most of the time) will change its size based on a selection. For example, properties dialogs do this a lot. When you open a property dialog the contents of each sheet can be different sizes. So what OSX does is when a new property sheet/pane is shown, the dialog resizes to match. This would be really easy to accomplish, I think. What they do is that the new page is shown, and then the dialog has an animated resize to match the new page. This means the layout manager has to cooperate. Its kind of the inverse of what we normally do. Normally we have the layout manager adjust the contents to match the dialog -- what we sometimes want is for the dialog to match the layout manager. This should be possible by getting the preferred size of everything from the layout manager and then adjusting the dialog to that. | | | JXGlassPane?
Simplified component to make it easier to write GlassPanes?. Romain has some tips for this (like managing opacity, etc). It would be good to have several default JXGlassPane? implementations/properties as well, such as FadeIn?/FadeOut GlassPane? (or properties on JXGlassPane?), JXInfiniteProgress? (extends JXGlassPane?), etc. | | |
JXTaskBar? and JXWindowsMenu?: Enhancements for users of JDesktopPane? | |
< < | For those apps using JDesktopPane?, these two components can greatly improve its usability, particularly if your users are used to the Windows taskbar. See the tutorial with download. | > > | For those apps using JDesktopPane?, these two components can greatly improve its usability, particularly if your users are used to the Windows taskbar. See the tutorial with download. Rbair: Cool! | | | |
| |
| META TOPICPARENT | name="SwingLabs" |
Home | Changes | Index | Search | Go <-- This creates the navigation links to : Home | Help | Index | etc. --> | | | There should also be some logic for allowing the toolbar to be configured by the user, including hiding or showing different buttons, etc.
JXImgTextField? | |
< < | A text field which allows embedding an image inside the text field, like in the iTunes search toolbar, where the magnifying glass is inside the search field. I've seen no easy APIs for this. | > > | A text field which allows embedding an image inside the text field, like in the iTunes search toolbar, where the magnifying glass is inside the search field. I've seen no easy APIs for this. Other uses might be drawing some error icon upon a validation error. Maybe coupling some sort of highlight to the textfield (say when the focus moves to it, or when there's a validation error) can also be included. | | | JXMultiSlider?
A slider allowing to select a range rather than a value, with two thumbs. | | | JXHeader
We talked about this quite a bit, Romain has a good starting point (plus, it looks really good). Probably have Title and description area, where the Title is a JLabel and the description is a JXEditorPane? or something. | |
> > | JXVerticalTabbedPane?
On the lines of JXVerticalLabel?, a JTabbedPane? which does not look strange (with flags sticking out of a panel unsupported) when in the EAST or WEST orientation. |
| |
| META TOPICPARENT | name="SwingLabs" |
Home | Changes | Index | Search | Go <-- This creates the navigation links to : Home | Help | Index | etc. --> | | |
- International country codes
- Airport codes
- US Zip Codes (or for other countries, where these are known and published).
| |
> > |
Common Translations
It'd be awesome if we had a jar containing resource bundles for common items such as "Cut", "Copy", "Paste", "Exit", "Start", "Run", "Open File", "Save As", etc etc, translated into as many different languages as possible. | | | Report Maker
A different/unique approach to creating reports in Java. Whereas other frameworks (JasperReports?, in particular) take the approach of defining a new UI component heirarchy (vi XML, usually), this tool would use Swing directly. This has several advantages: | | |
- Fraction
- Phone Number
- Zip Code
| |
> > |
- IP Addresses, network masks
| | |
- ForbiddenChars? (makes it easy to define a set of forbidden chars, rather than defining the appropriate regex)
- Alpha/AlphaNumeric (same as ForbiddenChars? -- simplifies the process)
| | | These are interesting and fun in their own right, but when combined with timingframework and animated transitions it could create some really intersting applications... | |
> > | Enhanced mnemonic support in JButton, JLabel (others?)
For example:
JXButton button = new JXButton("Save &As");
should cause the proper mnemonic to be set (VK_A, position 5). Microsoft has traditionally used the & as the indicator of the mnemonic (such as "Save &As"), but in Avalon they appear to use _ which makes more since (like "Save As"). We could be overly configurable and have a "setMnemonicChar(char c)" method that indicates what the mnemonic char code is ( or & or whatever) but I'm against this. If the text is specified in a resource file, then you won't know what the char code is in the swing file, and it just makes things messy. This is, also, a backwards incompatible change unless we have a "setComputeMnemonic(boolean)" method that will toggle whether to attempt to compute the mnemonic. This again is hacky because the developer making the API call doesn't know what is in the resource file, and so doesn't know whether "_" or "&" will collide with what the localization experts have put in the file.
In reality, however, that's a risk I'm willing to make. It won't cause that many problems, and will make many more developers lives easier.
JXSplitButton?/JXMenuButton
We've seen these crop up on the web in the past, and there are equivilent components in Winforms. I consider this one of the basic missing components. Especially in Microsoft Vista, where Menus seem to have disappeared entirely in favor of menu buttons and popup menus. We're going to want to make this behavior available. |
| |
| META TOPICPARENT | name="SwingLabs" |
Home | Changes | Index | Search | Go <-- This creates the navigation links to : Home | Help | Index | etc. --> | | | SpellChecking? on All UI Components
Hook into the native dictionary for all spellchecking needs! | |
> > | JXShape, JXEllipse, JXRectangle, JXLine, etc
Create a JXPanel derivitive for each of the Java2D? drawing primitives. So, JXEllipse extends JXArea which extends JXShape which extends JXPanel, etc. Map to the Shape, Area, Ellipse, etc primitives. Each should have a setRenderingHints method (ideally this would be available on JComponent, but should really be on JXPanel at least), setStroke, setPaint, etc matching the operations available on a Graphics2D? object. The paintComponent method for each of these panels would then simply execute the correct Graphics2D? calls and draw the appropriate shape.
These are interesting and fun in their own right, but when combined with timingframework and animated transitions it could create some really intersting applications... |
| |
| META TOPICPARENT | name="SwingLabs" |
Home | Changes | Index | Search | Go <-- This creates the navigation links to : Home | Help | Index | etc. --> | | | Better nonvisual components
Winforms beats us up in a couple of places in the UI builder department. One is a better set of nonvisual controls. I'd like to see things like SwingWorker?, ImageIcon?, Image, DataSet?, Timer (or better yet, TimingController? from timingframework.dev.java.net), HTTP, Help, TrayIcon?, etc all be normal, useable java beans with proper property editors etc for use within the GUI builder | |
> > | JXYahooMap?
Or maybe not JX anything, but just YahooMap?. Provide a simple to use Swing component that has access to all the YahooMaps? functionality. Its just a JPanel with a special background, so you could build whatever components on top of it you want (including, push pins, images, buttons, etc etc).
JXChooser
We talked about this some time ago. Rather than taking a JComboBox? and extending it to support drop down tables and such, it would perhaps be better to have a JXChooser component that would be more flexible than JXComboBox?. Details are sketchy at this point.
JXAccordian
Bino wrote one of these once upon a time -- we should see if we can round it up. Like the JXTaskPane? in purpose, different in visual appearance/use. This type of component has a stack of buttons, when you click on a button all the other buttons either go to the bottom or top of the space, leaving an empty middle area for content. Funky edge cases, but a useful component
Fred has one of these, way cool, we should beg to see if we can get it too
JXRichEditorPane?
Combines a JTextPane?/JXEditorPane (or some such) with a toolbar and basic built in functionality. Drop one on a form and it has all the bold/italic/center/left/right/etc functionality with a toolbar ready to go (with a JXFontChooser!!)
JXGradientPicker?
Josh Marinacci has coded one up, need to get it out there. This is an awesome gradient chooser component. Requires new API for handling gradients (some talk of getting this into Dolphin, currently code from Batik). The basic API is quite simple (150 lines or so), but the implementation is rather large (1/2 meg!), so the implementation jar has been separated out as an optional download, only required if multi stop gradient/radial gradient support is required.
VisualWorker?
Like the C# BackgroundWorker?, this would bring SwingWorker? to the visual builder world. Basically, rather than being a class that is extended and overridden, this is a class that is composed of event handlers acting as "callback" methods. It produces more ... spaghetti code, IMO, but a better visual builder experience. A necessary evil, as it were. Maybe we could improve on the concept, though.
AbstractFormatter?/AbstractFormatterFactory implementations
A set of long-missing implementations of AbstractFormatter? and AbstractFormatterFactory? for handling common datatypes with JFormattedTextField?. These would include:
- Currency
- Regex
- Number
- Email
- URL
- Percent
- Date
- Time
- Scientific
- Fraction
- Phone Number
- Zip Code
- ForbiddenChars? (makes it easy to define a set of forbidden chars, rather than defining the appropriate regex)
- Alpha/AlphaNumeric (same as ForbiddenChars? -- simplifies the process)
Vertical Orientation for JLabel
Like http://jroller.com/page/henribenoit?entry=vertical_labels |
| |
| META TOPICPARENT | name="SwingLabs" |
Home | Changes | Index | Search | Go <-- This creates the navigation links to : Home | Help | Index | etc. --> | | |
- Airport codes
- US Zip Codes (or for other countries, where these are known and published).
| |
> > | Report Maker
A different/unique approach to creating reports in Java. Whereas other frameworks (JasperReports?, in particular) take the approach of defining a new UI component heirarchy (vi XML, usually), this tool would use Swing directly. This has several advantages:
- Rich UI (gradients, opacity, borders, fonts, icons, images, etc etc)
- Ready use in any GUI builder
- Easy to understand for Swing developers
BeanInfo? for SwingX? Components
All of our SwingX? components need a rich set of BeanInfos?. This will ensure that they work well out of the box for any GUI builder (Netbeans, JFormDesigner?, JDeveloper, JBuilder, probably even Eclipse, but I don't know their Swing GUI builder story). A starting point exists, but they need more detailed analysis and implementations.
JXFrame/JXDialog: setCancelButton and setDefaultButton
JFrame should support a simple "setCancelButton" method taking an AbstractButton? (although make clear in the documentation the JButton use case for new developers who might not know that JButton is an AbstractButton?). Likewise a setDefaultButton method should exist.
JXFrame/JXDialog: setKeyPreview(boolean b)
This comes from WinForms?. Essentially it is a simple boolean (setKeyPreview/getKeyPreview) that will turn on event handling for the JFrame so that whenever a keypress or related event occurs, it will be trapped by the JFrame and passed to some event handlers for dealing with. I believe there is a mechanism in Swing for doing this already (otherwise we wouldn't be able to trap the ESC key to close a frame/dialog), but IIRC it is rather involved and should be simplified
JXFrame/JXDialog: StartPosition?
A simple enumerated type on the JXFrame/JXDialog indicating where it should appear on the screen when shown. Values include: CENTER_SCREEN, CENTER_IN_PARENT, MANUAL, OS_DEFAULT.
JXFrame/JXDialog/JXPanel/JXTabbedPane/others?: setWaitCursorVisible(boolean b)
Designed to be toggled at runtime, this property affects the cursor for this component and all child components by making them use the wait cursor (if true), or restoring the cursor to its previous value for each component (if false). Simply acts as a useful toggle for a common use case.
JXFrame/JXDialog/JXPanel/JXTabbedPane/others?: setEnabled(boolean b)
Simple toggle to disable the JXFrame/JXDialog and all sub components (if false). When toggled to true after having been false, all of the components will be re-enabled to their former state. So, if I had a JFoobar component on my JXFrame and it was enabled, and I call form.setEnabled(false) then it will be disabled, and if I then call form.setEnabled(true) then it will be enabled. If, however, JFoobar started off diabled, then after the form.setEnabled(true) call, JFoobar would remain disabled.
JXFrame/JXDialog: setWaitPane(Container c)
This will end up being the GlassPane? to use when setWaitPaneVisible(true) is called. The old glass pane will be saved off, and replaced by c. When setWaitPaneVisible(false) is called, the other glass pane will be restored.
JXFrame/JXDialog: setWaitPaneVisible(boolean b)
Shows the wait pane, if there is one (if b = true), or hides it (if b = false). This method could also call setEnabled(b), and setWaitCursorVisible(b). Or, there should be another method that accomplishes this so that these 3 calls can occur by default together (which seems like a reasonable, common use case)
JXGlassPane?
Simplified component to make it easier to write GlassPanes?. Romain has some tips for this (like managing opacity, etc). It would be good to have several default JXGlassPane? implementations/properties as well, such as FadeIn?/FadeOut GlassPane? (or properties on JXGlassPane?), JXInfiniteProgress? (extends JXGlassPane?), etc.
Better nonvisual components
Winforms beats us up in a couple of places in the UI builder department. One is a better set of nonvisual controls. I'd like to see things like SwingWorker?, ImageIcon?, Image, DataSet?, Timer (or better yet, TimingController? from timingframework.dev.java.net), HTTP, Help, TrayIcon?, etc all be normal, useable java beans with proper property editors etc for use within the GUI builder |
| |
| META TOPICPARENT | name="SwingLabs" |
Home | Changes | Index | Search | Go <-- This creates the navigation links to : Home | Help | Index | etc. --> | | | Framework Stuff
Utilities | |
> > | Adapters
For the incubator: some standard adapters for known data sources (known format), such as Apache-format log files...not sure how we would package these, but would be pretty easy to code and nice to have lying around. Similar in a way to having parsers available for standard XML returned from RDBMSs. These adapters would then be used to read the source data into a DataSet? and DataTable?(s).
Common Validators
One-line factories for common data-entry validation: Validator v = StandardValidators?.get("us-zipcode");
- phone numbers (varies by country)
- US SSN
- US Zip
Common Data Sets
Distribute small datasets for common cases, like country codes, US zip codes, etc. that are approved by international committees--the main thing is finding the files and downloading them, then writing a bit of documentation. The format would either be text file or XML, and data should compress well enough that you could just distribute all of them in one JAR, ZIP, or GZip file.
- International country codes
- Airport codes
- US Zip Codes (or for other countries, where these are known and published).
|
|
> > |
| META TOPICPARENT | name="SwingLabs" |
Home | Changes | Index | Search | Go <-- This creates the navigation links to : Home | Help | Index | etc. -->
This page is used to capture exploratory and creative ideas for the future of SwingLabs. This is for jokes--all the ideas should be potentially realizable, just might be difficult to do
or lower priority at the moment.
UI Components
Framework Stuff
Utilities |
|