tmf.ui: add support for transparency in timegraph
[deliverable/tracecompass.git] / tmf / org.eclipse.tracecompass.tmf.ui / src / org / eclipse / tracecompass / tmf / ui / widgets / timegraph / widgets / TimeGraphControl.java
index 09e0549c97e0559049bdcacf2b57a3221f060d70..ddf87f8a7556d76913de7798c664f9fc460b1989 100644 (file)
@@ -2465,7 +2465,11 @@ public class TimeGraphControl extends TimeGraphBaseControl
         // fill all rect area
         gc.setBackground(stateColor);
         if (visible) {
+            int prevAlpha = gc.getAlpha();
+            int alpha = ((int) styleMap.getOrDefault(ITimeEventStyleStrings.fillColor(), 0xff)) & 0xff;
+            gc.setAlpha(alpha);
             gc.fillRectangle(drawRect);
+            gc.setAlpha(prevAlpha);
         } else if (fBlendSubPixelEvents) {
             gc.setAlpha(128);
             gc.fillRectangle(drawRect);
This page took 0.025369 seconds and 5 git commands to generate.