code: protected void handlePaintItems(final WTree tree, final XmlStringBuilder xml) {
  		TreeItemModel model = tree.getTreeModel();
  		int rows = model.getRowCount();
  
  		if (rows > 0) {
  			Set<String> selectedRows = new HashSet(tree.getSelectedRows());
  			Set<String> expandedRows = new HashSet(tree.getExpandedRows());
  			WTree.ExpandMode mode = tree.getExpandMode();
  			for (int i = 0; i < rows; i++) {
  				List<Integer> rowIndex = new ArrayList<>();
  				rowIndex.add(i);
  				paintItem(tree, mode, model, rowIndex, xml, selectedRows, expandedRows);
  			}
  		}
  
  	}
docs: Paint the tree items.
  
  @param tree the WTree to render
  @param xml the XML string builder