////////////////////////////////////////////////////////////////////////////// // // ConTEXT Highlighter for Trainsim Original highlighter by Pete Willard // Expanded by Yuri Sos // Modified by Paul DeVerter /////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////// // language name Language: MS Trainsim files ////////////////////////////////////////////////////////////////////////////// // put whatever you want here, short description, author name, email address.. Description: Trainsim Highlighter by Pete Willard and Yuri Sos // ////////////////////////////////////////////////////////////////////////////// // default file filter // note: if more than one extension is associated, eg: // C/C++ files (*.c,*.cpp,*.h,*.hpp)|*.c;*.cpp;*.h;*.hpp Filter: Trainsim files (*.eng, *.wag, *.cvf, *.sms, *.con, *.sd)| *.eng;*.wag;*.cvf;*.sms; *.con; *.sd ////////////////////////////////////////////////////////////////////////////// // help file which will be invoked when F1 is pressed HelpFile: ////////////////////////////////////////////////////////////////////////////// // language case sensitivity // 0 - no // 1 - yes CaseSensitive: 0 ////////////////////////////////////////////////////////////////////////////// // comment type: LineComment - comment to the EOL // BlockCommentBeg - block comment begin, it could be // multiline // BlockCommentEnd - block comment end // // if there is more than one definition of line/beg/end comment string, // you can separate it with spaces. // for example, for pascal it would be: // LineComment: // // BlockCommentBeg: (* { // BlockCommentEnd: *) } LineComment: BlockCommentBeg: "comment (" "skip (" BlockCommentEnd: ) ////////////////////////////////////////////////////////////////////////////// // identifier characters // note: characters shouldn't be delimited, except arrays // array of chars could be defined as from_char..to_char IdentifierBegChars: a..z A..Z _%@. IdentifierChars: a..z A..Z _ 0..9 ? ////////////////////////////////////////////////////////////////////////////// // numeric constants begin characters // note: characters shouldn't be delimited, except arrays // array of chars could be defined as from_char..to_char // number always starts with 0..9 except when NumConstBeg // defines other NumConstBegChars: 0..9 ////////////////////////////////////////////////////////////////////////////// // numeric constants characters // note: characters shouldn't be delimited, except arrays // array of chars could be defined as from_char..to_char // number always starts with 0..9 except when NumConstBeg // defines other NumConstChars: 0..9 abcdefhABCDEFH ////////////////////////////////////////////////////////////////////////////// // escape character EscapeChar: ////////////////////////////////////////////////////////////////////////////// // keyword table // note: delimited with spaces, lines could be wrapped // you may divide keywords into five groups which can be // highlighted differently // op codes KeyWords1: DerailRailHeight DerailRailForce DerailBufferForce wagonshape centreofgravity maxtilt mass Size InertiaTensor Coupling Buffers Adheasion Box AWSMonitor wheelradius MaxOilPressure DoesBrakeCutPower BrakeCutsPowerAtBrakeCylinderPressure Effects MaxPower MaxForce EngineControllers MaxDieselLevel MaxTemperature DieselUsedPerHourAtMaxPower DieselUsedPerHourAtIdle DieselSmokeEffectInitialMagnitude DieselSmokeEffectMaxMagnitude DieselSmokeEffectInitialSmokeRate DieselSmokeEffectMaxSmokeRate DieselEngineIdleRPM DieselEngineMaxRPM dieselEngineSpeedOfMaxTractiveEffort DieselEngineMaxRPMChangeRate MaxContinuousForce RunUpTimeToMaxForce HeadOut MaxVelocity MaxCurrent WheelRadius CabView NumWheels Description AirBrakesAirCompressorPowerRating AirBrakesMainMinResAirPressure AirBrakesMainMaxAirPressure AirBrakesMainResVolume AirBrakesAirCompressorWattage AirBrakesCompressorRestartPressure AirBrakesAirUsedPerPoundsOfBrakePipePressure AirBrakesIsCompressorElectricOrMechanical EngineBrakesControllerMinPressureReduction TrainBrakesControllerMinPressureReduction EngineBrakesControllerHasProportionalBrake EngineBrakesProportionalBrakeLag EngineBrakesControllerMaxApplicationRate TrainBrakesControllerMaxApplicationRate EngineBrakesControllerMaxReleaseRate TrainBrakesControllerMaxReleaseRate EngineBrakesControllerEmergencyApplicationRate TrainBrakesControllerEmergencyApplicationRate TrainBrakesControllerMaxPressureDropInNormalApplication EngineBrakesControllerMinSystemPressure TrainBrakesControllerMinSystemPressure EngineBrakesControllerMaxSystemPressure TrainBrakesControllerMaxSystemPressure EngineBrakesControllerEmergencyBrakeTimePenalty TrainBrakesControllerEmergencyBrakeTimePenalty EngineBrakesControllerFullServicePressureDrop TrainBrakesControllerFullServicePressureDrop DynamicBrakesMinUsableSpeed DynamicBrakesMaximumEffectiveSpeed DynamicBrakesMaximumForce DynamicBrakesResistorCurrentLimit DynamicBrakesCutInSpeed DynamicBrakesMaxAirBrakePressure DynamicBrakesFadingSpeed DynamicBrakesDelayTimeBeforeEngaging DynamicBrakesMaximumSpeedForFadeOut DynamicBrakesEffectAtMaximumFadeOut DynamicBrakesHigherSpeedCurveExponent DynamicBrakesLowerSpeedCurveExponent DynamicBrakesNumberOfControllerNotches DynamicBrakeHasAutoBailOff Name Sound EngineOperatingProcedures EngineVariables istenderrequired AirBrakesHasLowPressureTest BrakesEngineBrakeType BrakesTrainBrakeType BrakesEngineControllers EngineBrakesControllerDirectControlExponent AntiSlip BrakeEquipmentType BrakeSystemType MaxBrakeForce EmergencyBrakeResMaxPressure TripleValveRatio MaxReleaseRate MaxApplicationRate MaxAuxilaryChargingRate FreightAnim EmergencyResCapacity EmergencyResChargingRate BrakeCylinderPressureForMaxBrakeBrakeForce Friction IntakePoint lights Inside OverspeedMonitor VigilanceMonitor EmergencyStopMonitor PassengerCapacity MaxSandingTime DoesHornTriggerBell MaxHandbrakeForce NumberOfHandbrakeLeverSteps BoilerLength BoilerVolume BoilerEffectivity DraftingEffect BoilerResponsiveness CoalBurnage MaxBoilerOutput NumCylinders CylinderStroke CylinderDiameter CylinderVolume CylinderEffectivity InjectorSizes ExhaustLimit PrimingFactor BlastExponent MaxBoilerPressure MaxFireMass IdealFireMass MaxWaterMass SafetyValvesSteamUsage ShovelCoalMass SmokeCombustion MaxTenderCoalMass MaxTenderWaterMass InjectorTypes SuperHeater SteamSmokeUnitsPerPoundOfFuel SteamMaxSmokeUnitsReleaseRate MaxSteamHeatingPressure SafetyValvePressureDifference SteamGaugeGlassHeight BasicSteamUsage BasicCoalUsage InjectorLimits1 InjectorLimits2 CylinderCocksPowerEfficiency SteamCylinderCocksOperation VacuumBrakesSmallEjectorPowerRating VacuumBrakesMinBoilerPressureMaxVacuum VacuumBrakesSmallEjectorUsageRate VacuumBrakesLargeEjectorUsageRate VacuumBrakesHasVacuumPump SteamSmallestCutoff NumberOfDamperSteps RegulatorValveType RegulatorSecondValveStartPosition RegulatorPilotValveExponent RegulatorSecondValveExponent RegulatorPilotValveFullOpenning RegulatorMainValveInitialOpenning SteamBlowerEffectExponent SteamBlowerEfficiencyExponent SteamBlowerMaxSteamUsageRate SteamBlowerMaxProportionOfBlastEffect SteamSmokeUnitsPerPoundOfFuel BrakeDistributorFullServicePressure BrakeDistributorMaxAuxilaryResPressure BrakeDistributorEmergencyResPressure BrakeDistributorReleaseRate BrakeDistributorApplicationRate BrakeDistributorTrainPipeControlRatio BrakeDistributorNormalFullReleasePressure Thumbnail CabViewWindowFile CabViewWindow TrainPipeLeakRate CabViewType CabViewFile CabViewControls ScalabiltyGroup Activation Deactivation Stereo Streams EngineData Volume Serial NextWagonUID Durability KeyWords2: Chain Spring Automatic CouplingHasRigidConnection PantographToggle1 Stream Conditions Cycle FadeIn FadeOut States DieselSpecialEffects Centre Brake_Dynamic Brake_Train Brake_Engine Velocity Light MonitoringDeviceMonitorTimeLimit MonitoringDeviceAlarmTimeLimit MonitoringDevicePenaltyTimeLimit MonitoringDeviceCriticalLevel MonitoringDeviceResetLevel MonitoringDeviceAppliesFullBrake MonitoringDeviceAppliesEmergencyBrake MonitoringDeviceAppliesCutsPower MonitoringDeviceAppliesShutsDownEngine Sanding SteamSpecialEffects EmergencyStopResetToggle Wipers Horn AWS BellToggle DirControl Combined_Control BailOffButton Headlights Vigilance EmergencyStopToggle Regulator Cutoff Brake_Hand MonitoringDeviceTriggerOnTrackOverspeed MonitoringDeviceTriggerOnTrackOverspeedMargin MonitoringDeviceResetOnZeroSpeed MonitoringDeviceResetOnResetButton DampersBack DampersFront Shovel HeatingTap FireDoor Blower SmallEjectorOrCompressor Injector1Steam Injector2Steam Injector1Water Injector2Water CylinderCocks Whistle TriState MultiStateDisplay TwoState ExternalCam Distance PassengerCam CabCam UiD WagonData ESD_Detail_Level ESD_Software_DLev ESD_Alternative_Texture ESD_Bounding_Box KeyWords3: State Exhaust1 Exhaust2 FRONT_HLIGHT NONE NumNotches Damping Break r0 Stiffness Headlight Unit SafetyValvesFX THROTTLE_DISPLAY DrainpipeFX StackFX WhistleFX CylindersFX Control Service TimeOfDay Priority Triggers NumFrames MouseControl Orientation DirIncrease ScaleRange ScalePos Units NumPositions NumValues Graphic Accuracy AccuracySwitch LeadingZeros Justification PositiveColour NegativeColour DecreaseColour DigitalClock FrequencyCurve VolumeCurve KeyWords4: PassengerCabinFile PassengerCabinHeadPos RotationLimit StartDirection FRICTION_BRAKING Duration LightColour Transition Angle Azimuth Radius Angle TRACTION_BRAKING Notch Elevation Manual Twin_port SwitchVal Initial_Trigger NEEDLE SPEEDOMETER MAIN_RES LOAD_METER TWO_STATE BELL BRAKE_CYL EQ_RES BRAKE_PIPE TRAIN_BRAKE KILO_LBS DYNAMIC_BRAKE_DISPLAY WHEELSLIP ONOFF SPRUNG NOT_SPRUNG ENGINE_BRAKE SANDERS MULTI_STATE_DISPLAY PSI DYNAMIC_BRAKE AMPS EMERGENCY_BRAKE MILES_PER_HOUR PENALTY_APP TRI_STATE PANTO_DISPLAY OVERSPEED CLOCK DIGITAL_CLOCK SPEEDLIM_DISPLAY Variable_Trigger CurvePoints Granularity Dist_Travelled_Trigger KeyWords5: StartLoop PlayOneShot SelectionMethod ////////////////////////////////////////////////////////////////////////////// // string delimiter: StringBegChar - string begin char // StringEndChar - string end char // MultilineStrings - enables multiline strings, as perl // has it StringBegChar: " StringEndChar: " MultilineStrings: 0 ////////////////////////////////////////////////////////////////////////////// // use preprocessor: 0 - no // 1 - yes // note: if yes, '#' and statements after it will be // highlighted with Preprocessor defined colors UsePreprocessor: 0 ////////////////////////////////////////////////////////////////////////////// // highlight line: 0 - no // 1 - yes // note: if yes, current line will be highlighted CurrLineHighlighted: 0 ////////////////////////////////////////////////////////////////////////////// // colors // note: first value is foreground, second is background color // and third (optional) represents font attribute: // B - bold // I - italic // U - underline // S - strike out // attributes can be combined: eg. B or BI // as value, it could be used any standard windows color: // clBlack, clMaroon, clGreen, clOlive, clNavy, // clPurple, clTeal, clGray, clSilver, clRed, clLime, // clYellow, clBlue, clFuchsia, clAqua, clLtGray, // clDkGray, clWhite, clScrollBar, clBackground, // clActiveCaption, clInactiveCaption, clMenu, clWindow, // clWindowFrame, clMenuText, clWindowText, clCaptionText, // clActiveBorder, clInactiveBorder, clAppWorkSpace, // clHighlight, clHighlightText, clBtnFace, clBtnShadow, // clGrayText, clBtnText, clInactiveCaptionText, // clBtnHighlight, cl3DDkShadow, cl3DLight, clInfoText, // clInfoBk // as value, it could be used hex numeric constant too: // $BBGGRR - BB: blue, GG: green, RR: red, eg: $FF6A00 SpaceCol: clWindowText clWindow Keyword1Col: clNavy clWindow Keyword2Col: clPurple clWindow Keyword3Col: clGreen clWindow Keyword4Col: clBlue clWindow Keyword5Col: clTeal clWindow IdentifierCol: clWindowText clWindow CommentCol: clOlive clWindow NumberCol: clRed clWindow StringCol: clMaroon clWindow SymbolCol: clGray clWindow PreprocessorCol: clBlue clWindow SelectionCol: clYellow clNavy CurrentLineCol: clBlack clYellow MatchedBracesCol: clRed clYellow OverrideTxtFgColor: 0 BlockAutoindent: 0 BlockBegStr: BlockEndStr: Keyword5Col: $00C0C000 clWindow