ScrollPanel problems

Hey there @void256,

I’ve working on my cargo manifest. The basics work, but now I need to move everything into a scroll pane. Which is where the problems begin. First, I had a bit of trouble getting the scroll panel to a dynamic width and height. I managed to fix this by adding the internal panel through Java like so:

final int width = cargoManifestScrollPanel.getWidth() - 15;
final int height = cargoManifestScrollPanel.getHeight() - 15;
Element contentPanel = new PanelBuilder(“contentPanel”) {{
width(width + “px”);
height(height + “px”);
}}.build(nifty, screen, cargoManifestScrollPanel);

The scrollpanel itself I setup through XML like so (the { and } replaced the XML tags because for some reason you cannot insert XML into forum posts anymore):
{layer id=“cargomanifestLayer” childLayout=“center” visibleToMouse=“false” visible=“false”
{panel id=“cargomanifestPanel” height=“75%” widht=“75%” childLayout=“vertical”}
{control id=“cargoManifestScrollPanel” name=“scrollPanel” horizontal=“false” height="" width=“75%” style=“nifty-panel”}
{panel height=“20px” width=“75%” id=“buttons” childLayout=“horizontal”}
{panel height=“100%” width="
{control id=“cargomanifestCloseButton” name=“button” label=“close” visibleToMouse=“true”}
{interact onClick=“close()” /}
The resulting scrollpanel looks a bit off though:
Scrollpanel problems

As you can see in the red circles, there are two areas where things don’t line up right.

Any idea where this could be coming from?