title: How can I make my StackPane take up the full vertical height of the window?
body: <p>I'm trying to make the StackPane located in the <code>&lt;left&gt;</code> element of my main BorderPane take up the full vertical height of the window, even when its resized. How can I do this? This is what I've got so far:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  
  &lt;?import javafx.scene.control.ListView?&gt;
  &lt;?import javafx.scene.control.MenuBar?&gt;
  &lt;?import javafx.scene.control.ScrollPane?&gt;
  &lt;?import javafx.scene.control.ToolBar?&gt;
  &lt;?import javafx.scene.Group?&gt;
  &lt;?import javafx.scene.image.Image?&gt;
  &lt;?import javafx.scene.image.ImageView?&gt;
  &lt;?import javafx.scene.layout.*?&gt;
  
  &lt;VBox prefWidth="800.0" prefHeight="600.0" xmlns="http://javafx.com/javafx/8.0.112" xmlns:fx="http://javafx.com/fxml/1"&gt;
      &lt;VBox alignment="TOP_CENTER"&gt;
          &lt;ToolBar minHeight="50.0" prefHeight="50.0" prefWidth="800.0" stylesheets="@style.css" GridPane.rowIndex="1"&gt;
              &lt;ImageView fitHeight="35.0" fitWidth="200.0" pickOnBounds="true" preserveRatio="true"&gt;
                  &lt;Image url="@react-toolbar-logo.png"/&gt;
              &lt;/ImageView&gt;
          &lt;/ToolBar&gt;
          &lt;MenuBar fx:id="menuBar" prefHeight="0.0" prefWidth="0.0"/&gt;
      &lt;/VBox&gt;
  
      &lt;BorderPane xmlns:fx="http://javafx.com/fxml"&gt;
  
          &lt;left&gt;
              &lt;StackPane prefWidth="230"&gt;
                  &lt;ListView fx:id="listView"/&gt;
              &lt;/StackPane&gt;
          &lt;/left&gt;
          &lt;right&gt;
              &lt;StackPane&gt;
                  &lt;ScrollPane&gt;
                      &lt;Group fx:id="selectionGroup"&gt;
                          &lt;ImageView fx:id="mainImageView"/&gt;
                      &lt;/Group&gt;
                  &lt;/ScrollPane&gt;
              &lt;/StackPane&gt;
          &lt;/right&gt;
  
      &lt;/BorderPane&gt;
  &lt;/VBox&gt;
  </code></pre>