特点:随着缩放窗口,窗口上的组件会上下移动(缩小向下,放大向上),在有限的空间内布局组件,如下图:
特性
FlowPane的常用方法
flow.setStyle("-fx-background-color: #548B54");//设置flow的背景颜色
flow.setPadding(new Insets(10));//设置(flow的)内边距
flow.setMargin(b1,new Insets(10));//设置某个组件的外边距
flow.setAlignment(Pos.CENTER);//设置对齐方式
flow.setHgap(10);//设置子组件的水平间距
flow.setVgap(10);//设置子组件的垂直间距
flow.setOrientation(Orientation.VERTICAL);//设置默认的布局方向为垂直