Use the Toolbar Button
The Gantt toolbar includes a Go to today button that scrolls the timeline to the current date with a single click. You can also access this action by right-clicking on the time scale header area and selecting the scroll-to-today option from the context menu.Scroll to Today Automatically on Load
To make the Gantt always center on today’s date when the page loads, add a script to the Gantt Config Script:- Open the Polarion page containing the Gantt widget
- Edit the widget properties
- Navigate to Advanced > Gantt Config Script
- Add one of the following scripts:
Configure the Today Marker
The today marker is a vertical line on the Gantt timeline indicating the current date. You can show or hide it using theshowTodayMarker widget parameter.
| Parameter | Default | Description |
|---|---|---|
showTodayMarker | true | Display a vertical line on today’s date |
nextedy.gantt.today.color | gray | Color of the today marker (administration property) |
- Edit the widget properties
- Navigate to Advanced > Show Today Marker
- Set it to No
Combine with Collapse on Load
A common configuration pattern combines scroll-to-today with starting the Gantt in a collapsed state. To start with all task groups collapsed, add the following to your Item Script:Verify Your Configuration
- Reload the Polarion page containing the Gantt widget
- You should now see the timeline automatically scrolled so that today’s date is in the visible area
- If
showTodayMarkeris enabled, a vertical line marks today’s date on the timeline - Click the Go to today toolbar button to confirm it scrolls to the same position
See Also
- Troubleshooting Today Marker Position for timezone-related marker issues
- Configure the Time Scale for adjusting the zoom level
- Create and Configure Markers for adding custom date markers
- Write Gantt Config Scripts for more configuration script examples
- Set the Gantt Time Range for controlling the overall visible date range
Sources
Sources
KB ArticlesSupport TicketsSource Code
prod-gantt-src/com.nextedy.polarion.gantt.client/src/js/components/Menu.jsprod-gantt-src/com.nextedy.polarion.gantt.client/src/js/commands.jsprod-gantt-src/com.nextedy.polarion.gantt.client/cypress/e2e/milestones/marker-colors.cy.tsprod-gantt-src/com.nextedy.polarion.gantt/src/com/nextedy/polarion/gantt/model/MarkerFactory.javaprod-gantt-src/com.nextedy.polarion.gantt/src/com/nextedy/polarion/gantt/widget/GanttWidgetConfig.java