Example #1
0
 private void setFillColor(int symbolType) {
   penColor = gRef.getColor();
   switch (symbolType) {
     case FTAConstants.SYMB_BASIC:
       gRef.setColor(Preferences.basicInitiatingEventColor);
       break;
     case FTAConstants.SYMB_UNDEV:
       gRef.setColor(Preferences.undevelopedEventColor);
       break;
     case FTAConstants.SYMB_EXTERN:
       gRef.setColor(Preferences.externalEventColor);
       break;
     case FTAConstants.SYMB_INTERMEDIATE:
       gRef.setColor(Preferences.intermediateEventColor);
       break;
     case FTAConstants.SYMB_AND:
       gRef.setColor(Preferences.andGateColor);
       break;
     case FTAConstants.SYMB_OR:
       gRef.setColor(Preferences.orGateColor);
       break;
     case FTAConstants.SYMB_PRIORITY_AND:
       gRef.setColor(Preferences.priorityAndGateColor);
       break;
     case FTAConstants.SYMB_EXCL_OR:
       gRef.setColor(Preferences.exclusiveOrGateColor);
       break;
     case FTAConstants.SYMB_INHIBIT:
       gRef.setColor(Preferences.inhibitGateColor);
       break;
     case FTAConstants.SYMB_CONDITION:
       gRef.setColor(Preferences.conditioningEventColor);
       break;
     case FTAConstants.SYMB_TRANS_IN:
       gRef.setColor(Preferences.transferInColor);
       break;
     case FTAConstants.SYMB_TRANS_OUT:
       gRef.setColor(Preferences.transferOutColor);
       break;
     default:
       gRef.setColor(Preferences.backgroundColor);
       break;
   }
 }
Example #2
0
 private void clearArc(int x, int y, int width, int height, int startAngle, int arcAngle) {
   penColor = gRef.getColor();
   gRef.setColor(Preferences.backgroundColor);
   gRef.fillArc(x, y, width, height, startAngle, arcAngle);
   gRef.setColor(penColor);
 }