final Gantt gantt = Gantt.Builder()
.arrow(arrow)
.barCornerRadius(0) //The radius for defining the curve of a bar's corners.
.barHeight(15) //The height of the bars for tasks.
.criticalPathEnabled(true) //If true any arrows on the critical path will be styled differently.
.criticalPathStyle(LineStyle.New("red", 3)) //An object containing the style for any critical path arrows.
.defaultStartDate(DateValue.Date(LocalDate.now())) //If the start date cannot be computed from the values in the
DataTable, the start date will be set to this.
.innerGridDarkTrack(BarStyle.New("white")) //The fill color of the inner grid track.
.innerGridHorizLine(LineStyle.New("black", 3)) //Defines the style of the inner horizontal grid lines.
.innerGridTrack(BarStyle.New("gray")) //The fill color of the inner grid track.
.labelStyle(TextStyle.New("black", "Arial", 12)) //An object containing the styles for task labels.
.labelMaxWidth(20) //The maximum amount of space allowed for each task label.
.percentEnabled(true) //Fills the task bar based on the percentage completed for the task.
.shadowColor("blue") //Defines the color of the shadows under any task bar which has dependencies.
.shadowEnabled(true) //If set to true, draws a shadow under each task bar which has dependencies.
.shadowOffset(4) //Defines the offset, in pixels, of the shadows under any task bar which has dependencies.
.trackHeight(40) //The height of the tracks.
.build();
this.ganttChart.setGantt(gantt); |