Closed GoogleCodeExporter closed 9 years ago
Here is the source with MigPane
Original comment by bobbyo...@gmail.com
on 4 Dec 2013 at 7:03
Attachments:
This is not a bug, what you are seeing is MigLayout's default attempts to make
a UI look good byh adding white space. Try creating MigLayout like this:
MigPane root = new MigPane(new LC().insets("0px"));
Original comment by tbeer...@gmail.com
on 8 Dec 2013 at 9:05
I'm sorry, I've read you issue wrong.
Original comment by tbeer...@gmail.com
on 8 Dec 2013 at 9:08
Ok, interestingly enough MigPane seems to be doing it fine, below are some
debug prints:
MigPane.setPrefHeight 14.0
MigPane.setPrefHeight 35.0
Button[id=null, styleClass=button] FX2ComponentWrapper.setBound x=7,y=7 /
w=28,h=21 / resizable=true
MigPane.setPrefHeight 35.0
Button[id=null, styleClass=button] FX2ComponentWrapper.setBound x=7,y=7 /
w=102,h=21 / resizable=true
The first time setPrefHeight is called, it is set to just the insets (2x7px).
Later on the button is added (21px) and the prefheight is set to 35px. For some
reason the window does not pick that up. If I hardcode the prefHeight to 35, so
the first call also sets 35px, then the window sizes correctly.
Strange
Original comment by tbeer...@gmail.com
on 8 Dec 2013 at 12:24
So it's a problem concerning JavaFX that doesn't update the window size,
MigLayout, or both?
Original comment by bobbyo...@gmail.com
on 8 Dec 2013 at 4:34
I have found a workaround for this. Maybe it's not a "correct" way, but a
temporary solution would be to append
stage.sizeToScene()
after
stage.show()
Original comment by bobbyo...@gmail.com
on 9 Dec 2013 at 5:21
I found the problem, it was a matter of when MigPane recalculated its size and
when JavaFX wanted to know it.
Original comment by tbeer...@gmail.com
on 11 Dec 2013 at 7:10
Sweet! :-)
Will it be fixed in a near future release? And can we already have a patch to
apply to the current release or is it too early to ask?
Original comment by bobbyo...@gmail.com
on 11 Dec 2013 at 9:02
It is already fixed, in the 5.0-SNAPSHOT
Original comment by tbeer...@gmail.com
on 12 Dec 2013 at 7:18
Where can I find the 5.0 snapshot?
Original comment by bobbyo...@gmail.com
on 12 Dec 2013 at 11:21
Good work, Thanks for the fix. Fixed my issues
I downloaded snapshot 5.0 from:
https://oss.sonatype.org/content/repositories/snapshots/com/miglayout/
Original comment by had...@gmail.com
on 27 Jan 2014 at 12:23
I tried the version 5.0, but it's not working with Java7. I get the next
exception: Caused by: java.lang.UnsupportedClassVersionError:
org/tbee/javafx/scene/layout/fxml/MigPane : Unsupported major.minor version 52.0
I understand that version 52.0 means Java8, isn't?
Is there a solution for Java7?
Original comment by maq...@gmail.com
on 29 May 2014 at 12:46
5.0 is Java 8, MigPane 4 is for Java 7. I would suggest upgrading to J8, since
JavaFX also is a major upgrade.
Original comment by tbeer...@gmail.com
on 29 May 2014 at 4:00
Original issue reported on code.google.com by
bobbyo...@gmail.com
on 4 Dec 2013 at 7:01Attachments: