The ListView is 300px wide. Flex directions is set.
I populate the list by code. Yet it only grows downwards and not in width. I want to have 3 items next to eachother per row. See the image below. (The darkgreen is the ListView width)
Settings ListView:

I fill the list like this
ListView buildingList = _ui.visualTree.Q<ListView>("buildinglist");
for (int z = 0; z < 100; z++)
{
Button button = new Button();
button.text = building.Value.buildingName;
button.AddToClassList("build-icon");
button.style.backgroundImage = new StyleBackground(building.Value.buildingIcon);
buildingList.Add(button);
}
How can i use flex so i can have 3 items per row?


