Class AbstractPaintManager
java.lang.Object
org.eclipse.nebula.widgets.ganttchart.AbstractPaintManager
- All Implemented Interfaces:
IPaintManager
- Direct Known Subclasses:
DefaultPaintManager
public abstract class AbstractPaintManager extends java.lang.Object implements IPaintManager
-
Constructor Summary
Constructors Constructor Description AbstractPaintManager()
-
Method Summary
Modifier and Type Method Description void
drawArrowHead(int x, int y, int face, org.eclipse.swt.graphics.GC gc)
Draws an arrow head.void
drawCheckpoint(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent event, org.eclipse.swt.graphics.GC gc, boolean threeDee, int dayWidth, int x, int y, org.eclipse.swt.graphics.Rectangle bounds)
Draws one checkpoint.void
drawDaysOnChart(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent event, org.eclipse.swt.graphics.GC gc, boolean threeDee, int x, int y, int eventWidth, int daysNumber, org.eclipse.swt.graphics.Rectangle bounds)
Draws the little plaque showing how many number of days an event spans over.void
drawEvent(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent event, org.eclipse.swt.graphics.GC gc, boolean isSelected, boolean threeDee, int dayWidth, int xStart, int y, int eventWidth, org.eclipse.swt.graphics.Rectangle bounds)
Draws one normal event.void
drawEventString(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent event, org.eclipse.swt.graphics.GC gc, java.lang.String toDraw, boolean threeDee, int x, int y, int eventWidth, org.eclipse.swt.graphics.Rectangle bounds)
Draws a string shown next to an event.void
drawImage(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent event, org.eclipse.swt.graphics.GC gc, org.eclipse.swt.graphics.Image image, boolean threeDee, int dayWidth, int xLoc, int yStart, org.eclipse.swt.graphics.Rectangle fullBounds)
Draws one checkpoint.void
drawLockedDateRangeMarker(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent ge, org.eclipse.swt.graphics.GC gc, boolean threeDee, int dayWidth, int y, int startLoc, int end, org.eclipse.swt.graphics.Rectangle bounds)
Draws the marker that shows what dates an event are locked down tovoid
drawPlannedDates(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent event, org.eclipse.swt.graphics.GC gc, boolean threeDee, int x, int y, int eventWidth, org.eclipse.swt.graphics.Rectangle bounds)
Draws the planned dates.void
drawScope(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent event, org.eclipse.swt.graphics.GC gc, boolean threeDee, int dayWidth, int x, int y, int eventWidth, org.eclipse.swt.graphics.Rectangle bounds)
Draws one scope.void
redrawStarting()
Notifies a redraw is starting from scratch, so you can zero out variables etc
-
Constructor Details
-
AbstractPaintManager
public AbstractPaintManager()
-
-
Method Details
-
redrawStarting
public void redrawStarting()Description copied from interface:IPaintManager
Notifies a redraw is starting from scratch, so you can zero out variables etc- Specified by:
redrawStarting
in interfaceIPaintManager
-
drawEvent
public void drawEvent(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent event, org.eclipse.swt.graphics.GC gc, boolean isSelected, boolean threeDee, int dayWidth, int xStart, int y, int eventWidth, org.eclipse.swt.graphics.Rectangle bounds)Description copied from interface:IPaintManager
Draws one normal event.- Specified by:
drawEvent
in interfaceIPaintManager
- Parameters:
ganttComposite
- GanttComposite parentsettings
- ISettingscolorManager
- IColorManagerevent
- GanttEventgc
- GCisSelected
- Whether the event is selected or notthreeDee
- Whether 3D events is on or offdayWidth
- Width of one dayxStart
- x locationy
- y locationeventWidth
- Width of eventbounds
- full bounds of draw area
-
drawCheckpoint
public void drawCheckpoint(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent event, org.eclipse.swt.graphics.GC gc, boolean threeDee, int dayWidth, int x, int y, org.eclipse.swt.graphics.Rectangle bounds)Description copied from interface:IPaintManager
Draws one checkpoint.- Specified by:
drawCheckpoint
in interfaceIPaintManager
- Parameters:
ganttComposite
- GanttComposite parentsettings
- ISettingscolorManager
- IColorManagerevent
- GanttEventgc
- GCthreeDee
- Whether 3D events is on or offdayWidth
- Width of one dayx
- x locationy
- y locationbounds
- full bounds of draw area
-
drawPlannedDates
public void drawPlannedDates(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent event, org.eclipse.swt.graphics.GC gc, boolean threeDee, int x, int y, int eventWidth, org.eclipse.swt.graphics.Rectangle bounds)Description copied from interface:IPaintManager
Draws the planned dates.- Specified by:
drawPlannedDates
in interfaceIPaintManager
- Parameters:
ganttComposite
- GanttComposite parentsettings
- ISettingscolorManager
- IColorManagerevent
- GanttEventgc
- GCthreeDee
- Whether 3D events is on or off.x
- x locationy
- y locationeventWidth
- Width of eventbounds
- full bounds of draw area
-
drawDaysOnChart
public void drawDaysOnChart(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent event, org.eclipse.swt.graphics.GC gc, boolean threeDee, int x, int y, int eventWidth, int daysNumber, org.eclipse.swt.graphics.Rectangle bounds)Description copied from interface:IPaintManager
Draws the little plaque showing how many number of days an event spans over.- Specified by:
drawDaysOnChart
in interfaceIPaintManager
- Parameters:
ganttComposite
- GanttComposite parentsettings
- ISettingscolorManager
- IColorManagerevent
- GanttEventgc
- GCthreeDee
- Whether 3D events is on or offx
- x locationy
- y locationeventWidth
- Width of eventdaysNumber
- Number of days the event encompassesbounds
- full bounds of draw area
-
drawEventString
public void drawEventString(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent event, org.eclipse.swt.graphics.GC gc, java.lang.String toDraw, boolean threeDee, int x, int y, int eventWidth, org.eclipse.swt.graphics.Rectangle bounds)Description copied from interface:IPaintManager
Draws a string shown next to an event.- Specified by:
drawEventString
in interfaceIPaintManager
- Parameters:
ganttComposite
- GanttComposite parentsettings
- ISettingscolorManager
- IColorManagerevent
- GanttEventgc
- GCtoDraw
- String to drawthreeDee
- Whether 3D events is on or offx
- x locationy
- y locationeventWidth
- Width of eventbounds
- full bounds of draw area
-
drawScope
public void drawScope(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent event, org.eclipse.swt.graphics.GC gc, boolean threeDee, int dayWidth, int x, int y, int eventWidth, org.eclipse.swt.graphics.Rectangle bounds)Description copied from interface:IPaintManager
Draws one scope.- Specified by:
drawScope
in interfaceIPaintManager
- Parameters:
ganttComposite
- GanttComposite parentsettings
- ISettingscolorManager
- IColorManagerevent
- GanttEventgc
- GCthreeDee
- Whether 3D events is on or offdayWidth
- Width of one dayx
- x locationy
- y locationeventWidth
- Width of eventbounds
- full bounds of draw area
-
drawImage
public void drawImage(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent event, org.eclipse.swt.graphics.GC gc, org.eclipse.swt.graphics.Image image, boolean threeDee, int dayWidth, int xLoc, int yStart, org.eclipse.swt.graphics.Rectangle fullBounds)Description copied from interface:IPaintManager
Draws one checkpoint.- Specified by:
drawImage
in interfaceIPaintManager
- Parameters:
ganttComposite
- GanttComposite parentsettings
- ISettingscolorManager
- IColorManagerevent
- GanttEventgc
- GCimage
- ImagethreeDee
- Whether 3D events is on or offdayWidth
- Width of one dayxLoc
- x locationyStart
- y locationfullBounds
- full bounds of draw area
-
drawArrowHead
public void drawArrowHead(int x, int y, int face, org.eclipse.swt.graphics.GC gc)Description copied from interface:IPaintManager
Draws an arrow head.- Specified by:
drawArrowHead
in interfaceIPaintManager
- Parameters:
x
- X locationy
- Y locationface
- What direction the arrows is in (one of SWT.LEFT, SWT.RIGHT, SWT.UP, SWT.DOWN)gc
- GC
-
drawLockedDateRangeMarker
public void drawLockedDateRangeMarker(GanttComposite ganttComposite, ISettings settings, IColorManager colorManager, GanttEvent ge, org.eclipse.swt.graphics.GC gc, boolean threeDee, int dayWidth, int y, int startLoc, int end, org.eclipse.swt.graphics.Rectangle bounds)Description copied from interface:IPaintManager
Draws the marker that shows what dates an event are locked down to- Specified by:
drawLockedDateRangeMarker
in interfaceIPaintManager
- Parameters:
ganttComposite
- GanttComposite parentsettings
- ISettingscolorManager
- IColorManagerge
- GanttEventgc
- GCthreeDee
- Whether 3D events is on or offdayWidth
- Width of one dayy
- y locationstartLoc
- where to draw the being marker. Will be -1 if there is no marker to draw.end
- where to draw the end marker. Will be -1 if there is no marker to draw.
-