VisualEditor in Java - dynamically build sub-panel?
-
08-07-2019 - |
Question
I'm using the "Visual Editor" to "paint" my Swing GUI. Can I dynamically build the contents of a sub-panel with VE or do I have to use a predefined sub-class of JPanel (and build that with VE)?
Solution
You can dynamically build the contents of a sub panel - say based on a file or soemthing - the visual editor is not going to stop you.
Generally, VE is intelligent enough to see that you are dynamically build the panel and show the contents (say contents of a file in a JList)
Sometimes, VE fails to render the items because 'The control is too complex' - but this does not happen frequently.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow