Layout on Form Scout 8 [message #1799141] |
Fri, 30 November 2018 06:59  |
Eclipse User |
|
|
|
Hello,
i have a question about the layouting of a form.
This form is attached on a tablepage as a detailform.
What i need to have is, that all fields are in the left side of the form.
So like you see in the picture, that box 3 and box 4 should be positioned under box 2, so that all boxes are positioned on the left side and the right side is just plain empty. Is this possible?
At the moment my code (simplified for layout) looks like that:
@Order(1000)
@ClassId("e87975bc-28d4-4912-834a-aeca15209dae")
public class MainBox extends AbstractGroupBox {
@Override
protected int getConfiguredGridColumnCount() {
return 2;
}
public class GeneralBox extends AbstractGroupBox {
@Override
protected int getConfiguredGridW() {
return 1;
}
@Override
protected double getConfiguredGridWeightY() {
// do not allow the general box to grow or shrink vertically.
return 0;
}
public class Box1Box extends AbstractGroupBox {
@Override
protected int getConfiguredGridW() {
return 1;
}
public class Field1Field extends AbstractDateField { }
public class Field2Field extends AbstractSmartField<Long> { }
}
public class Box2Box extends AbstractGroupBox {
@Override
protected int getConfiguredGridW() {
return 1;
}
public class Field3Field extends AbstractBigDecimalField { }
public class Field4Field extends AbstractBigDecimalField { }
}
public class Box3Box extends AbstractGroupBox {
@Override
protected int getConfiguredGridW() {
return 1;
}
public class Button1 extends AbstractButton { }
public class Button2 extends AbstractButton { }
}
public class Box4Box extends AbstractGroupBox {
@Override
protected int getConfiguredGridW() {
return 1;
}
public class Field5Field extends AbstractStringField {}
)
public class Field6Field extends AbstractStringField {
@Override
protected int getConfiguredGridH() {
return 2;
}
}
}
}
public class OkButton extends AbstractOkButton {
@Override
protected int getConfiguredSystemType() {
return SYSTEM_TYPE_SAVE;
}
@Override
protected String getConfiguredLabel() {
return TEXTS.get("SaveEntry");
}
}
}
So i think it will be an easy fix, but i just dont get where to make the definitions needed. Tried with different column counts, weights, added empty boxes as buffers...nothing worked out.
Thank you.
[Updated on: Fri, 30 November 2018 06:59] by Moderator
|
|
|
|
Re: Layout on Form Scout 8 [message #1799252 is a reply to message #1799153] |
Mon, 03 December 2018 08:58  |
Eclipse User |
|
|
|
Thanks a lot!
The trick was the part i was missing before, already been there but i was wondering why the box was just ignored/removed.
Thx again for sharing your magic with us here :)
|
|
|
Powered by
FUDForum. Page generated in 0.03337 seconds