jellyfin-web/dashboard-ui/bower_components/libjass/libjass.js.map
2016-04-04 21:23:42 -04:00

1 line
447 KiB
Plaintext

{"version":3,"sources":["index.ts","parser/index.ts","parser/misc.ts","parser/parse.ts","parser/stream-parsers.ts","parser/streams.ts","parser/ttf.ts","parts/drawing.ts","parts/index.ts","renderers/clocks/auto.ts","renderers/clocks/base.ts","renderers/clocks/manual.ts","renderers/clocks/video.ts","renderers/default.ts","renderers/index.ts","renderers/null.ts","renderers/settings.ts","renderers/web/animation-collection.ts","renderers/web/drawing-styles.ts","renderers/web/font-size.ts","renderers/web/keyframe.ts","renderers/web/renderer.ts","renderers/web/span-styles.ts","settings.ts","types/ass.ts","types/attachment.ts","types/dialogue.ts","types/misc.ts","types/script-properties.ts","types/style.ts","utility/map.ts","utility/mixin.ts","utility/promise.ts","utility/set.ts","utility/ts-helpers.ts","webworker/channel.ts","webworker/commands.ts","webworker/index.ts","webworker/misc.ts"],"names":["settings","require","settings_1","exports","debugMode","verboseMode","set","set_1","Set","map","map_1","Map","promise","promise_1","Promise","DeferredPromise","webworker","parts","parser","renderers","ass_1","ASS","attachment_1","Attachment","AttachmentType","dialogue_1","Dialogue","script_properties_1","ScriptProperties","style_1","Style","misc_1","BorderStyle","Format","WrappingStyle","Object","defineProperties","get","setDebugMode","setVerboseMode","setImplementation","parse_1","parse","streams_1","BrowserReadableStream","StringStream","XhrStream","stream_parsers_1","StreamParser","SrtStreamParser","parseLineIntoProperty","line","parseLineIntoTypedTemplate","formatSpecifier","rules","input","rule","ParserRun","ParserRun.constructor","ParserRun.result","ParserRun.parse_dialogueParts","ParserRun.parse_enclosedTags","ParserRun.parse_newline","ParserRun.parse_hardspace","ParserRun.parse_text","ParserRun.parse_comment","ParserRun.parse_tag_a","ParserRun.parse_tag_alpha","ParserRun.parse_tag_an","ParserRun.parse_tag_b","ParserRun.parse_tag_be","ParserRun.parse_tag_blur","ParserRun.parse_tag_bord","ParserRun.parse_tag_c","ParserRun.parse_tag_clip","ParserRun.parse_tag_fad","ParserRun.parse_tag_fade","ParserRun.parse_tag_fax","ParserRun.parse_tag_fay","ParserRun.parse_tag_fn","ParserRun.parse_tag_fr","ParserRun.parse_tag_frx","ParserRun.parse_tag_fry","ParserRun.parse_tag_frz","ParserRun.parse_tag_fs","ParserRun.parse_tag_fsplus","ParserRun.parse_tag_fsminus","ParserRun.parse_tag_fscx","ParserRun.parse_tag_fscy","ParserRun.parse_tag_fsp","ParserRun.parse_tag_i","ParserRun.parse_tag_iclip","ParserRun.parse_tag_k","ParserRun.parse_tag_K","ParserRun.parse_tag_kf","ParserRun.parse_tag_ko","ParserRun.parse_tag_move","ParserRun.parse_tag_org","ParserRun.parse_tag_p","ParserRun.parse_tag_pbo","ParserRun.parse_tag_pos","ParserRun.parse_tag_q","ParserRun.parse_tag_r","ParserRun.parse_tag_s","ParserRun.parse_tag_shad","ParserRun.parse_tag_t","ParserRun.parse_tag_u","ParserRun.parse_tag_xbord","ParserRun.parse_tag_xshad","ParserRun.parse_tag_ybord","ParserRun.parse_tag_yshad","ParserRun.parse_tag_1a","ParserRun.parse_tag_1c","ParserRun.parse_tag_2a","ParserRun.parse_tag_2c","ParserRun.parse_tag_3a","ParserRun.parse_tag_3c","ParserRun.parse_tag_4a","ParserRun.parse_tag_4c","ParserRun.parse_drawingInstructions","ParserRun.parse_decimalInt32","ParserRun.parse_hexInt32","ParserRun.parse_decimalOrHexInt32","ParserRun.parse_decimal","ParserRun.parse_unsignedDecimal","ParserRun.parse_enableDisable","ParserRun.parse_color","ParserRun.parse_alpha","ParserRun.parse_colorWithAlpha","ParserRun.read","ParserRun._peek","ParserRun._haveMore","ParserRun._parse_tag_clip_or_iclip","makeTagParserFunction","tagName","tagConstructor","valueParser","required","self","this","current","ParseNode","parent","read","pop","valueNode","call","value","Alpha","prototype","parse_alpha","Blur","parse_decimal","GaussianBlur","Border","PrimaryColor","parse_color","SkewX","SkewY","RotateZ","RotateX","RotateY","FontSize","LetterSpacing","Italic","parse_enableDisable","DrawingMode","DrawingBaselineOffset","StrikeThrough","Shadow","Underline","BorderX","ShadowX","BorderY","ShadowY","PrimaryAlpha","SecondaryAlpha","SecondaryColor","OutlineAlpha","OutlineColor","ShadowAlpha","ShadowColor","_i","_a","keys","length","key","indexOf","substr","ParseNode.constructor","ParseNode.start","ParseNode.end","ParseNode.parent","ParseNode.children","ParseNode.value","ParseNode.pop","ParseNode._setEnd","commands_1","registerWorkerCommand","WorkerCommands","Parse","parameters","resolve","Section","StreamParser.constructor","StreamParser.minimalASS","StreamParser.ass","StreamParser.currentSection","StreamParser._onNextLine","SrtStreamParser.constructor","SrtStreamParser.ass","SrtStreamParser._onNextLine","uuencodedToBase64","str","StringStream.constructor","StringStream.nextLine","XhrStream.constructor","XhrStream.nextLine","XhrStream._onXhrProgress","XhrStream._onXhrLoad","XhrStream._onXhrError","XhrStream._tryResolveNextLine","BrowserReadableStream.constructor","BrowserReadableStream.nextLine","BrowserReadableStream._tryResolveNextLine","DataType","fieldDecorators","OffsetTable","TableRecord","NameTableHeader","NameRecord","getTtfNames","attachment","struct","clazz","field","type","MoveInstruction","MoveInstruction.constructor","MoveInstruction.x","MoveInstruction.y","LineInstruction","LineInstruction.constructor","LineInstruction.x","LineInstruction.y","CubicBezierCurveInstruction","CubicBezierCurveInstruction.constructor","CubicBezierCurveInstruction.x1","CubicBezierCurveInstruction.y1","CubicBezierCurveInstruction.x2","CubicBezierCurveInstruction.y2","CubicBezierCurveInstruction.x3","CubicBezierCurveInstruction.y3","drawing","Color","Color.constructor","Color.red","Color.green","Color.blue","Color.alpha","Color.withAlpha","Color.toString","Color.interpolate","Comment","Comment.constructor","Comment.value","Text","Text.constructor","Text.value","Text.toString","NewLine","Italic.constructor","Italic.value","Bold","Bold.constructor","Bold.value","Underline.constructor","Underline.value","StrikeThrough.constructor","StrikeThrough.value","Border.constructor","Border.value","BorderX.constructor","BorderX.value","BorderY.constructor","BorderY.value","Shadow.constructor","Shadow.value","ShadowX.constructor","ShadowX.value","ShadowY.constructor","ShadowY.value","Blur.constructor","Blur.value","GaussianBlur.constructor","GaussianBlur.value","FontName","FontName.constructor","FontName.value","FontSize.constructor","FontSize.value","FontSizePlus","FontSizePlus.constructor","FontSizePlus.value","FontSizeMinus","FontSizeMinus.constructor","FontSizeMinus.value","FontScaleX","FontScaleX.constructor","FontScaleX.value","FontScaleY","FontScaleY.constructor","FontScaleY.value","LetterSpacing.constructor","LetterSpacing.value","RotateX.constructor","RotateX.value","RotateY.constructor","RotateY.value","RotateZ.constructor","RotateZ.value","SkewX.constructor","SkewX.value","SkewY.constructor","SkewY.value","PrimaryColor.constructor","PrimaryColor.value","SecondaryColor.constructor","SecondaryColor.value","OutlineColor.constructor","OutlineColor.value","ShadowColor.constructor","ShadowColor.value","Alpha.constructor","Alpha.value","PrimaryAlpha.constructor","PrimaryAlpha.value","SecondaryAlpha.constructor","SecondaryAlpha.value","OutlineAlpha.constructor","OutlineAlpha.value","ShadowAlpha.constructor","ShadowAlpha.value","Alignment","Alignment.constructor","Alignment.value","ColorKaraoke","ColorKaraoke.constructor","ColorKaraoke.duration","SweepingColorKaraoke","SweepingColorKaraoke.constructor","SweepingColorKaraoke.duration","OutlineKaraoke","OutlineKaraoke.constructor","OutlineKaraoke.duration","WrappingStyle.constructor","WrappingStyle.value","Reset","Reset.constructor","Reset.value","Position","Position.constructor","Position.x","Position.y","Move","Move.constructor","Move.x1","Move.y1","Move.x2","Move.y2","Move.t1","Move.t2","RotationOrigin","RotationOrigin.constructor","RotationOrigin.x","RotationOrigin.y","Fade","Fade.constructor","Fade.start","Fade.end","ComplexFade","ComplexFade.constructor","ComplexFade.a1","ComplexFade.a2","ComplexFade.a3","ComplexFade.t1","ComplexFade.t2","ComplexFade.t3","ComplexFade.t4","Transform","Transform.constructor","Transform.start","Transform.end","Transform.accel","Transform.tags","RectangularClip","RectangularClip.constructor","RectangularClip.x1","RectangularClip.y1","RectangularClip.x2","RectangularClip.y2","RectangularClip.inside","VectorClip","VectorClip.constructor","VectorClip.scale","VectorClip.instructions","VectorClip.inside","DrawingMode.constructor","DrawingMode.scale","DrawingBaselineOffset.constructor","DrawingBaselineOffset.value","DrawingInstructions","DrawingInstructions.constructor","DrawingInstructions.instructions","addToString","ctor","ctorName","hasOwnProperty","propertyNames","getOwnPropertyNames","filter","property","toString","_this","name","join","Function","registerClassPrototype","_b","_c","manual_1","AutoClock","AutoClock.constructor","AutoClock.play","AutoClock.pause","AutoClock.seeking","AutoClock.currentTime","AutoClock.enabled","AutoClock.paused","AutoClock.rate","AutoClock.setRate","AutoClock.enable","AutoClock.disable","AutoClock.toggle","AutoClock.setEnabled","AutoClock.addEventListener","AutoClock._onTimerTick","AutoClock._startTicking","AutoClock._stopTicking","EventSource","EventSource.addEventListener","EventSource._dispatchEvent","ClockEvent","mixin_1","base_1","ManualClock","ManualClock.constructor","ManualClock.play","ManualClock.tick","ManualClock.seek","ManualClock.pause","ManualClock.stop","ManualClock.currentTime","ManualClock.enabled","ManualClock.paused","ManualClock.rate","ManualClock.setRate","ManualClock.enable","ManualClock.disable","ManualClock.toggle","ManualClock.setEnabled","mixin","auto_1","VideoClock","VideoClock.constructor","VideoClock.currentTime","VideoClock.enabled","VideoClock.paused","VideoClock.rate","VideoClock.enable","VideoClock.disable","VideoClock.toggle","VideoClock.setEnabled","VideoClock.addEventListener","video_1","renderer_1","DefaultRenderer","_super","DefaultRenderer.constructor","DefaultRenderer.resize","DefaultRenderer.resizeVideo","DefaultRenderer._ready","WebRenderer","default_1","null_1","NullRenderer","RendererSettings","settings_2","NullRenderer.constructor","NullRenderer.id","NullRenderer.ass","NullRenderer.clock","NullRenderer.settings","NullRenderer.enable","NullRenderer.disable","NullRenderer.toggle","NullRenderer.setEnabled","NullRenderer.enabled","NullRenderer._onClockPlay","NullRenderer._onClockTick","NullRenderer._onClockPause","NullRenderer._onClockStop","NullRenderer._onClockRateChange","RendererSettings.makeFontMapFromStyleElement","RendererSettings.from","isFontFaceRule","AnimationCollection","AnimationCollection.constructor","AnimationCollection.animationStyle","AnimationCollection.animationDelays","AnimationCollection.add","DrawingStyles","DrawingStyles.constructor","DrawingStyles.scale","DrawingStyles.baselineOffset","DrawingStyles.toSVG","prepareFontSizeElement","fontFamily","fontSize","fallbackFonts","fontSizeElement","lineHeightForFontSize","lineHeightForFontSizeSync","fontMetricsFromLineHeights","lowerLineHeight","upperLineHeight","calculateFontMetrics","fontSizeFromMetrics","lineHeight","factor","fontSizeForLineHeight","fontMetricsCache","Keyframe","Keyframe.constructor","Keyframe.time","Keyframe.properties","animation_collection_1","drawing_styles_1","font_size_1","keyframe_1","span_styles_1","ttf_1","fontSrcUrlRegex","WebRenderer.constructor","WebRenderer.libjassSubsWrapper","WebRenderer.resize","WebRenderer.preRender","WebRenderer.draw","WebRenderer._onClockPlay","WebRenderer._onClockTick","WebRenderer._onClockPause","WebRenderer._onClockStop","WebRenderer._onClockRateChange","WebRenderer._ready","WebRenderer._calculateFontMetricsAfterFetch","WebRenderer._removeSub","WebRenderer._removeAllSubs","SpanStyles","SpanStyles.constructor","SpanStyles.reset","SpanStyles.setStylesOnSpan","SpanStyles._setSvgOutlineOnSpan","SpanStyles._setTextShadowOutlineOnSpan","SpanStyles.makeNewLine","SpanStyles.italic","SpanStyles.bold","SpanStyles.underline","SpanStyles.strikeThrough","SpanStyles.outlineWidth","SpanStyles.outlineHeight","SpanStyles.shadowDepthX","SpanStyles.shadowDepthY","SpanStyles.blur","SpanStyles.gaussianBlur","SpanStyles.fontName","SpanStyles.fontSize","SpanStyles.fontScaleX","SpanStyles.fontScaleY","SpanStyles.letterSpacing","SpanStyles.rotationX","SpanStyles.rotationY","SpanStyles.rotationZ","SpanStyles.skewX","SpanStyles.skewY","SpanStyles.primaryColor","SpanStyles.secondaryColor","SpanStyles.outlineColor","SpanStyles.shadowColor","SpanStyles.primaryAlpha","SpanStyles.secondaryAlpha","SpanStyles.outlineAlpha","SpanStyles.shadowAlpha","misc_2","ASS.constructor","ASS.properties","ASS.styles","ASS.dialogues","ASS.attachments","ASS.stylesFormatSpecifier","ASS.dialoguesFormatSpecifier","ASS.addStyle","ASS.addEvent","ASS.addAttachment","ASS.fromString","ASS.fromStream","ASS.fromUrl","ASS.fromReadableStream","Attachment.constructor","Attachment.filename","Attachment.type","Attachment.contents","Dialogue.constructor","Dialogue.id","Dialogue.start","Dialogue.end","Dialogue.style","Dialogue.alignment","Dialogue.layer","Dialogue.parts","Dialogue.containsTransformTag","Dialogue.toString","Dialogue._parsePartsString","Dialogue._toTime","valueOrDefault","template","converter","validator","defaultValue","ScriptProperties.resolutionX","ScriptProperties.resolutionY","ScriptProperties.wrappingStyle","ScriptProperties.scaleBorderAndShadow","Style.constructor","Style.name","Style.italic","Style.bold","Style.underline","Style.strikeThrough","Style.fontName","Style.fontSize","Style.fontScaleX","Style.fontScaleY","Style.letterSpacing","Style.rotationZ","Style.primaryColor","Style.secondaryColor","Style.outlineColor","Style.shadowColor","Style.outlineThickness","Style.borderStyle","Style.shadowDepth","Style.alignment","Style.marginLeft","Style.marginRight","Style.marginVertical","global","SimpleMap","SimpleMap.constructor","SimpleMap.get","SimpleMap.has","SimpleMap.set","SimpleMap.delete","SimpleMap.clear","SimpleMap.forEach","SimpleMap.size","SimpleMap._keyToProperty","undefined","forEach","size","ex","mixins","enqueueJob","MutationObserver","WebkitMutationObserver","process","nextTick","callback","pending","currentlyPending","div","document","createElement","observer","processing","splice","classList","toggle","observe","attributes","push","setTimeout","SimplePromise","SimplePromise.constructor","SimplePromise.then","SimplePromise.catch","SimplePromise.resolve","SimplePromise.reject","SimplePromise.all","SimplePromise.race","SimplePromise._createResolvingFunctions","SimplePromise._resolveWithThenable","SimplePromise._fulfill","SimplePromise._reject","SimplePromise._enqueueFulfilledReactionJob","SimplePromise._enqueueRejectedReactionJob","SimplePromiseState","DeferredPromise.constructor","DeferredPromise.promise","first","promises","first_rec","previousRejections","any","lastly","body","SimpleSet","SimpleSet.constructor","SimpleSet.add","SimpleSet.clear","SimpleSet.has","SimpleSet.forEach","SimpleSet.size","SimpleSet._toProperty","__extends","derived","base","___extends","___extends.___","__decorate","decorators","target","___decorate","decorateClass","decorateField","proto","WorkerChannelImpl","WorkerChannelImpl.constructor","WorkerChannelImpl.request","WorkerChannelImpl.cancelRequest","WorkerChannelImpl._respond","WorkerChannelImpl._onMessage","Ping","channel_1","supported","Worker","_scriptNode","currentScript","createWorker","scriptPath","WorkerGlobalScope","workerCommands","classPrototypes","command","handler","getWorkerCommandHandler","serialize","obj","deserialize"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAoBA,IAAYA,WAAQC,QAAM;QAC1B,IAAAC,aAAAD,QAAuC;QAA9BE,QAAAC,YAAAF,WAAAE;QAAWD,QAAAE,cAAAH,WAAAG;QAEpB,IAAYC,MAAGL,QAAM;QACrB,IAAAM,QAAAN,QAAoB;QAAXE,QAAAK,MAAAD,MAAAC;QAET,IAAYC,MAAGR,QAAM;QACrB,IAAAS,QAAAT,QAAoB;QAAXE,QAAAQ,MAAAD,MAAAC;QAET,IAAYC,UAAOX,QAAM;QACzB,IAAAY,YAAAZ,QAAyC;QAAhCE,QAAAW,UAAAD,UAAAC;QAASX,QAAAY,kBAAAF,UAAAE;QAElB,IAAYC,YAASf,QAAM;QAClBE,QAAAa,YAASA;QAElB,IAAYC,QAAKhB,QAAM;QACdE,QAAAc,QAAKA;QAEd,IAAYC,SAAMjB,QAAM;QACfE,QAAAe,SAAMA;QAEf,IAAYC,YAASlB,QAAM;QAClBE,QAAAgB,YAASA;QAElB,IAAAC,QAAAnB,QAAoB;QAAXE,QAAAkB,MAAAD,MAAAC;QACT,IAAAC,eAAArB,QAA2C;QAAlCE,QAAAoB,aAAAD,aAAAC;QAAYpB,QAAAqB,iBAAAF,aAAAE;QACrB,IAAAC,aAAAxB,QAAyB;QAAhBE,QAAAuB,WAAAD,WAAAC;QACT,IAAAC,sBAAA1B,QAAiC;QAAxBE,QAAAyB,mBAAAD,oBAAAC;QACT,IAAAC,UAAA5B,QAA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AAA/oB,QAAAT,QAAoB;QAKpB,IAAMuvB,iBAAiB,IAAI9uB,MAAAC;QAE3B,IAAM8uB,kBAAkB,IAAI/uB,MAAAC;;;;;;;QAQ5B,SAAA2L,sBAAsCojB,SAAyBC;YAC9DrjB,eAAeA,IAAIA,SAASA;;QADbnM,QAAAmM,wBAAqBA;;;;;;;QAUrC,SAAAsjB,wBAAwCF;YACvCE,OAAOA,eAAeA,IAAIA;;QADXzvB,QAAAyvB,0BAAuBA;;;;;;QASvC,SAAAjV,uBAAuCtR;YACtCsR,UAAUA,YAAYA,gBAAgBA;YACtCA,gBAAgBA,IAAIA,UAAUA,WAAWA;;QAF1Bxa,QAAAwa,yBAAsBA;;;;;QAStC,SAAAkV,UAA0BC;YACzBD,OAAOA,KAAKA,UAAUA,KAAKA,iCAAwBA,KAAaA;gBAC/DA,IAAIA,SAASA,MAAMA,cAAcA,WAAWA;oBAC3CA,MAAMA,YAAYA,MAAMA;;gBAGzBA,OAAOA;;;QANO1vB,QAAA0vB,YAASA;;;;;QAczB,SAAAE,YAA4B1iB;YAC3B0iB,OAAOA,KAAKA,MAAMA,KAAKA,iCAAwBA,KAAaA;gBAC3DA,IAAIA,SAASA,MAAMA,cAAcA,WAAWA;oBAC3CA,IAAMA,gBAAgBA,OAAOA,OAAOA,gBAAgBA,IAAIA,MAAMA;oBAC9DA,KAAkBA,IAAAA,KAAAA,GAAAA,KAAAA,OAAOA,KAAKA,QAAzBA,KAAAA,GAAAA,QAAAA,MAAgCA;wBAAhCA,IAAMA,QAAGA,GAAAA;wBACbA,IAAIA,UAAQA,aAAaA;4BACxBA,cAAcA,SAAOA,MAAMA;;;oBAG7BA,QAAQA;;gBAGTA,OAAOA;;;QAZO5vB,QAAA4vB,cAAWA","file":"libjass.js","sourceRoot":"","sourcesContent":["/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as settings from \"./settings\";\nexport { debugMode, verboseMode } from \"./settings\";\n\nimport * as set from \"./utility/set\";\nexport { Set } from \"./utility/set\";\n\nimport * as map from \"./utility/map\";\nexport { Map } from \"./utility/map\";\n\nimport * as promise from \"./utility/promise\";\nexport { Promise, DeferredPromise } from \"./utility/promise\";\n\nimport * as webworker from \"./webworker\";\nexport { webworker };\n\nimport * as parts from \"./parts\";\nexport { parts };\n\nimport * as parser from \"./parser\";\nexport { parser };\n\nimport * as renderers from \"./renderers\";\nexport { renderers };\n\nexport { ASS } from \"./types/ass\";\nexport { Attachment, AttachmentType } from \"./types/attachment\";\nexport { Dialogue } from \"./types/dialogue\";\nexport { ScriptProperties } from \"./types/script-properties\";\nexport { Style } from \"./types/style\";\n\nexport { BorderStyle, Format, WrappingStyle } from \"./types/misc\";\n\ndeclare const exports: any;\n\nObject.defineProperties(exports, {\n\tdebugMode: {\n\t\tget: () => settings.debugMode,\n\t\tset: settings.setDebugMode,\n\t},\n\n\tverboseMode: {\n\t\tget: () => settings.verboseMode,\n\t\tset: settings.setVerboseMode,\n\t},\n\tSet: {\n\t\tget: () => set.Set,\n\t\tset: set.setImplementation,\n\t},\n\tMap: {\n\t\tget: () => map.Map,\n\t\tset: map.setImplementation,\n\t},\n\tPromise: {\n\t\tget: () => promise.Promise,\n\t\tset: promise.setImplementation,\n\t},\n});\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport { parse } from \"./parse\";\nexport { BrowserReadableStream, Stream, StringStream, XhrStream } from \"./streams\";\nexport { StreamParser, SrtStreamParser } from \"./stream-parsers\";\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Property, TypedTemplate } from \"../types/misc\";\n\nimport { Map } from \"../utility/map\";\n\n/**\n * Parses a line into a {@link ./types/misc.Property}.\n *\n * @param {string} line\n * @return {!Property}\n */\nexport function parseLineIntoProperty(line: string): Property {\n\tconst colonPos = line.indexOf(\":\");\n\tif (colonPos === -1) {\n\t\treturn null;\n\t}\n\n\tconst name = line.substr(0, colonPos);\n\tconst value = line.substr(colonPos + 1).replace(/^\\s+/, \"\");\n\n\treturn { name, value };\n}\n\n/**\n * Parses a line into a {@link ./types/misc.TypedTemplate} according to the given format specifier.\n *\n * @param {string} line\n * @param {!Array.<string>} formatSpecifier\n * @return {!TypedTemplate}\n */\nexport function parseLineIntoTypedTemplate(line: string, formatSpecifier: string[]): TypedTemplate {\n\tconst property = parseLineIntoProperty(line);\n\tif (property === null) {\n\t\treturn null;\n\t}\n\n\tconst value = property.value.split(\",\");\n\n\tif (value.length > formatSpecifier.length) {\n\t\tvalue[formatSpecifier.length - 1] = value.slice(formatSpecifier.length - 1).join(\",\");\n\t}\n\n\tconst template = new Map<string, string>();\n\tformatSpecifier.forEach((formatKey, index) => {\n\t\ttemplate.set(formatKey, value[index]);\n\t});\n\n\treturn { type: property.name, template };\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as parts from \"../parts\";\n\nimport { debugMode } from \"../settings\";\n\nimport { Map } from \"../utility/map\";\n\nconst rules = new Map<string, (parent: ParseNode) => ParseNode>();\n\n/**\n * Parses a given string with the specified rule.\n *\n * @param {string} input The string to be parsed.\n * @param {string} rule The rule to parse the string with\n * @return {*} The value returned depends on the rule used.\n */\nexport function parse(input: string, rule: string): any {\n\tconst run = new ParserRun(input, rule);\n\n\tif (run.result === null || run.result.end !== input.length) {\n\t\tif (debugMode) {\n\t\t\tconsole.error(\"Parse failed. %s %s %o\", rule, input, run.result);\n\t\t}\n\n\t\tthrow new Error(\"Parse failed.\");\n\t}\n\n\treturn run.result.value;\n}\n\n/**\n * This class represents a single run of the parser.\n *\n * @param {string} input\n * @param {string} rule\n */\nclass ParserRun {\n\tprivate _parseTree: ParseNode;\n\tprivate _result: ParseNode;\n\n\tconstructor(private _input: string, rule: string) {\n\t\tthis._parseTree = new ParseNode(null);\n\n\t\tthis._result = rules.get(rule).call(this, this._parseTree);\n\t}\n\n\t/**\n\t * @type {ParseNode}\n\t */\n\tget result(): ParseNode {\n\t\treturn this._result;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_dialogueParts(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tcurrent.value = [];\n\n\t\twhile (this._haveMore()) {\n\t\t\tconst enclosedTagsNode = this.parse_enclosedTags(current);\n\n\t\t\tif (enclosedTagsNode !== null) {\n\t\t\t\tcurrent.value.push(...enclosedTagsNode.value);\n\t\t\t}\n\n\t\t\telse {\n\t\t\t\tconst whiteSpaceOrTextNode = this.parse_newline(current) || this.parse_hardspace(current) || this.parse_text(current);\n\n\t\t\t\tif (whiteSpaceOrTextNode === null) {\n\t\t\t\t\tparent.pop();\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\n\t\t\t\tif (whiteSpaceOrTextNode.value instanceof parts.Text && current.value[current.value.length - 1] instanceof parts.Text) {\n\t\t\t\t\t// Merge consecutive text parts into one part\n\t\t\t\t\tconst previousTextPart = <parts.Text>current.value[current.value.length - 1];\n\t\t\t\t\tcurrent.value[current.value.length - 1] = new parts.Text(previousTextPart.value + (<parts.Text>whiteSpaceOrTextNode.value).value);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tcurrent.value.push(whiteSpaceOrTextNode.value);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tlet inDrawingMode = false;\n\n\t\tcurrent.value.forEach((part: parts.Part, i: number) => {\n\t\t\tif (part instanceof parts.DrawingMode) {\n\t\t\t\tinDrawingMode = part.scale !== 0;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.Text && inDrawingMode) {\n\t\t\t\tcurrent.value[i] = new parts.DrawingInstructions(<parts.drawing.Instruction[]>parse(part.value, \"drawingInstructions\"));\n\t\t\t}\n\t\t});\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_enclosedTags(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tcurrent.value = [];\n\n\t\tif (this.read(current, \"{\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tfor (let next = this._peek(); this._haveMore() && next !== \"}\"; next = this._peek()) {\n\t\t\tlet childNode: ParseNode = null;\n\n\t\t\tif (this.read(current, \"\\\\\") !== null) {\n\t\t\t\tchildNode =\n\t\t\t\t\tthis.parse_tag_alpha(current) ||\n\t\t\t\t\tthis.parse_tag_iclip(current) ||\n\t\t\t\t\tthis.parse_tag_xbord(current) ||\n\t\t\t\t\tthis.parse_tag_ybord(current) ||\n\t\t\t\t\tthis.parse_tag_xshad(current) ||\n\t\t\t\t\tthis.parse_tag_yshad(current) ||\n\n\t\t\t\t\tthis.parse_tag_blur(current) ||\n\t\t\t\t\tthis.parse_tag_bord(current) ||\n\t\t\t\t\tthis.parse_tag_clip(current) ||\n\t\t\t\t\tthis.parse_tag_fade(current) ||\n\t\t\t\t\tthis.parse_tag_fscx(current) ||\n\t\t\t\t\tthis.parse_tag_fscy(current) ||\n\t\t\t\t\tthis.parse_tag_move(current) ||\n\t\t\t\t\tthis.parse_tag_shad(current) ||\n\n\t\t\t\t\tthis.parse_tag_fad(current) ||\n\t\t\t\t\tthis.parse_tag_fax(current) ||\n\t\t\t\t\tthis.parse_tag_fay(current) ||\n\t\t\t\t\tthis.parse_tag_frx(current) ||\n\t\t\t\t\tthis.parse_tag_fry(current) ||\n\t\t\t\t\tthis.parse_tag_frz(current) ||\n\t\t\t\t\tthis.parse_tag_fsp(current) ||\n\t\t\t\t\tthis.parse_tag_fsplus(current) ||\n\t\t\t\t\tthis.parse_tag_fsminus(current) ||\n\t\t\t\t\tthis.parse_tag_org(current) ||\n\t\t\t\t\tthis.parse_tag_pbo(current) ||\n\t\t\t\t\tthis.parse_tag_pos(current) ||\n\n\t\t\t\t\tthis.parse_tag_an(current) ||\n\t\t\t\t\tthis.parse_tag_be(current) ||\n\t\t\t\t\tthis.parse_tag_fn(current) ||\n\t\t\t\t\tthis.parse_tag_fr(current) ||\n\t\t\t\t\tthis.parse_tag_fs(current) ||\n\t\t\t\t\tthis.parse_tag_kf(current) ||\n\t\t\t\t\tthis.parse_tag_ko(current) ||\n\t\t\t\t\tthis.parse_tag_1a(current) ||\n\t\t\t\t\tthis.parse_tag_1c(current) ||\n\t\t\t\t\tthis.parse_tag_2a(current) ||\n\t\t\t\t\tthis.parse_tag_2c(current) ||\n\t\t\t\t\tthis.parse_tag_3a(current) ||\n\t\t\t\t\tthis.parse_tag_3c(current) ||\n\t\t\t\t\tthis.parse_tag_4a(current) ||\n\t\t\t\t\tthis.parse_tag_4c(current) ||\n\n\t\t\t\t\tthis.parse_tag_a(current) ||\n\t\t\t\t\tthis.parse_tag_b(current) ||\n\t\t\t\t\tthis.parse_tag_c(current) ||\n\t\t\t\t\tthis.parse_tag_i(current) ||\n\t\t\t\t\tthis.parse_tag_k(current) ||\n\t\t\t\t\tthis.parse_tag_K(current) ||\n\t\t\t\t\tthis.parse_tag_p(current) ||\n\t\t\t\t\tthis.parse_tag_q(current) ||\n\t\t\t\t\tthis.parse_tag_r(current) ||\n\t\t\t\t\tthis.parse_tag_s(current) ||\n\t\t\t\t\tthis.parse_tag_t(current) ||\n\t\t\t\t\tthis.parse_tag_u(current);\n\n\t\t\t\tif (childNode === null) {\n\t\t\t\t\tcurrent.pop(); // Unread backslash\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (childNode === null) {\n\t\t\t\tchildNode = this.parse_comment(current);\n\t\t\t}\n\n\t\t\tif (childNode !== null) {\n\t\t\t\tif (childNode.value instanceof parts.Comment && current.value[current.value.length - 1] instanceof parts.Comment) {\n\t\t\t\t\t// Merge consecutive comment parts into one part\n\t\t\t\t\tcurrent.value[current.value.length - 1] =\n\t\t\t\t\t\tnew parts.Comment(\n\t\t\t\t\t\t\t(<parts.Comment>current.value[current.value.length - 1]).value +\n\t\t\t\t\t\t\t(<parts.Comment>childNode.value).value\n\t\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tcurrent.value.push(childNode.value);\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\tparent.pop();\n\t\t\t\treturn null;\n\t\t\t}\n\t\t}\n\n\t\tif (this.read(current, \"}\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_newline(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"\\\\N\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value = new parts.NewLine();\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_hardspace(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"\\\\h\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value = new parts.Text(\"\\u00A0\");\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_text(parent: ParseNode): ParseNode {\n\t\tconst value = this._peek();\n\n\t\tconst current = new ParseNode(parent);\n\t\tconst valueNode = new ParseNode(current, value);\n\n\t\tcurrent.value = new parts.Text(valueNode.value);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_comment(parent: ParseNode): ParseNode {\n\t\tconst value = this._peek();\n\n\t\tconst current = new ParseNode(parent);\n\t\tconst valueNode = new ParseNode(current, value);\n\n\t\tcurrent.value = new parts.Comment(valueNode.value);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_a(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"a\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tlet next = this._peek();\n\n\t\tswitch (next) {\n\t\t\tcase \"1\":\n\t\t\t\tconst next2 = this._peek(2);\n\n\t\t\t\tswitch (next2) {\n\t\t\t\t\tcase \"10\":\n\t\t\t\t\tcase \"11\":\n\t\t\t\t\t\tnext = next2;\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\tcase \"2\":\n\t\t\tcase \"3\":\n\t\t\tcase \"5\":\n\t\t\tcase \"6\":\n\t\t\tcase \"7\":\n\t\t\tcase \"9\":\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\tparent.pop();\n\t\t\t\treturn null;\n\t\t}\n\n\t\tconst valueNode = new ParseNode(current, next);\n\n\t\tlet value: number = null;\n\t\tswitch (valueNode.value) {\n\t\t\tcase \"1\":\n\t\t\t\tvalue = 1;\n\t\t\t\tbreak;\n\n\t\t\tcase \"2\":\n\t\t\t\tvalue = 2;\n\t\t\t\tbreak;\n\n\t\t\tcase \"3\":\n\t\t\t\tvalue = 3;\n\t\t\t\tbreak;\n\n\t\t\tcase \"5\":\n\t\t\t\tvalue = 7;\n\t\t\t\tbreak;\n\n\t\t\tcase \"6\":\n\t\t\t\tvalue = 8;\n\t\t\t\tbreak;\n\n\t\t\tcase \"7\":\n\t\t\t\tvalue = 9;\n\t\t\t\tbreak;\n\n\t\t\tcase \"9\":\n\t\t\t\tvalue = 4;\n\t\t\t\tbreak;\n\n\t\t\tcase \"10\":\n\t\t\t\tvalue = 5;\n\t\t\t\tbreak;\n\n\t\t\tcase \"11\":\n\t\t\t\tvalue = 6;\n\t\t\t\tbreak;\n\t\t}\n\n\t\tcurrent.value = new parts.Alignment(value);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_alpha(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_an(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"an\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst next = this._peek();\n\n\t\tif (next < \"1\" || next > \"9\") {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst valueNode = new ParseNode(current, next);\n\n\t\tcurrent.value = new parts.Alignment(parseInt(valueNode.value));\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_b(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"b\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tlet valueNode: ParseNode = null;\n\n\t\tlet next = this._peek();\n\n\t\tif (next >= \"1\" && next <= \"9\") {\n\t\t\tnext = this._peek(3);\n\t\t\tif (next.substr(1) === \"00\") {\n\t\t\t\tvalueNode = new ParseNode(current, next);\n\t\t\t\tvalueNode.value = parseInt(valueNode.value);\n\t\t\t}\n\t\t}\n\n\t\tif (valueNode === null) {\n\t\t\tvalueNode = this.parse_enableDisable(current);\n\t\t}\n\n\t\tif (valueNode !== null) {\n\t\t\tcurrent.value = new parts.Bold(valueNode.value);\n\t\t}\n\t\telse {\n\t\t\tcurrent.value = new parts.Bold(null);\n\t\t}\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_be(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_blur(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_bord(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_c(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_clip(parent: ParseNode): ParseNode {\n\t\treturn this._parse_tag_clip_or_iclip(\"clip\", parent);\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_fad(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"fad\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \"(\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst startNode = this.parse_decimal(current);\n\t\tif (startNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \",\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst endNode = this.parse_decimal(current);\n\t\tif (endNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \")\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value = new parts.Fade(startNode.value / 1000, endNode.value / 1000);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_fade(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"fade\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \"(\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst a1Node = this.parse_decimal(current);\n\t\tif (a1Node === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \",\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst a2Node = this.parse_decimal(current);\n\t\tif (a2Node === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \",\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst a3Node = this.parse_decimal(current);\n\t\tif (a3Node === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \",\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst t1Node = this.parse_decimal(current);\n\t\tif (t1Node === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \",\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst t2Node = this.parse_decimal(current);\n\t\tif (t2Node === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \",\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst t3Node = this.parse_decimal(current);\n\t\tif (t3Node === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \",\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst t4Node = this.parse_decimal(current);\n\t\tif (t4Node === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \")\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value =\n\t\t\tnew parts.ComplexFade(\n\t\t\t\t1 - a1Node.value / 255, 1 - a2Node.value / 255, 1 - a3Node.value / 255,\n\t\t\t\tt1Node.value / 1000, t2Node.value / 1000, t3Node.value / 1000, t4Node.value / 1000\n\t\t\t);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_fax(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_fay(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_fn(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"fn\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst valueNode = new ParseNode(current, \"\");\n\n\t\tfor (let next = this._peek(); this._haveMore() && next !== \"\\\\\" && next !== \"}\"; next = this._peek()) {\n\t\t\tvalueNode.value += next;\n\t\t}\n\n\t\tif (valueNode.value.length > 0) {\n\t\t\tcurrent.value = new parts.FontName(valueNode.value);\n\t\t}\n\t\telse {\n\t\t\tcurrent.value = new parts.FontName(null);\n\t\t}\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_fr(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_frx(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_fry(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_frz(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_fs(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_fsplus(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"fs+\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst valueNode = this.parse_decimal(current);\n\n\t\tif (valueNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value = new parts.FontSizePlus(valueNode.value);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_fsminus(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"fs-\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst valueNode = this.parse_decimal(current);\n\n\t\tif (valueNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value = new parts.FontSizeMinus(valueNode.value);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_fscx(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"fscx\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst valueNode = this.parse_decimal(current);\n\n\t\tif (valueNode !== null) {\n\t\t\tcurrent.value = new parts.FontScaleX(valueNode.value / 100);\n\t\t}\n\t\telse {\n\t\t\tcurrent.value = new parts.FontScaleX(null);\n\t\t}\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_fscy(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"fscy\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst valueNode = this.parse_decimal(current);\n\n\t\tif (valueNode !== null) {\n\t\t\tcurrent.value = new parts.FontScaleY(valueNode.value / 100);\n\t\t}\n\t\telse {\n\t\t\tcurrent.value = new parts.FontScaleY(null);\n\t\t}\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_fsp(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_i(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_iclip(parent: ParseNode): ParseNode {\n\t\treturn this._parse_tag_clip_or_iclip(\"iclip\", parent);\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_k(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"k\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst valueNode = this.parse_decimal(current);\n\n\t\tif (valueNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value = new parts.ColorKaraoke(valueNode.value / 100);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_K(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"K\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst valueNode = this.parse_decimal(current);\n\n\t\tif (valueNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value = new parts.SweepingColorKaraoke(valueNode.value / 100);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_kf(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"kf\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst valueNode = this.parse_decimal(current);\n\n\t\tif (valueNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value = new parts.SweepingColorKaraoke(valueNode.value / 100);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_ko(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"ko\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst valueNode = this.parse_decimal(current);\n\n\t\tif (valueNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value = new parts.OutlineKaraoke(valueNode.value / 100);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_move(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"move\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \"(\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst x1Node = this.parse_decimal(current);\n\t\tif (x1Node === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \",\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst y1Node = this.parse_decimal(current);\n\t\tif (y1Node === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \",\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst x2Node = this.parse_decimal(current);\n\t\tif (x2Node === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \",\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst y2Node = this.parse_decimal(current);\n\t\tif (y2Node === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tlet t1Node: ParseNode = null;\n\t\tlet t2Node: ParseNode = null;\n\n\t\tif (this.read(current, \",\") !== null) {\n\t\t\tt1Node = this.parse_decimal(current);\n\t\t\tif (t1Node === null) {\n\t\t\t\tparent.pop();\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\tif (this.read(current, \",\") === null) {\n\t\t\t\tparent.pop();\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\tt2Node = this.parse_decimal(current);\n\t\t\tif (t2Node === null) {\n\t\t\t\tparent.pop();\n\t\t\t\treturn null;\n\t\t\t}\n\t\t}\n\n\t\tif (this.read(current, \")\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value = new parts.Move(\n\t\t\tx1Node.value, y1Node.value, x2Node.value, y2Node.value,\n\t\t\t(t1Node !== null) ? (t1Node.value / 1000) : null, (t2Node !== null) ? (t2Node.value / 1000) : null\n\t\t);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_org(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"org\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \"(\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst xNode = this.parse_decimal(current);\n\t\tif (xNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \",\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst yNode = this.parse_decimal(current);\n\t\tif (yNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \")\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value = new parts.RotationOrigin(xNode.value, yNode.value);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_p(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_pbo(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_pos(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"pos\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \"(\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst xNode = this.parse_decimal(current);\n\t\tif (xNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \",\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst yNode = this.parse_decimal(current);\n\t\tif (yNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \")\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value = new parts.Position(xNode.value, yNode.value);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_q(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"q\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst next = this._peek();\n\n\t\tif (next < \"0\" || next > \"3\") {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst valueNode = new ParseNode(current, next);\n\n\t\tcurrent.value = new parts.WrappingStyle(parseInt(valueNode.value));\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_r(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"r\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst valueNode = new ParseNode(current, \"\");\n\n\t\tfor (let next = this._peek(); this._haveMore() && next !== \"\\\\\" && next !== \"}\"; next = this._peek()) {\n\t\t\tvalueNode.value += next;\n\t\t}\n\n\t\tif (valueNode.value.length > 0) {\n\t\t\tcurrent.value = new parts.Reset(valueNode.value);\n\t\t}\n\t\telse {\n\t\t\tcurrent.value = new parts.Reset(null);\n\t\t}\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_s(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_shad(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_t(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, \"t\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \"(\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tlet startNode: ParseNode = null;\n\t\tlet endNode: ParseNode = null;\n\t\tlet accelNode: ParseNode = null;\n\n\t\tconst firstNode = this.parse_decimal(current);\n\t\tif (firstNode !== null) {\n\t\t\tif (this.read(current, \",\") === null) {\n\t\t\t\tparent.pop();\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\tconst secondNode = this.parse_decimal(current);\n\t\t\tif (secondNode !== null) {\n\t\t\t\tstartNode = firstNode;\n\t\t\t\tendNode = secondNode;\n\n\t\t\t\tif (this.read(current, \",\") === null) {\n\t\t\t\t\tparent.pop();\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\n\t\t\t\tconst thirdNode = this.parse_decimal(current);\n\t\t\t\tif (thirdNode !== null) {\n\t\t\t\t\taccelNode = thirdNode;\n\n\t\t\t\t\tif (this.read(current, \",\") === null) {\n\t\t\t\t\t\tparent.pop();\n\t\t\t\t\t\treturn null;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\taccelNode = firstNode;\n\n\t\t\t\tif (this.read(current, \",\") === null) {\n\t\t\t\t\tparent.pop();\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tconst transformTags: parts.Part[] = [];\n\n\t\tfor (let next = this._peek(); this._haveMore() && next !== \")\" && next !== \"}\"; next = this._peek()) {\n\t\t\tlet childNode: ParseNode = null;\n\n\t\t\tif (this.read(current, \"\\\\\") !== null) {\n\t\t\t\tchildNode =\n\t\t\t\t\tthis.parse_tag_alpha(current) ||\n\t\t\t\t\tthis.parse_tag_iclip(current) ||\n\t\t\t\t\tthis.parse_tag_xbord(current) ||\n\t\t\t\t\tthis.parse_tag_ybord(current) ||\n\t\t\t\t\tthis.parse_tag_xshad(current) ||\n\t\t\t\t\tthis.parse_tag_yshad(current) ||\n\n\t\t\t\t\tthis.parse_tag_blur(current) ||\n\t\t\t\t\tthis.parse_tag_bord(current) ||\n\t\t\t\t\tthis.parse_tag_clip(current) ||\n\t\t\t\t\tthis.parse_tag_fscx(current) ||\n\t\t\t\t\tthis.parse_tag_fscy(current) ||\n\t\t\t\t\tthis.parse_tag_shad(current) ||\n\n\t\t\t\t\tthis.parse_tag_fax(current) ||\n\t\t\t\t\tthis.parse_tag_fay(current) ||\n\t\t\t\t\tthis.parse_tag_frx(current) ||\n\t\t\t\t\tthis.parse_tag_fry(current) ||\n\t\t\t\t\tthis.parse_tag_frz(current) ||\n\t\t\t\t\tthis.parse_tag_fsp(current) ||\n\t\t\t\t\tthis.parse_tag_fsplus(current) ||\n\t\t\t\t\tthis.parse_tag_fsminus(current) ||\n\n\t\t\t\t\tthis.parse_tag_be(current) ||\n\t\t\t\t\tthis.parse_tag_fr(current) ||\n\t\t\t\t\tthis.parse_tag_fs(current) ||\n\t\t\t\t\tthis.parse_tag_1a(current) ||\n\t\t\t\t\tthis.parse_tag_1c(current) ||\n\t\t\t\t\tthis.parse_tag_2a(current) ||\n\t\t\t\t\tthis.parse_tag_2c(current) ||\n\t\t\t\t\tthis.parse_tag_3a(current) ||\n\t\t\t\t\tthis.parse_tag_3c(current) ||\n\t\t\t\t\tthis.parse_tag_4a(current) ||\n\t\t\t\t\tthis.parse_tag_4c(current) ||\n\n\t\t\t\t\tthis.parse_tag_c(current);\n\n\t\t\t\tif (childNode === null) {\n\t\t\t\t\tcurrent.pop(); // Unread backslash\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (childNode === null) {\n\t\t\t\tchildNode = this.parse_comment(current);\n\t\t\t}\n\n\t\t\tif (childNode !== null) {\n\t\t\t\tif (childNode.value instanceof parts.Comment && transformTags[transformTags.length - 1] instanceof parts.Comment) {\n\t\t\t\t\t// Merge consecutive comment parts into one part\n\t\t\t\t\ttransformTags[transformTags.length - 1] =\n\t\t\t\t\t\tnew parts.Comment(\n\t\t\t\t\t\t\t(<parts.Comment>transformTags[transformTags.length - 1]).value +\n\t\t\t\t\t\t\t(<parts.Comment>childNode.value).value\n\t\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\ttransformTags.push(childNode.value);\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\tparent.pop();\n\t\t\t\treturn null;\n\t\t\t}\n\t\t}\n\n\t\tthis.read(current, \")\");\n\n\t\tcurrent.value =\n\t\t\tnew parts.Transform(\n\t\t\t\t(startNode !== null) ? (startNode.value / 1000) : null,\n\t\t\t\t(endNode !== null) ? (endNode.value / 1000) : null,\n\t\t\t\t(accelNode !== null) ? (accelNode.value / 1000) : null,\n\t\t\t\ttransformTags\n\t\t\t);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_u(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_xbord(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_xshad(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_ybord(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_yshad(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_1a(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_1c(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_2a(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_2c(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_3a(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_3c(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_4a(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_tag_4c(parent: ParseNode): ParseNode {\n\t\tthrow new Error(\"Method not implemented.\");\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_drawingInstructions(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tlet currentType: string = null;\n\t\tconst numberParts: ParseNode[] = [];\n\n\t\tcurrent.value = [];\n\n\t\twhile (this._haveMore()) {\n\t\t\twhile (this.read(current, \" \") !== null) { }\n\t\t\tif (!this._haveMore()) {\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tif (currentType !== null) {\n\t\t\t\tconst numberPart = this.parse_decimal(current);\n\t\t\t\tif (numberPart !== null) {\n\t\t\t\t\tnumberParts.push(numberPart);\n\n\t\t\t\t\tif (currentType === \"m\" && numberParts.length === 2) {\n\t\t\t\t\t\tcurrent.value.push(new parts.drawing.MoveInstruction(numberParts[0].value, numberParts[1].value));\n\t\t\t\t\t\tnumberParts.splice(0, numberParts.length);\n\t\t\t\t\t}\n\t\t\t\t\telse if (currentType === \"l\" && numberParts.length === 2) {\n\t\t\t\t\t\tcurrent.value.push(new parts.drawing.LineInstruction(numberParts[0].value, numberParts[1].value));\n\t\t\t\t\t\tnumberParts.splice(0, numberParts.length);\n\t\t\t\t\t}\n\t\t\t\t\telse if (currentType === \"b\" && numberParts.length === 6) {\n\t\t\t\t\t\tcurrent.value.push(new parts.drawing.CubicBezierCurveInstruction(\n\t\t\t\t\t\t\tnumberParts[0].value, numberParts[1].value,\n\t\t\t\t\t\t\tnumberParts[2].value, numberParts[3].value,\n\t\t\t\t\t\t\tnumberParts[4].value, numberParts[5].value));\n\t\t\t\t\t\tnumberParts.splice(0, numberParts.length);\n\t\t\t\t\t}\n\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tconst typePart = this.parse_text(current);\n\t\t\tif (typePart === null) {\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tconst newType = (<parts.Text>typePart.value).value;\n\t\t\tswitch (newType) {\n\t\t\t\tcase \"m\":\n\t\t\t\tcase \"l\":\n\t\t\t\tcase \"b\":\n\t\t\t\t\tcurrentType = newType;\n\t\t\t\t\tnumberParts.splice(0, numberParts.length);\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\twhile (this.read(current, \" \") !== null) { }\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_decimalInt32(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tconst isNegative = this.read(current, \"-\") !== null;\n\n\t\tconst numberNode = new ParseNode(current, \"\");\n\t\tfor (let next = this._peek(); this._haveMore() && next >= \"0\" && next <= \"9\"; next = this._peek()) {\n\t\t\tnumberNode.value += next;\n\t\t}\n\n\t\tif (numberNode.value.length === 0) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tlet value = parseInt(numberNode.value);\n\t\tif (value >= 0xFFFFFFFF) {\n\t\t\tvalue = 0xFFFFFFFF;\n\t\t}\n\t\telse if (isNegative) {\n\t\t\tvalue = -value;\n\t\t}\n\n\t\tcurrent.value = value;\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_hexInt32(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tconst isNegative = this.read(current, \"-\") !== null;\n\n\t\tconst numberNode = new ParseNode(current, \"\");\n\t\tfor (\n\t\t\tlet next = this._peek();\n\t\t\tthis._haveMore() && (\n\t\t\t\t(next >= \"0\" && next <= \"9\") ||\n\t\t\t\t(next >= \"a\" && next <= \"f\") ||\n\t\t\t\t(next >= \"A\" && next <= \"F\")\n\t\t\t);\n\t\t\tnext = this._peek()) {\n\n\t\t\tnumberNode.value += next;\n\t\t}\n\n\t\tif (numberNode.value.length === 0) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tlet value = parseInt(numberNode.value, 16);\n\t\tif (value >= 0xFFFFFFFF) {\n\t\t\tvalue = 0xFFFFFFFF;\n\t\t}\n\t\telse if (isNegative) {\n\t\t\tvalue = -value;\n\t\t}\n\n\t\tcurrent.value = value;\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_decimalOrHexInt32(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tconst valueNode =\n\t\t\t(this.read(current, \"&H\") !== null || this.read(current, \"&h\") !== null) ?\n\t\t\t\t this.parse_hexInt32(current) :\n\t\t\t\t this.parse_decimalInt32(current);\n\n\t\tif (valueNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value = valueNode.value;\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_decimal(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tconst negative = (this.read(current, \"-\") !== null);\n\n\t\tconst numericalPart = this.parse_unsignedDecimal(current);\n\n\t\tif (numericalPart === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tcurrent.value = numericalPart.value;\n\n\t\tif (negative) {\n\t\t\tcurrent.value = -current.value;\n\t\t}\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_unsignedDecimal(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tconst characteristicNode = new ParseNode(current, \"\");\n\n\t\tlet mantissaNode: ParseNode = null;\n\n\t\tfor (let next = this._peek(); this._haveMore() && next >= \"0\" && next <= \"9\"; next = this._peek()) {\n\t\t\tcharacteristicNode.value += next;\n\t\t}\n\n\t\tif (characteristicNode.value.length === 0) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \".\") !== null) {\n\t\t\tmantissaNode = new ParseNode(current, \"\");\n\n\t\t\tfor (let next = this._peek(); this._haveMore() && next >= \"0\" && next <= \"9\"; next = this._peek()) {\n\t\t\t\tmantissaNode.value += next;\n\t\t\t}\n\n\t\t\tif (mantissaNode.value.length === 0) {\n\t\t\t\tparent.pop();\n\t\t\t\treturn null;\n\t\t\t}\n\t\t}\n\n\t\tcurrent.value = parseFloat(characteristicNode.value + ((mantissaNode !== null) ? (\".\" + mantissaNode.value) : \"\"));\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_enableDisable(parent: ParseNode): ParseNode {\n\t\tconst next = this._peek();\n\n\t\tif (next === \"0\" || next === \"1\") {\n\t\t\tconst result = new ParseNode(parent, next);\n\t\t\tresult.value = (result.value === \"1\");\n\n\t\t\treturn result;\n\t\t}\n\n\t\treturn null;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_color(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\twhile (this.read(current, \"&\") !== null || this.read(current, \"H\") !== null) { }\n\n\t\tconst valueNode = this.parse_hexInt32(current);\n\t\tif (valueNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst value = valueNode.value;\n\n\t\tcurrent.value = new parts.Color(\n\t\t\tvalue & 0xFF,\n\t\t\t(value >> 8) & 0xFF,\n\t\t\t(value >> 16) & 0xFF\n\t\t);\n\n\t\twhile (this.read(current, \"&\") !== null || this.read(current, \"H\") !== null) { }\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_alpha(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\twhile (this.read(current, \"&\") !== null || this.read(current, \"H\") !== null) { }\n\n\t\tconst valueNode = this.parse_hexInt32(current);\n\t\tif (valueNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst value = valueNode.value;\n\n\t\tcurrent.value = 1 - (value & 0xFF) / 0xFF;\n\n\t\twhile (this.read(current, \"&\") !== null || this.read(current, \"H\") !== null) { }\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tparse_colorWithAlpha(parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tconst valueNode = this.parse_decimalOrHexInt32(current);\n\t\tif (valueNode === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst value = valueNode.value;\n\n\t\tcurrent.value = new parts.Color(\n\t\t\tvalue & 0xFF,\n\t\t\t(value >> 8) & 0xFF,\n\t\t\t(value >> 16) & 0xFF,\n\t\t\t1 - ((value >> 24) & 0xFF) / 0xFF\n\t\t);\n\n\t\treturn current;\n\t}\n\n\t/**\n\t * @param {!ParseNode} parent\n\t * @param {string} next\n\t * @return {ParseNode}\n\t */\n\tread(parent: ParseNode, next: string): ParseNode {\n\t\tif (this._peek(next.length) !== next) {\n\t\t\treturn null;\n\t\t}\n\n\t\treturn new ParseNode(parent, next);\n\t}\n\n\t/**\n\t * @param {number=1} count\n\t * @return {string}\n\t */\n\tprivate _peek(count: number = 1): string {\n\t\t// Fastpath for count === 1. http://jsperf.com/substr-vs-indexer\n\t\tif (count === 1) { return this._input[this._parseTree.end]; }\n\n\t\treturn this._input.substr(this._parseTree.end, count);\n\t}\n\n\t/**\n\t * @return {boolean}\n\t */\n\tprivate _haveMore(): boolean {\n\t\treturn this._parseTree.end < this._input.length;\n\t}\n\n\t/**\n\t * @param {string} tagName One of \"clip\" and \"iclip\"\n\t * @param {!ParseNode} parent\n\t * @return {ParseNode}\n\t */\n\tprivate _parse_tag_clip_or_iclip(tagName: string, parent: ParseNode): ParseNode {\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (this.read(current, tagName) === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tif (this.read(current, \"(\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tlet x1Node: ParseNode = null;\n\t\tlet x2Node: ParseNode = null;\n\t\tlet y1Node: ParseNode = null;\n\t\tlet y2Node: ParseNode = null;\n\t\tlet scaleNode: ParseNode = null;\n\t\tlet commandsNode: ParseNode = null;\n\n\t\tconst firstNode = this.parse_decimal(current);\n\n\t\tif (firstNode !== null) {\n\t\t\tif (this.read(current, \",\") === null) {\n\t\t\t\tparent.pop();\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\tconst secondNode = this.parse_decimal(current);\n\n\t\t\tif (secondNode !== null) {\n\t\t\t\tx1Node = firstNode;\n\t\t\t\ty1Node = secondNode;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tscaleNode = firstNode;\n\t\t\t}\n\t\t}\n\n\t\tif (x1Node !== null && y1Node !== null) {\n\t\t\tif (this.read(current, \",\") === null) {\n\t\t\t\tparent.pop();\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\tx2Node = this.parse_decimal(current);\n\n\t\t\tif (this.read(current, \",\") === null) {\n\t\t\t\tparent.pop();\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\ty2Node = this.parse_decimal(current);\n\n\t\t\tcurrent.value = new parts.RectangularClip(x1Node.value, y1Node.value, x2Node.value, y2Node.value, tagName === \"clip\");\n\t\t}\n\t\telse {\n\t\t\tcommandsNode = new ParseNode(current, \"\");\n\n\t\t\tfor (let next = this._peek(); this._haveMore() && next !== \")\" && next !== \"}\"; next = this._peek()) {\n\t\t\t\tcommandsNode.value += next;\n\t\t\t}\n\n\t\t\tcurrent.value = new parts.VectorClip((scaleNode !== null) ? scaleNode.value : 1, <parts.drawing.Instruction[]>parse(commandsNode.value, \"drawingInstructions\"), tagName === \"clip\");\n\t\t}\n\n\t\tif (this.read(current, \")\") === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\treturn current;\n\t}\n}\n\n/**\n * Constructs a simple tag parser function and sets it on the prototype of the {@link ./parser/parse.ParserRun} class.\n *\n * @param {string} tagName The name of the tag to generate the parser function for\n * @param {function(new: !libjass.parts.Part, *)} tagConstructor The type of tag to be returned by the generated parser function\n * @param {function(!ParseNode): ParseNode} valueParser The parser for the tag's value\n * @param {boolean} required Whether the tag's value is required or optional\n */\nfunction makeTagParserFunction(\n\ttagName: string,\n\ttagConstructor: { new (value: any): parts.Part },\n\tvalueParser: (current: ParseNode) => ParseNode,\n\trequired: boolean\n): void {\n\t(<any>ParserRun.prototype)[`parse_tag_${ tagName }`] = function (parent: ParseNode): ParseNode {\n\t\tconst self = <ParserRun>this;\n\t\tconst current = new ParseNode(parent);\n\n\t\tif (self.read(current, tagName) === null) {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\tconst valueNode = valueParser.call(self, current);\n\n\t\tif (valueNode !== null) {\n\t\t\tcurrent.value = new tagConstructor(valueNode.value);\n\t\t}\n\t\telse if (!required) {\n\t\t\tcurrent.value = new tagConstructor(null);\n\t\t}\n\t\telse {\n\t\t\tparent.pop();\n\t\t\treturn null;\n\t\t}\n\n\t\treturn current;\n\t};\n}\n\nmakeTagParserFunction(\"alpha\", parts.Alpha, ParserRun.prototype.parse_alpha, false);\nmakeTagParserFunction(\"be\", parts.Blur, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"blur\", parts.GaussianBlur, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"bord\", parts.Border, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"c\", parts.PrimaryColor, ParserRun.prototype.parse_color, false);\nmakeTagParserFunction(\"fax\", parts.SkewX, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"fay\", parts.SkewY, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"fr\", parts.RotateZ, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"frx\", parts.RotateX, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"fry\", parts.RotateY, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"frz\", parts.RotateZ, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"fs\", parts.FontSize, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"fsp\", parts.LetterSpacing, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"i\", parts.Italic, ParserRun.prototype.parse_enableDisable, false);\nmakeTagParserFunction(\"p\", parts.DrawingMode, ParserRun.prototype.parse_decimal, true);\nmakeTagParserFunction(\"pbo\", parts.DrawingBaselineOffset, ParserRun.prototype.parse_decimal, true);\nmakeTagParserFunction(\"s\", parts.StrikeThrough, ParserRun.prototype.parse_enableDisable, false);\nmakeTagParserFunction(\"shad\", parts.Shadow, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"u\", parts.Underline, ParserRun.prototype.parse_enableDisable, false);\nmakeTagParserFunction(\"xbord\", parts.BorderX, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"xshad\", parts.ShadowX, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"ybord\", parts.BorderY, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"yshad\", parts.ShadowY, ParserRun.prototype.parse_decimal, false);\nmakeTagParserFunction(\"1a\", parts.PrimaryAlpha, ParserRun.prototype.parse_alpha, false);\nmakeTagParserFunction(\"1c\", parts.PrimaryColor, ParserRun.prototype.parse_color, false);\nmakeTagParserFunction(\"2a\", parts.SecondaryAlpha, ParserRun.prototype.parse_alpha, false);\nmakeTagParserFunction(\"2c\", parts.SecondaryColor, ParserRun.prototype.parse_color, false);\nmakeTagParserFunction(\"3a\", parts.OutlineAlpha, ParserRun.prototype.parse_alpha, false);\nmakeTagParserFunction(\"3c\", parts.OutlineColor, ParserRun.prototype.parse_color, false);\nmakeTagParserFunction(\"4a\", parts.ShadowAlpha, ParserRun.prototype.parse_alpha, false);\nmakeTagParserFunction(\"4c\", parts.ShadowColor, ParserRun.prototype.parse_color, false);\n\nfor (const key of Object.keys(ParserRun.prototype)) {\n\tif (key.indexOf(\"parse_\") === 0 && typeof (<any>ParserRun.prototype)[key] === \"function\") {\n\t\trules.set(key.substr(\"parse_\".length), (<any>ParserRun.prototype)[key]);\n\t}\n}\n\n/**\n * This class represents a single parse node. It has a start and end position, and an optional value object.\n *\n * @param {ParseNode} parent The parent of this parse node.\n * @param {*=null} value If provided, it is assigned as the value of the node.\n */\nclass ParseNode {\n\tprivate _children: ParseNode[] = [];\n\n\tprivate _start: number;\n\tprivate _end: number;\n\tprivate _value: any;\n\n\tconstructor(private _parent: ParseNode, value: any = null) {\n\t\tif (_parent !== null) {\n\t\t\t_parent.children.push(this);\n\t\t}\n\n\t\tthis._start = ((_parent !== null) ? _parent.end : 0);\n\t\tthis._end = this._start;\n\n\t\tthis.value = value;\n\t}\n\n\t/**\n\t * The start position of this parse node.\n\t *\n\t * @type {number}\n\t */\n\tget start(): number {\n\t\treturn this._start;\n\t}\n\n\t/**\n\t * The end position of this parse node.\n\t *\n\t * @type {number}\n\t */\n\tget end(): number {\n\t\treturn this._end;\n\t}\n\n\t/**\n\t * @type {ParseNode}\n\t */\n\tget parent(): ParseNode {\n\t\treturn this._parent;\n\t}\n\n\t/**\n\t * @type {!Array.<!ParseNode>}\n\t */\n\tget children(): ParseNode[] {\n\t\treturn this._children;\n\t}\n\n\t/**\n\t * An optional object associated with this parse node.\n\t *\n\t * @type {*}\n\t */\n\tget value(): any {\n\t\treturn this._value;\n\t}\n\n\t/**\n\t * An optional object associated with this parse node.\n\t *\n\t * If the value is a string, then the end property is updated to be the length of the string.\n\t *\n\t * @type {*}\n\t */\n\tset value(newValue: any) {\n\t\tthis._value = newValue;\n\n\t\tif (this._value !== null && this._value.constructor === String && this._children.length === 0) {\n\t\t\tthis._setEnd(this._start + this._value.length);\n\t\t}\n\t}\n\n\t/**\n\t * Removes the last child of this node and updates the end position to be end position of the new last child.\n\t */\n\tpop(): void {\n\t\tthis._children.splice(this._children.length - 1, 1);\n\n\t\tif (this._children.length > 0) {\n\t\t\tthis._setEnd(this._children[this._children.length - 1].end);\n\t\t}\n\t\telse {\n\t\t\tthis._setEnd(this.start);\n\t\t}\n\t}\n\n\t/**\n\t * Updates the end property of this node and its parent recursively to the root node.\n\t *\n\t * @param {number} newEnd\n\t */\n\tprivate _setEnd(newEnd: number): void {\n\t\tthis._end = newEnd;\n\n\t\tif (this._parent !== null && this._parent.end !== this._end) {\n\t\t\tthis._parent._setEnd(this._end);\n\t\t}\n\t}\n}\n\nimport { Promise } from \"../utility/promise\";\n\nimport { WorkerCommands } from \"../webworker/commands\";\nimport { registerWorkerCommand } from \"../webworker/misc\";\n\nregisterWorkerCommand(WorkerCommands.Parse, parameters => new Promise(resolve => {\n\tresolve(parse(parameters.input, parameters.rule));\n}));\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { debugMode } from \"../settings\";\n\nimport { ASS } from \"../types/ass\";\nimport { Style } from \"../types/style\";\nimport { Dialogue } from \"../types/dialogue\";\nimport { Attachment, AttachmentType } from \"../types/attachment\";\nimport { Property, TypedTemplate } from \"../types/misc\";\n\nimport { Map } from \"../utility/map\";\n\nimport { Promise, DeferredPromise } from \"../utility/promise\";\n\nimport { parseLineIntoProperty } from \"./misc\";\nimport { Stream } from \"./streams\";\n\nenum Section {\n\tScriptInfo,\n\tStyles,\n\tEvents,\n\tFonts,\n\tGraphics,\n\tOther,\n\tEOF,\n}\n\n/**\n * A parser that parses an {@link libjass.ASS} object from a {@link libjass.parser.Stream}.\n *\n * @param {!libjass.parser.Stream} stream The {@link libjass.parser.Stream} to parse\n */\nexport class StreamParser {\n\tprivate _ass: ASS = new ASS();\n\tprivate _minimalDeferred: DeferredPromise<ASS> = new DeferredPromise<ASS>();\n\tprivate _deferred: DeferredPromise<ASS> = new DeferredPromise<ASS>();\n\n\tprivate _shouldSwallowBom: boolean = true;\n\tprivate _currentSection: Section = Section.ScriptInfo;\n\tprivate _currentAttachment: Attachment = null;\n\n\tconstructor(private _stream: Stream) {\n\t\tthis._stream.nextLine().then(line => this._onNextLine(line), reason => {\n\t\t\tthis._minimalDeferred.reject(reason);\n\t\t\tthis._deferred.reject(reason);\n\t\t});\n\t}\n\n\t/**\n\t * @type {!Promise.<!libjass.ASS>} A promise that will be resolved when the script properties of the ASS script have been parsed from the stream. Styles and events have not necessarily been\n\t * parsed at the point this promise becomes resolved.\n\t */\n\tget minimalASS(): Promise<ASS> {\n\t\treturn this._minimalDeferred.promise;\n\t}\n\n\t/**\n\t * @type {!Promise.<!libjass.ASS>} A promise that will be resolved when the entire stream has been parsed.\n\t */\n\tget ass(): Promise<ASS> {\n\t\treturn this._deferred.promise;\n\t}\n\n\t/**\n\t * @type {number}\n\t */\n\tprivate get currentSection(): Section {\n\t\treturn this._currentSection;\n\t}\n\n\t/**\n\t * @type {number}\n\t */\n\tprivate set currentSection(value: Section) {\n\t\tif (this._currentAttachment !== null) {\n\t\t\tthis._ass.addAttachment(this._currentAttachment);\n\t\t\tthis._currentAttachment = null;\n\t\t}\n\n\t\tif (this._currentSection === Section.ScriptInfo && value !== Section.ScriptInfo) {\n\t\t\t// Exiting script info section\n\t\t\tthis._minimalDeferred.resolve(this._ass);\n\t\t}\n\n\t\tif (value === Section.EOF) {\n\t\t\tconst scriptProperties = this._ass.properties;\n\t\t\tif (scriptProperties.resolutionX === undefined || scriptProperties.resolutionY === undefined) {\n\t\t\t\t// Malformed script.\n\t\t\t\tthis._minimalDeferred.reject(\"Malformed ASS script.\");\n\t\t\t\tthis._deferred.reject(\"Malformed ASS script.\");\n\t\t\t}\n\t\t\telse {\n\t\t\t\tthis._minimalDeferred.resolve(this._ass);\n\t\t\t\tthis._deferred.resolve(this._ass);\n\t\t\t}\n\t\t}\n\n\t\tthis._currentSection = value;\n\t}\n\n\t/**\n\t * @param {string} line\n\t */\n\tprivate _onNextLine(line: string): void {\n\t\tif (line === null) {\n\t\t\tthis.currentSection = Section.EOF;\n\t\t\treturn;\n\t\t}\n\n\t\tif (line[line.length - 1] === \"\\r\") {\n\t\t\tline = line.substr(0, line.length - 1);\n\t\t}\n\n\t\tif (line.charCodeAt(0) === 0xfeff && this._shouldSwallowBom) {\n\t\t\tline = line.substr(1);\n\t\t}\n\n\t\tthis._shouldSwallowBom = false;\n\n\t\tif (line === \"\") {\n\t\t\t// Ignore empty lines.\n\t\t}\n\n\t\telse if (line[0] === \";\" && this._currentAttachment === null) {\n\t\t\t// Lines starting with ; are comments, unless reading an attachment.\n\t\t}\n\n\t\telse if (line === \"[Script Info]\") {\n\t\t\tthis.currentSection = Section.ScriptInfo;\n\t\t}\n\t\telse if (line === \"[V4+ Styles]\" || line === \"[V4 Styles]\") {\n\t\t\tthis.currentSection = Section.Styles;\n\t\t}\n\t\telse if (line === \"[Events]\") {\n\t\t\tthis.currentSection = Section.Events;\n\t\t}\n\t\telse if (line === \"[Fonts]\") {\n\t\t\tthis.currentSection = Section.Fonts;\n\t\t}\n\t\telse if (line === \"[Graphics]\") {\n\t\t\tthis.currentSection = Section.Graphics;\n\t\t}\n\t\telse {\n\t\t\tif (this._currentAttachment === null && line[0] === \"[\" && line[line.length - 1] === \"]\") {\n\t\t\t\t/* This looks like the start of a new section. The section name is unrecognized if it is.\n\t\t\t\t * Since there's no current attachment being parsed it's definitely the start of a new section.\n\t\t\t\t * If an attachment is being parsed, this might be part of the attachment.\n\t\t\t\t */\n\t\t\t\tthis.currentSection = Section.Other;\n\t\t\t}\n\n\t\t\tswitch (this.currentSection) {\n\t\t\t\tcase Section.ScriptInfo:\n\t\t\t\t\tconst property = parseLineIntoProperty(line);\n\t\t\t\t\tif (property !== null) {\n\t\t\t\t\t\tswitch (property.name) {\n\t\t\t\t\t\t\tcase \"PlayResX\":\n\t\t\t\t\t\t\t\tthis._ass.properties.resolutionX = parseInt(property.value);\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase \"PlayResY\":\n\t\t\t\t\t\t\t\tthis._ass.properties.resolutionY = parseInt(property.value);\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase \"WrapStyle\":\n\t\t\t\t\t\t\t\tthis._ass.properties.wrappingStyle = parseInt(property.value);\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase \"ScaledBorderAndShadow\":\n\t\t\t\t\t\t\t\tthis._ass.properties.scaleBorderAndShadow = (property.value === \"yes\");\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase Section.Styles:\n\t\t\t\t\tif (this._ass.stylesFormatSpecifier === null) {\n\t\t\t\t\t\tconst property = parseLineIntoProperty(line);\n\t\t\t\t\t\tif (property !== null && property.name === \"Format\") {\n\t\t\t\t\t\t\tthis._ass.stylesFormatSpecifier = property.value.split(\",\").map(str => str.trim());\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t// Ignore any non-format lines\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tthis._ass.addStyle(line);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcatch (ex) {\n\t\t\t\t\t\t\tif (debugMode) {\n\t\t\t\t\t\t\t\tconsole.error(`Could not parse style from line ${ line } - ${ ex.stack || ex }`);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase Section.Events:\n\t\t\t\t\tif (this._ass.dialoguesFormatSpecifier === null) {\n\t\t\t\t\t\tconst property = parseLineIntoProperty(line);\n\t\t\t\t\t\tif (property !== null && property.name === \"Format\") {\n\t\t\t\t\t\t\tthis._ass.dialoguesFormatSpecifier = property.value.split(\",\").map(str => str.trim());\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t// Ignore any non-format lines\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tthis._ass.addEvent(line);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcatch (ex) {\n\t\t\t\t\t\t\tif (debugMode) {\n\t\t\t\t\t\t\t\tconsole.error(`Could not parse event from line ${ line } - ${ ex.stack || ex }`);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase Section.Fonts:\n\t\t\t\tcase Section.Graphics:\n\t\t\t\t\tconst startOfNewAttachmentRegex = (this.currentSection === Section.Fonts) ? /^fontname:(.+)/ : /^filename:(.+)/;\n\t\t\t\t\tconst startOfNewAttachment = startOfNewAttachmentRegex.exec(line);\n\n\t\t\t\t\tif (startOfNewAttachment !== null) {\n\t\t\t\t\t\t// Start of new attachment\n\n\t\t\t\t\t\tif (this._currentAttachment !== null) {\n\t\t\t\t\t\t\tthis._ass.addAttachment(this._currentAttachment);\n\t\t\t\t\t\t\tthis._currentAttachment = null;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tthis._currentAttachment = new Attachment(startOfNewAttachment[1].trim(), (this.currentSection === Section.Fonts) ? AttachmentType.Font : AttachmentType.Graphic);\n\t\t\t\t\t}\n\t\t\t\t\telse if (this._currentAttachment !== null) {\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tthis._currentAttachment.contents += uuencodedToBase64(line);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcatch (ex) {\n\t\t\t\t\t\t\tif (debugMode) {\n\t\t\t\t\t\t\t\tconsole.error(`Encountered error while reading font ${ this._currentAttachment.filename }: %o`, ex);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tthis._currentAttachment = null;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\t// Ignore.\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase Section.Other:\n\t\t\t\t\t// Ignore other sections.\n\t\t\t\t\tbreak;\n\n\t\t\t\tdefault:\n\t\t\t\t\tthrow new Error(`Unhandled state ${ this.currentSection }`);\n\t\t\t}\n\t\t}\n\n\t\tthis._stream.nextLine().then(line => this._onNextLine(line), reason => {\n\t\t\tthis._minimalDeferred.reject(reason);\n\t\t\tthis._deferred.reject(reason);\n\t\t});\n\t}\n}\n\n/**\n * A parser that parses an {@link libjass.ASS} object from a {@link libjass.parser.Stream} of an SRT script.\n *\n * @param {!libjass.parser.Stream} stream The {@link libjass.parser.Stream} to parse\n */\nexport class SrtStreamParser {\n\tprivate _ass: ASS = new ASS();\n\tprivate _deferred: DeferredPromise<ASS> = new DeferredPromise<ASS>();\n\n\tprivate _shouldSwallowBom: boolean = true;\n\n\tprivate _currentDialogueNumber: string = null;\n\tprivate _currentDialogueStart: string = null;\n\tprivate _currentDialogueEnd: string = null;\n\tprivate _currentDialogueText: string = null;\n\n\tconstructor(private _stream: Stream) {\n\t\tthis._stream.nextLine().then(line => this._onNextLine(line), reason => {\n\t\t\tthis._deferred.reject(reason);\n\t\t});\n\n\t\tthis._ass.properties.resolutionX = 1280;\n\t\tthis._ass.properties.resolutionY = 720;\n\t\tthis._ass.properties.wrappingStyle = 1;\n\t\tthis._ass.properties.scaleBorderAndShadow = true;\n\n\t\tconst newStyle = new Style(new Map([[\"Name\", \"Default\"], [\"FontSize\", \"36\"]]));\n\t\tthis._ass.styles.set(newStyle.name, newStyle);\n\t}\n\n\t/**\n\t * @type {!Promise.<!libjass.ASS>} A promise that will be resolved when the entire stream has been parsed.\n\t */\n\tget ass(): Promise<ASS> {\n\t\treturn this._deferred.promise;\n\t}\n\n\t/**\n\t * @param {string} line\n\t */\n\tprivate _onNextLine(line: string): void {\n\t\tif (line === null) {\n\t\t\tif (this._currentDialogueNumber !== null && this._currentDialogueStart !== null && this._currentDialogueEnd !== null && this._currentDialogueText !== null) {\n\t\t\t\tthis._ass.dialogues.push(new Dialogue(new Map([\n\t\t\t\t\t[\"Style\", \"Default\"],\n\t\t\t\t\t[\"Start\", this._currentDialogueStart],\n\t\t\t\t\t[\"End\", this._currentDialogueEnd],\n\t\t\t\t\t[\"Text\", this._currentDialogueText],\n\t\t\t\t]), this._ass));\n\t\t\t}\n\n\t\t\tthis._deferred.resolve(this._ass);\n\t\t\treturn;\n\t\t}\n\n\t\tif (line[line.length - 1] === \"\\r\") {\n\t\t\tline = line.substr(0, line.length - 1);\n\t\t}\n\n\t\tif (line.charCodeAt(0) === 0xfeff && this._shouldSwallowBom) {\n\t\t\tline = line.substr(1);\n\t\t}\n\n\t\tthis._shouldSwallowBom = false;\n\n\t\tif (line === \"\") {\n\t\t\tif (this._currentDialogueNumber !== null && this._currentDialogueStart !== null && this._currentDialogueEnd !== null && this._currentDialogueText !== null) {\n\t\t\t\tthis._ass.dialogues.push(new Dialogue(new Map([\n\t\t\t\t\t[\"Style\", \"Default\"],\n\t\t\t\t\t[\"Start\", this._currentDialogueStart],\n\t\t\t\t\t[\"End\", this._currentDialogueEnd],\n\t\t\t\t\t[\"Text\", this._currentDialogueText],\n\t\t\t\t]), this._ass));\n\t\t\t}\n\n\t\t\tthis._currentDialogueNumber = this._currentDialogueStart = this._currentDialogueEnd = this._currentDialogueText = null;\n\t\t}\n\t\telse {\n\t\t\tif (this._currentDialogueNumber === null) {\n\t\t\t\tif (/^\\d+$/.test(line)) {\n\t\t\t\t\tthis._currentDialogueNumber = line;\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (this._currentDialogueStart === null && this._currentDialogueEnd === null) {\n\t\t\t\tconst match = /^(\\d\\d:\\d\\d:\\d\\d,\\d\\d\\d) --> (\\d\\d:\\d\\d:\\d\\d,\\d\\d\\d)/.exec(line);\n\t\t\t\tif (match !== null) {\n\t\t\t\t\tthis._currentDialogueStart = match[1].replace(\",\", \".\");\n\t\t\t\t\tthis._currentDialogueEnd = match[2].replace(\",\", \".\");\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\tline = line\n\t\t\t\t\t.replace(/<b>/g, \"{\\\\b1}\").replace(/\\{b\\}/g, \"{\\\\b1}\")\n\t\t\t\t\t.replace(/<\\/b>/g, \"{\\\\b0}\").replace(/\\{\\/b\\}/g, \"{\\\\b0}\")\n\t\t\t\t\t.replace(/<i>/g, \"{\\\\i1}\").replace(/\\{i\\}/g, \"{\\\\i1}\")\n\t\t\t\t\t.replace(/<\\/i>/g, \"{\\\\i0}\").replace(/\\{\\/i\\}/g, \"{\\\\i0}\")\n\t\t\t\t\t.replace(/<u>/g, \"{\\\\u1}\").replace(/\\{u\\}/g, \"{\\\\u1}\")\n\t\t\t\t\t.replace(/<\\/u>/g, \"{\\\\u0}\").replace(/\\{\\/u\\}/g, \"{\\\\u0}\")\n\t\t\t\t\t.replace(\n\t\t\t\t\t\t/<font color=\"#([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})\">/g,\n\t\t\t\t\t\t(/* ujs:unreferenced */ substring: string, red: string, green: string, blue: string) => `{\\c&H${ blue }${ green }${ red }&}`\n\t\t\t\t\t).replace(/<\\/font>/g, \"{\\\\c}\");\n\n\t\t\t\tif (this._currentDialogueText !== null) {\n\t\t\t\t\tthis._currentDialogueText += \"\\\\N\" + line;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tthis._currentDialogueText = line;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tthis._stream.nextLine().then(line => this._onNextLine(line), reason => {\n\t\t\tthis._deferred.reject(reason);\n\t\t});\n\t}\n}\n\n/**\n * Converts a uuencoded string to a base64 string.\n *\n * @param {string} str\n * @return {string}\n */\nfunction uuencodedToBase64(str: string): string {\n\tlet result = \"\";\n\n\tfor (let i = 0; i < str.length; i++) {\n\t\tconst charCode = str.charCodeAt(i) - 33;\n\n\t\tif (charCode < 0 || charCode > 63) {\n\t\t\tthrow new Error(`Out-of-range character code ${ charCode } at index ${ i } in string ${ str }`);\n\t\t}\n\t\tif (charCode < 26) {\n\t\t\tresult += String.fromCharCode(\"A\".charCodeAt(0) + charCode);\n\t\t}\n\t\telse if (charCode < 52) {\n\t\t\tresult += String.fromCharCode(\"a\".charCodeAt(0) + charCode - 26);\n\t\t}\n\t\telse if (charCode < 62) {\n\t\t\tresult += String.fromCharCode(\"0\".charCodeAt(0) + charCode - 52);\n\t\t}\n\t\telse if (charCode === 62) {\n\t\t\tresult += \"+\";\n\t\t}\n\t\telse {\n\t\t\tresult += \"/\";\n\t\t}\n\t}\n\n\treturn result;\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Promise, DeferredPromise } from \"../utility/promise\";\n\nexport interface ReadableStream {\n\t/**\n\t * @return {!ReadableStreamReader}\n\t */\n\tgetReader(): ReadableStreamReader;\n}\n\ninterface ReadableStreamReader {\n\t/**\n\t * @return {!Promise.<{ value?: Uint8Array, done: boolean }>}\n\t */\n\tread(): Promise<{ value: Uint8Array; done: boolean; }>;\n}\n\nexport interface TextDecoder {\n\t/**\n\t * @param {!ArrayBuffer|!ArrayBufferView} input\n\t * @param {{ stream: boolean }} options\n\t * @return {string}\n\t */\n\tdecode(input: ArrayBuffer | ArrayBufferView, options: { stream: boolean }): string;\n}\nexport interface TextDecoderConstructor {\n\tnew (encoding: string, options: { ignoreBOM: boolean }): TextDecoder;\n\n\t/**\n\t * @type {!TextDecoder}\n\t */\n\tprototype: TextDecoder;\n}\n\ndeclare const global: {\n\t/**\n\t * @type {!TextDecoderConstructor}\n\t */\n\tTextDecoder?: TextDecoderConstructor;\n};\n\n/**\n * An interface for a stream.\n */\nexport interface Stream {\n\t/**\n\t * @return {!Promise.<?string>} A promise that will be resolved with the next line, or null if the stream is exhausted.\n\t */\n\tnextLine(): Promise<string>;\n}\n\n/**\n * A {@link libjass.parser.Stream} that reads from a string in memory.\n *\n * @param {string} str The string\n */\nexport class StringStream implements Stream {\n\tprivate _readTill: number = 0;\n\n\tconstructor(private _str: string) { }\n\n\t/**\n\t * @return {!Promise.<?string>} A promise that will be resolved with the next line, or null if the string has been completely read.\n\t */\n\tnextLine(): Promise<string> {\n\t\tlet result: Promise<string> = null;\n\n\t\tif (this._readTill < this._str.length) {\n\t\t\tconst nextNewLinePos = this._str.indexOf(\"\\n\", this._readTill);\n\t\t\tif (nextNewLinePos !== -1) {\n\t\t\t\tresult = Promise.resolve(this._str.substring(this._readTill, nextNewLinePos));\n\t\t\t\tthis._readTill = nextNewLinePos + 1;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tresult = Promise.resolve(this._str.substr(this._readTill));\n\t\t\t\tthis._readTill = this._str.length;\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\tresult = Promise.resolve<string>(null);\n\t\t}\n\n\t\treturn result;\n\t}\n}\n\n/**\n * A {@link libjass.parser.Stream} that reads from an XMLHttpRequest object.\n *\n * @param {!XMLHttpRequest} xhr The XMLHttpRequest object. Make sure to not call .open() on this object before passing it in here,\n * since event handlers cannot be registered after open() has been called.\n */\nexport class XhrStream implements Stream {\n\tprivate _readTill: number = 0;\n\tprivate _pendingDeferred: DeferredPromise<string> = null;\n\tprivate _failedError: ErrorEvent = null;\n\n\tconstructor(private _xhr: XMLHttpRequest) {\n\t\t_xhr.addEventListener(\"progress\", () => this._onXhrProgress(), false);\n\t\t_xhr.addEventListener(\"load\", () => this._onXhrLoad(), false);\n\t\t_xhr.addEventListener(\"error\", event => this._onXhrError(event), false);\n\t}\n\n\t/**\n\t * @return {!Promise.<?string>} A promise that will be resolved with the next line, or null if the stream is exhausted.\n\t */\n\tnextLine(): Promise<string> {\n\t\tif (this._pendingDeferred !== null) {\n\t\t\tthrow new Error(\"XhrStream only supports one pending unfulfilled read at a time.\");\n\t\t}\n\n\t\tconst deferred = this._pendingDeferred = new DeferredPromise<string>();\n\n\t\tthis._tryResolveNextLine();\n\n\t\treturn deferred.promise;\n\t}\n\n\t/**\n\t */\n\tprivate _onXhrProgress(): void {\n\t\tif (this._pendingDeferred === null) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this._xhr.readyState === XMLHttpRequest.DONE) {\n\t\t\t/* Suppress resolving next line here. Let the \"load\" or \"error\" event handlers do it.\n\t\t\t *\n\t\t\t * This is required because a failed XHR fires the progress event with readyState === DONE before it fires the error event.\n\t\t\t * This would confuse _tryResolveNextLine() into thinking the request succeeded with no data if it was called here.\n\t\t\t */\n\t\t\treturn;\n\t\t}\n\n\t\tthis._tryResolveNextLine();\n\t}\n\n\t/**\n\t */\n\tprivate _onXhrLoad(): void {\n\t\tif (this._pendingDeferred === null) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._tryResolveNextLine();\n\t}\n\n\t/**\n\t * @param {!ErrorEvent} event\n\t */\n\tprivate _onXhrError(event: ErrorEvent): void {\n\t\tthis._failedError = event;\n\n\t\tif (this._pendingDeferred === null) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._tryResolveNextLine();\n\t}\n\n\t/**\n\t */\n\tprivate _tryResolveNextLine(): void {\n\t\tif (this._failedError !== null) {\n\t\t\tthis._pendingDeferred.reject(this._failedError);\n\t\t\treturn;\n\t\t}\n\n\t\tconst response = this._xhr.responseText;\n\n\t\tconst nextNewLinePos = response.indexOf(\"\\n\", this._readTill);\n\t\tif (nextNewLinePos !== -1) {\n\t\t\tthis._pendingDeferred.resolve(response.substring(this._readTill, nextNewLinePos));\n\t\t\tthis._readTill = nextNewLinePos + 1;\n\t\t\tthis._pendingDeferred = null;\n\t\t}\n\n\t\telse if (this._xhr.readyState === XMLHttpRequest.DONE) {\n\t\t\tif (this._failedError !== null) {\n\t\t\t\tthis._pendingDeferred.reject(this._failedError);\n\t\t\t}\n\n\t\t\t// No more data. This is the last line.\n\t\t\telse if (this._readTill < response.length) {\n\t\t\t\tthis._pendingDeferred.resolve(response.substr(this._readTill));\n\t\t\t\tthis._readTill = response.length;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tthis._pendingDeferred.resolve(null);\n\t\t\t}\n\n\t\t\tthis._pendingDeferred = null;\n\t\t}\n\t}\n}\n\n/**\n * A {@link libjass.parser.Stream} that reads from a ReadableStream object.\n *\n * @param {!ReadableStream} stream\n * @param {string} encoding\n */\nexport class BrowserReadableStream implements Stream {\n\tprivate _reader: ReadableStreamReader;\n\tprivate _decoder: TextDecoder;\n\tprivate _buffer: string = \"\";\n\tprivate _pendingDeferred: DeferredPromise<string> = null;\n\n\tconstructor(stream: ReadableStream, encoding: string) {\n\t\tthis._reader = stream.getReader();\n\t\tthis._decoder = new global.TextDecoder(encoding, { ignoreBOM: true });\n\t}\n\n\t/**\n\t * @return {!Promise.<?string>} A promise that will be resolved with the next line, or null if the stream is exhausted.\n\t */\n\tnextLine(): Promise<string> {\n\t\tif (this._pendingDeferred !== null) {\n\t\t\tthrow new Error(\"BrowserReadableStream only supports one pending unfulfilled read at a time.\");\n\t\t}\n\n\t\tconst deferred = this._pendingDeferred = new DeferredPromise<string>();\n\n\t\tthis._tryResolveNextLine();\n\n\t\treturn deferred.promise;\n\t}\n\n\t/**\n\t */\n\tprivate _tryResolveNextLine(): void {\n\t\tconst nextNewLinePos = this._buffer.indexOf(\"\\n\");\n\t\tif (nextNewLinePos !== -1) {\n\t\t\tthis._pendingDeferred.resolve(this._buffer.substr(0, nextNewLinePos));\n\t\t\tthis._buffer = this._buffer.substr(nextNewLinePos + 1);\n\t\t\tthis._pendingDeferred = null;\n\t\t}\n\n\t\telse {\n\t\t\tthis._reader.read().then(next => {\n\t\t\t\tconst { value, done } = next;\n\n\t\t\t\tif (!done) {\n\t\t\t\t\tthis._buffer += this._decoder.decode(value, { stream: true });\n\t\t\t\t\tthis._tryResolveNextLine();\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t// No more data.\n\t\t\t\t\tif (this._buffer.length === 0) {\n\t\t\t\t\t\tthis._pendingDeferred.resolve(null);\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\tthis._pendingDeferred.resolve(this._buffer);\n\t\t\t\t\t\tthis._buffer = \"\";\n\t\t\t\t\t}\n\n\t\t\t\t\tthis._pendingDeferred = null;\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Attachment } from \"../types/attachment\";\n\nimport { Map } from \"../utility/map\";\nimport { Set } from \"../utility/set\";\n\ntype DataReader = { dataView: DataView; position: number; };\n\nenum DataType {\n\tChar,\n\tUint16,\n\tUint32,\n}\n\ntype StructMemberDefinition = { type: DataType; field?: string; };\n\nconst fieldDecorators = new Map<DataType, (proto: any, field: string) => void>();\n\n@struct\nclass OffsetTable {\n\t/** @type {number} */ @field(DataType.Uint16) majorVersion: number;\n\t/** @type {number} */ @field(DataType.Uint16) minorVersion: number;\n\t/** @type {number} */ @field(DataType.Uint16) numTables: number;\n\t/** @type {number} */ @field(DataType.Uint16) searchRange: number;\n\t/** @type {number} */ @field(DataType.Uint16) entrySelector: number;\n\t/** @type {number} */ @field(DataType.Uint16) rangeShift: number;\n\n\t/** @type {function(!{ dataView: DataView, position: number }): OffsetTable} */\n\tstatic read: (reader: DataReader) => OffsetTable;\n}\n\n@struct\nclass TableRecord {\n\t/** @type {string} */ @field(DataType.Char) c1: string;\n\t/** @type {string} */ @field(DataType.Char) c2: string;\n\t/** @type {string} */ @field(DataType.Char) c3: string;\n\t/** @type {string} */ @field(DataType.Char) c4: string;\n\t/** @type {number} */ @field(DataType.Uint32) checksum: number;\n\t/** @type {number} */ @field(DataType.Uint32) offset: number;\n\t/** @type {number} */ @field(DataType.Uint32) length: number;\n\n\t/** @type {function(!{ dataView: DataView, position: number }): TableRecord} */\n\tstatic read: (reader: DataReader) => TableRecord;\n}\n\n@struct\nclass NameTableHeader {\n\t/** @type {number} */ @field(DataType.Uint16) formatSelector: number;\n\t/** @type {number} */ @field(DataType.Uint16) count: number;\n\t/** @type {number} */ @field(DataType.Uint16) stringOffset: number;\n\n\t/** @type {function(!{ dataView: DataView, position: number }): NameTableHeader} */\n\tstatic read: (reader: DataReader) => NameTableHeader;\n}\n\n@struct\nclass NameRecord {\n\t/** @type {number} */ @field(DataType.Uint16) platformId: number;\n\t/** @type {number} */ @field(DataType.Uint16) encodingId: number;\n\t/** @type {number} */ @field(DataType.Uint16) languageId: number;\n\t/** @type {number} */ @field(DataType.Uint16) nameId: number;\n\t/** @type {number} */ @field(DataType.Uint16) length: number;\n\t/** @type {number} */ @field(DataType.Uint16) offset: number;\n\n\t/** @type {function(!{ dataView: DataView, position: number }): NameRecord} */\n\tstatic read: (reader: DataReader) => NameRecord;\n}\n\n/**\n * Gets all the font names from the given font attachment.\n *\n * @param {!libjass.Attachment} attachment\n * @return {!libjass.Set.<string>}\n */\nexport function getTtfNames(attachment: Attachment): Set<string> {\n\tconst decoded = atob(attachment.contents);\n\n\tconst bytes = new Uint8Array(new ArrayBuffer(decoded.length));\n\n\tfor (let i = 0; i < decoded.length; i++) {\n\t\tbytes[i] = decoded.charCodeAt(i);\n\t}\n\n\tconst reader = { dataView: new DataView(bytes.buffer), position: 0 };\n\n\tconst offsetTable = OffsetTable.read(reader);\n\tlet nameTableRecord: TableRecord = null;\n\tfor (let i = 0; i < offsetTable.numTables; i++) {\n\t\tconst tableRecord = TableRecord.read(reader);\n\t\tif (tableRecord.c1 + tableRecord.c2 + tableRecord.c3 + tableRecord.c4 === \"name\") {\n\t\t\tnameTableRecord = tableRecord;\n\t\t\tbreak;\n\t\t}\n\t}\n\n\treader.position = nameTableRecord.offset;\n\tconst nameTableHeader = NameTableHeader.read(reader);\n\n\tconst result = new Set<string>();\n\tfor (let i = 0; i < nameTableHeader.count; i++) {\n\t\tconst nameRecord = NameRecord.read(reader);\n\n\t\tswitch (nameRecord.nameId) {\n\t\t\tcase 1:\n\t\t\tcase 4:\n\t\t\tcase 6:\n\t\t\t\tconst recordOffset = nameTableRecord.offset + nameTableHeader.stringOffset + nameRecord.offset;\n\t\t\t\tconst nameBytes = bytes.subarray(recordOffset, recordOffset + nameRecord.length);\n\n\t\t\t\tswitch (nameRecord.platformId) {\n\t\t\t\t\tcase 1: {\n\t\t\t\t\t\tlet name = \"\";\n\n\t\t\t\t\t\tfor (let j = 0; j < nameBytes.length; j++) {\n\t\t\t\t\t\t\tname += String.fromCharCode(nameBytes[j]);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tresult.add(name);\n\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase 3: {\n\t\t\t\t\t\tlet name = \"\";\n\n\t\t\t\t\t\tfor (let j = 0; j < nameBytes.length; j += 2) {\n\t\t\t\t\t\t\tname += String.fromCharCode((nameBytes[j] << 8) + nameBytes[j + 1]);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tresult.add(name);\n\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\tbreak;\n\t\t}\n\t}\n\n\treturn result;\n}\n\n/**\n * @param {!function(new(): T)} clazz\n * @return {!function(new(): T)}\n */\nfunction struct<T>(clazz: { new (): T; read(reader: DataReader): T; }): { new (): T; read(reader: DataReader): T; } {\n\tconst fields: StructMemberDefinition[] = (<any>clazz).__fields;\n\n\tclazz.read = (reader: DataReader) => {\n\t\tconst result: any = new clazz();\n\n\t\tfor (const field of fields) {\n\t\t\tlet value: any;\n\t\t\tswitch (field.type) {\n\t\t\t\tcase DataType.Char:\n\t\t\t\t\tvalue = String.fromCharCode(reader.dataView.getInt8(reader.position));\n\t\t\t\t\treader.position += 1;\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase DataType.Uint16:\n\t\t\t\t\tvalue = reader.dataView.getUint16(reader.position);\n\t\t\t\t\treader.position += 2;\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase DataType.Uint32:\n\t\t\t\t\tvalue = reader.dataView.getUint32(reader.position);\n\t\t\t\t\treader.position += 4;\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tresult[field.field] = value;\n\t\t}\n\n\t\treturn result;\n\t};\n\n\treturn clazz;\n}\n\n/**\n * @param {number} type\n * @return {function(T, string)}\n */\nfunction field<T>(type: DataType): (proto: T, field: string) => void {\n\tlet existingDecorator = fieldDecorators.get(type);\n\tif (existingDecorator === undefined) {\n\t\texistingDecorator =(proto: T, field: string) => {\n\t\t\tconst ctor: { __fields?: StructMemberDefinition[] } = proto.constructor;\n\t\t\tif (ctor.__fields === undefined) {\n\t\t\t\tctor.__fields = [];\n\t\t\t}\n\n\t\t\tctor.__fields.push({ type, field });\n\t\t};\n\n\t\tfieldDecorators.set(type, existingDecorator);\n\t}\n\n\treturn existingDecorator;\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * The base interface of the drawing instructions.\n */\nexport interface Instruction { }\n\n/**\n * An instruction to move to a particular position.\n *\n * @param {number} x\n * @param {number} y\n */\nexport class MoveInstruction implements Instruction {\n\tconstructor(private _x: number, private _y: number) { }\n\n\t/**\n\t * The X position of this move instruction.\n\t *\n\t * @type {number}\n\t */\n\tget x(): number {\n\t\treturn this._x;\n\t}\n\n\t/**\n\t * The Y position of this move instruction.\n\t *\n\t * @type {number}\n\t */\n\tget y(): number {\n\t\treturn this._y;\n\t}\n}\n\n/**\n * An instruction to draw a line to a particular position.\n *\n * @param {number} x\n * @param {number} y\n */\nexport class LineInstruction implements Instruction {\n\tconstructor(private _x: number, private _y: number) { }\n\n\t/**\n\t * The X position of this line instruction.\n\t *\n\t * @type {number}\n\t */\n\tget x(): number {\n\t\treturn this._x;\n\t}\n\n\t/**\n\t * The Y position of this line instruction.\n\t *\n\t * @type {number}\n\t */\n\tget y(): number {\n\t\treturn this._y;\n\t}\n}\n\n/**\n * An instruction to draw a cubic bezier curve to a particular position, with two given control points.\n *\n * @param {number} x1\n * @param {number} y1\n * @param {number} x2\n * @param {number} y2\n * @param {number} x3\n * @param {number} y3\n */\nexport class CubicBezierCurveInstruction implements Instruction {\n\tconstructor(private _x1: number, private _y1: number, private _x2: number, private _y2: number, private _x3: number, private _y3: number) { }\n\n\t/**\n\t * The X position of the first control point of this cubic bezier curve instruction.\n\t *\n\t * @type {number}\n\t */\n\tget x1(): number {\n\t\treturn this._x1;\n\t}\n\n\t/**\n\t * The Y position of the first control point of this cubic bezier curve instruction.\n\t *\n\t * @type {number}\n\t */\n\tget y1(): number {\n\t\treturn this._y1;\n\t}\n\n\t/**\n\t * The X position of the second control point of this cubic bezier curve instruction.\n\t *\n\t * @type {number}\n\t */\n\tget x2(): number {\n\t\treturn this._x2;\n\t}\n\n\t/**\n\t * The Y position of the second control point of this cubic bezier curve instruction.\n\t *\n\t * @type {number}\n\t */\n\tget y2(): number {\n\t\treturn this._y2;\n\t}\n\n\t/**\n\t * The ending X position of this cubic bezier curve instruction.\n\t *\n\t * @type {number}\n\t */\n\tget x3(): number {\n\t\treturn this._x3;\n\t}\n\n\t/**\n\t * The ending Y position of this cubic bezier curve instruction.\n\t *\n\t * @type {number}\n\t */\n\tget y3(): number {\n\t\treturn this._y3;\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { WrappingStyle as WrappingStyleType } from \"../types/misc\";\n\nimport * as drawing from \"./drawing\";\nexport { drawing };\n\n/**\n * Represents a CSS color with red, green, blue and alpha components.\n *\n * Instances of this class are immutable.\n *\n * @param {number} red\n * @param {number} green\n * @param {number} blue\n * @param {number=1} alpha\n */\nexport class Color {\n\tconstructor(private _red: number, private _green: number, private _blue: number, private _alpha: number = 1) { }\n\n\t/**\n\t * The red component of this color as a number between 0 and 255.\n\t *\n\t * @type {number}\n\t */\n\tget red(): number {\n\t\treturn this._red;\n\t}\n\n\t/**\n\t * The green component of this color as a number between 0 and 255.\n\t *\n\t * @type {number}\n\t */\n\tget green(): number {\n\t\treturn this._green;\n\t}\n\n\t/**\n\t * The blue component of this color as a number between 0 and 255.\n\t *\n\t * @type {number}\n\t */\n\tget blue(): number {\n\t\treturn this._blue;\n\t}\n\n\t/**\n\t * The alpha component of this color as a number between 0 and 1, where 0 means transparent and 1 means opaque.\n\t *\n\t * @type {number}\n\t */\n\tget alpha(): number {\n\t\treturn this._alpha;\n\t}\n\n\t/**\n\t * @param {?number} value The new alpha. If null, the existing alpha is used.\n\t * @return {!libjass.parts.Color} Returns a new Color instance with the same color but the provided alpha.\n\t */\n\twithAlpha(value: number): Color {\n\t\tif (value !== null) {\n\t\t\treturn new Color(this._red, this._green, this._blue, value);\n\t\t}\n\n\t\treturn this;\n\t}\n\n\t/**\n\t * @return {string} The CSS representation \"rgba(...)\" of this color.\n\t */\n\ttoString(): string {\n\t\treturn `rgba(${ this._red }, ${ this._green }, ${ this._blue }, ${ this._alpha.toFixed(3) })`;\n\t}\n\n\t/**\n\t * Returns a new Color by interpolating the current color to the final color by the given progression.\n\t *\n\t * @param {!libjass.parts.Color} final\n\t * @param {number} progression\n\t * @return {!libjass.parts.Color}\n\t */\n\tinterpolate(final: Color, progression: number): Color {\n\t\treturn new Color(\n\t\t\tthis._red + progression * (final.red - this._red),\n\t\t\tthis._green + progression * (final.green - this._green),\n\t\t\tthis._blue + progression * (final.blue - this._blue),\n\t\t\tthis._alpha + progression * (final.alpha - this._alpha)\n\t\t);\n\t}\n}\n\n/**\n * The base interface of the ASS tag classes.\n */\nexport interface Part { }\n\n/**\n * A comment, i.e., any text enclosed in {} that is not understood as an ASS tag.\n *\n * @param {string} value The text of this comment\n */\nexport class Comment {\n\tconstructor(private _value: string) { }\n\n\t/**\n\t * The value of this comment.\n\t *\n\t * @type {string}\n\t */\n\tget value(): string {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A block of text, i.e., any text not enclosed in {}. Also includes \\h.\n *\n * @param {string} value The content of this block of text\n */\nexport class Text {\n\tconstructor(private _value: string) { }\n\n\t/**\n\t * The value of this text part.\n\t *\n\t * @type {string}\n\t */\n\tget value(): string {\n\t\treturn this._value;\n\t}\n\n\t/**\n\t * @return {string}\n\t */\n\ttoString(): string {\n\t\treturn `Text { value: ${ this._value.replace(/\\u00A0/g, \"\\\\h\") } }`;\n\t}\n}\n\n/**\n * A newline character \\N.\n */\nexport class NewLine {\n}\n\n/**\n * An italic tag {\\i}\n *\n * @param {?boolean} value {\\i1} -> true, {\\i0} -> false, {\\i} -> null\n */\nexport class Italic {\n\tconstructor(private _value: boolean) { }\n\n\t/**\n\t * The value of this italic tag.\n\t *\n\t * @type {?boolean}\n\t */\n\tget value(): boolean {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A bold tag {\\b}\n *\n * @param {*} value {\\b1} -> true, {\\b0} -> false, {\\b###} -> weight of the bold (number), {\\b} -> null\n */\nexport class Bold {\n\tconstructor(private _value: Object) { }\n\n\t/**\n\t * The value of this bold tag.\n\t *\n\t * @type {?boolean|?number}\n\t */\n\tget value(): Object {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * An underline tag {\\u}\n *\n * @param {?boolean} value {\\u1} -> true, {\\u0} -> false, {\\u} -> null\n */\nexport class Underline {\n\tconstructor(private _value: boolean) { }\n\n\t/**\n\t * The value of this underline tag.\n\t *\n\t * @type {?boolean}\n\t */\n\tget value(): boolean {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A strike-through tag {\\s}\n *\n * @param {?boolean} value {\\s1} -> true, {\\s0} -> false, {\\s} -> null\n */\nexport class StrikeThrough {\n\tconstructor(private _value: boolean) { }\n\n\t/**\n\t * The value of this strike-through tag.\n\t *\n\t * @type {?boolean}\n\t */\n\tget value(): boolean {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A border tag {\\bord}\n *\n * @param {?number} value {\\bord###} -> width (number), {\\bord} -> null\n */\nexport class Border {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this border tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A horizontal border tag {\\xbord}\n *\n * @param {?number} value {\\xbord###} -> width (number), {\\xbord} -> null\n */\nexport class BorderX {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this horizontal border tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A vertical border tag {\\ybord}\n *\n * @param {?number} value {\\ybord###} -> height (number), {\\ybord} -> null\n */\nexport class BorderY {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this vertical border tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A shadow tag {\\shad}\n *\n * @param {?number} value {\\shad###} -> depth (number), {\\shad} -> null\n */\nexport class Shadow {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this shadow tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A horizontal shadow tag {\\xshad}\n *\n * @param {?number} value {\\xshad###} -> depth (number), {\\xshad} -> null\n */\nexport class ShadowX {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this horizontal shadow tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A vertical shadow tag {\\yshad}\n *\n * @param {?number} value {\\yshad###} -> depth (number), {\\yshad} -> null\n */\nexport class ShadowY {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this vertical shadow tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A blur tag {\\be}\n *\n * @param {?number} value {\\be###} -> strength (number), {\\be} -> null\n */\nexport class Blur {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this blur tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A Gaussian blur tag {\\blur}\n *\n * @param {?number} value {\\blur###} -> strength (number), {\\blur} -> null\n */\nexport class GaussianBlur {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this Gaussian blur tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A font name tag {\\fn}\n *\n * @param {?string} value {\\fn###} -> name (string), {\\fn} -> null\n */\nexport class FontName {\n\tconstructor(private _value: string) { }\n\n\t/**\n\t * The value of this font name tag.\n\t *\n\t * @type {?string}\n\t */\n\tget value(): string {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A font size tag {\\fs}\n *\n * @param {?number} value {\\fs###} -> size (number), {\\fs} -> null\n */\nexport class FontSize {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this font size tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A font size increase tag {\\fs+}\n *\n * @param {number} value {\\fs+###} -> difference (number)\n */\nexport class FontSizePlus {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this font size increase tag.\n\t *\n\t * @type {number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A font size decrease tag {\\fs-}\n *\n * @param {number} value {\\fs-###} -> difference (number)\n */\nexport class FontSizeMinus {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this font size decrease tag.\n\t *\n\t * @type {number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A horizontal font scaling tag {\\fscx}\n *\n * @param {?number} value {\\fscx###} -> scale (number), {\\fscx} -> null\n */\nexport class FontScaleX {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this horizontal font scaling tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A vertical font scaling tag {\\fscy}\n *\n * @param {?number} value {\\fscy###} -> scale (number), {\\fscy} -> null\n */\nexport class FontScaleY {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this vertical font scaling tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A letter-spacing tag {\\fsp}\n *\n * @param {?number} value {\\fsp###} -> spacing (number), {\\fsp} -> null\n */\nexport class LetterSpacing {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this letter-spacing tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * An X-axis rotation tag {\\frx}\n *\n * @param {?number} value {\\frx###} -> angle (number), {\\frx} -> null\n */\nexport class RotateX {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this X-axis rotation tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A Y-axis rotation tag {\\fry}\n *\n * @param {?number} value {\\fry###} -> angle (number), {\\fry} -> null\n */\nexport class RotateY {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this Y-axis rotation tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A Z-axis rotation tag {\\fr} or {\\frz}\n *\n * @param {?number} value {\\frz###} -> angle (number), {\\frz} -> null\n */\nexport class RotateZ {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this Z-axis rotation tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * An X-axis shearing tag {\\fax}\n *\n * @param {?number} value {\\fax###} -> angle (number), {\\fax} -> null\n */\nexport class SkewX {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this X-axis shearing tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value() {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A Y-axis shearing tag {\\fay}\n *\n * @param {?number} value {\\fay###} -> angle (number), {\\fay} -> null\n */\nexport class SkewY {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this Y-axis shearing tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A primary color tag {\\c} or {\\1c}\n *\n * @param {libjass.parts.Color} value {\\1c###} -> color (Color), {\\1c} -> null\n */\nexport class PrimaryColor {\n\tconstructor(private _value: Color) { }\n\n\t/**\n\t * The value of this primary color tag.\n\t *\n\t * @type {libjass.parts.Color}\n\t */\n\tget value(): Color {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A secondary color tag {\\2c}\n *\n * @param {libjass.parts.Color} value {\\2c###} -> color (Color), {\\2c} -> null\n */\nexport class SecondaryColor {\n\tconstructor(private _value: Color) { }\n\n\t/**\n\t * The value of this secondary color tag.\n\t *\n\t * @type {libjass.parts.Color}\n\t */\n\tget value(): Color {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * An outline color tag {\\3c}\n *\n * @param {libjass.parts.Color} value {\\3c###} -> color (Color), {\\3c} -> null\n */\nexport class OutlineColor {\n\tconstructor(private _value: Color) { }\n\n\t/**\n\t * The value of this outline color tag.\n\t *\n\t * @type {libjass.parts.Color}\n\t */\n\tget value(): Color {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A shadow color tag {\\4c}\n *\n * @param {libjass.parts.Color} value {\\4c###} -> color (Color), {\\4c} -> null\n */\nexport class ShadowColor {\n\tconstructor(private _value: Color) { }\n\n\t/**\n\t * The value of this shadow color tag.\n\t *\n\t * @type {libjass.parts.Color}\n\t */\n\tget value(): Color {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * An alpha tag {\\alpha}\n *\n * @param {?number} value {\\alpha###} -> alpha (number), {\\alpha} -> null\n */\nexport class Alpha {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this alpha tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A primary alpha tag {\\1a}\n *\n * @param {?number} value {\\1a###} -> alpha (number), {\\1a} -> null\n */\nexport class PrimaryAlpha {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this primary alpha tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A secondary alpha tag {\\2a}\n *\n * @param {?number} value {\\2a###} -> alpha (number), {\\2a} -> null\n */\nexport class SecondaryAlpha {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this secondary alpha tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * An outline alpha tag {\\3a}\n *\n * @param {?number} value {\\3a###} -> alpha (number), {\\3a} -> null\n */\nexport class OutlineAlpha {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this outline alpha tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A shadow alpha tag {\\4a}\n *\n * @param {?number} value {\\4a###} -> alpha (number), {\\4a} -> null\n */\nexport class ShadowAlpha {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this shadow alpha tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * An alignment tag {\\an} or {\\a}\n *\n * @param {number} value {\\an###} -> alignment (number)\n */\nexport class Alignment {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this alignment tag.\n\t *\n\t * @type {?number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A color karaoke tag {\\k}\n *\n * @param {number} duration {\\k###} -> duration (number)\n */\nexport class ColorKaraoke {\n\tconstructor(private _duration: number) { }\n\n\t/**\n\t * The duration of this color karaoke tag.\n\t *\n\t * @type {number}\n\t */\n\tget duration(): number {\n\t\treturn this._duration;\n\t}\n}\n\n/**\n * A sweeping color karaoke tag {\\K} or {\\kf}\n *\n * @param {number} duration {\\kf###} -> duration (number)\n */\nexport class SweepingColorKaraoke {\n\tconstructor(private _duration: number) { }\n\n\t/**\n\t * The duration of this sweeping color karaoke tag.\n\t *\n\t * @type {number}\n\t */\n\tget duration(): number {\n\t\treturn this._duration;\n\t}\n}\n\n/**\n * An outline karaoke tag {\\ko}\n *\n * @param {number} duration {\\ko###} -> duration (number)\n */\nexport class OutlineKaraoke {\n\tconstructor(private _duration: number) { }\n\n\t/**\n\t * The duration of this outline karaoke tag.\n\t *\n\t * @type {number}\n\t */\n\tget duration(): number {\n\t\treturn this._duration;\n\t}\n}\n\n/**\n * A wrapping style tag {\\q}\n *\n * @param {number} value {\\q###} -> style (number)\n */\nexport class WrappingStyle {\n\tconstructor(private _value: WrappingStyleType) { }\n\n\t/**\n\t * The value of this wrapping style tag.\n\t *\n\t * @type {number}\n\t */\n\tget value(): WrappingStyleType {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A style reset tag {\\r}\n *\n * @param {?string} value {\\r###} -> style name (string), {\\r} -> null\n */\nexport class Reset {\n\tconstructor(private _value: string) { }\n\n\t/**\n\t * The value of this style reset tag.\n\t *\n\t * @type {?string}\n\t */\n\tget value(): string {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A position tag {\\pos}\n *\n * @param {number} x\n * @param {number} y\n */\nexport class Position {\n\tconstructor(private _x: number, private _y: number) { }\n\n\t/**\n\t * The x value of this position tag.\n\t *\n\t * @type {number}\n\t */\n\tget x(): number {\n\t\treturn this._x;\n\t}\n\n\t/**\n\t * The y value of this position tag.\n\t *\n\t * @type {number}\n\t */\n\tget y(): number {\n\t\treturn this._y;\n\t}\n}\n\n/**\n * A movement tag {\\move}\n *\n * @param {number} x1\n * @param {number} y1\n * @param {number} x2\n * @param {number} y2\n * @param {number} t1\n * @param {number} t2\n */\nexport class Move {\n\tconstructor(private _x1: number, private _y1: number, private _x2: number, private _y2: number, private _t1: number, private _t2: number) { }\n\n\t/**\n\t * The starting x value of this move tag.\n\t *\n\t * @type {number}\n\t */\n\tget x1(): number {\n\t\treturn this._x1;\n\t}\n\n\t/**\n\t * The starting y value of this move tag.\n\t *\n\t * @type {number}\n\t */\n\tget y1(): number {\n\t\treturn this._y1;\n\t}\n\n\t/**\n\t * The ending x value of this move tag.\n\t *\n\t * @type {number}\n\t */\n\tget x2(): number {\n\t\treturn this._x2;\n\t}\n\n\t/**\n\t * The ending y value of this move tag.\n\t *\n\t * @type {number}\n\t */\n\tget y2(): number {\n\t\treturn this._y2;\n\t}\n\n\t/**\n\t * The start time of this move tag.\n\t *\n\t * @type {number}\n\t */\n\tget t1(): number {\n\t\treturn this._t1;\n\t}\n\n\t/**\n\t * The end time value of this move tag.\n\t *\n\t * @type {number}\n\t */\n\tget t2(): number {\n\t\treturn this._t2;\n\t}\n}\n\n/**\n * A rotation origin tag {\\org}\n *\n * @param {number} x\n * @param {number} y\n */\nexport class RotationOrigin {\n\tconstructor(private _x: number, private _y: number) { }\n\n\t/**\n\t * The x value of this rotation origin tag.\n\t *\n\t * @type {number}\n\t */\n\tget x(): number {\n\t\treturn this._x;\n\t}\n\n\t/**\n\t * The y value of this rotation origin tag.\n\t *\n\t * @type {number}\n\t */\n\tget y(): number {\n\t\treturn this._y;\n\t}\n}\n\n/**\n * A simple fade tag {\\fad}\n *\n * @param {number} start\n * @param {number} end\n */\nexport class Fade {\n\tconstructor(private _start: number, private _end: number) { }\n\n\t/**\n\t * The start time of this fade tag.\n\t *\n\t * @type {number}\n\t */\n\tget start(): number {\n\t\treturn this._start;\n\t}\n\n\t/**\n\t * The end time of this fade tag.\n\t *\n\t * @type {number}\n\t */\n\tget end(): number {\n\t\treturn this._end;\n\t}\n}\n\n/**\n * A complex fade tag {\\fade}\n *\n * @param {number} a1\n * @param {number} a2\n * @param {number} a3\n * @param {number} t1\n * @param {number} t2\n * @param {number} t3\n * @param {number} t4\n */\nexport class ComplexFade {\n\tconstructor(\n\t\tprivate _a1: number, private _a2: number, private _a3: number,\n\t\tprivate _t1: number, private _t2: number, private _t3: number, private _t4: number\n\t) { }\n\n\t/**\n\t * The alpha value of this complex fade tag at time t2.\n\t *\n\t * @type {number}\n\t */\n\tget a1(): number {\n\t\treturn this._a1;\n\t}\n\n\t/**\n\t * The alpha value of this complex fade tag at time t3.\n\t *\n\t * @type {number}\n\t */\n\tget a2(): number {\n\t\treturn this._a2;\n\t}\n\n\t/**\n\t * The alpha value of this complex fade tag at time t4.\n\t *\n\t * @type {number}\n\t */\n\tget a3(): number {\n\t\treturn this._a3;\n\t}\n\n\t/**\n\t * The starting time of this complex fade tag.\n\t *\n\t * @type {number}\n\t */\n\tget t1(): number {\n\t\treturn this._t1;\n\t}\n\n\t/**\n\t * The first intermediate time of this complex fade tag.\n\t *\n\t * @type {number}\n\t */\n\tget t2(): number {\n\t\treturn this._t2;\n\t}\n\n\t/**\n\t * The second intermediate time of this complex fade tag.\n\t *\n\t * @type {number}\n\t */\n\tget t3(): number {\n\t\treturn this._t3;\n\t}\n\n\t/**\n\t * The ending time of this complex fade tag.\n\t *\n\t * @type {number}\n\t */\n\tget t4(): number {\n\t\treturn this._t4;\n\t}\n}\n\n/**\n * A transform tag {\\t}\n *\n * @param {number} start\n * @param {number} end\n * @param {number} accel\n * @param {!Array.<!libjass.parts.Tag>} tags\n */\nexport class Transform {\n\tconstructor(private _start: number, private _end: number, private _accel: number, private _tags: Part[]) { }\n\n\t/**\n\t * The starting time of this transform tag.\n\t *\n\t * @type {?number}\n\t */\n\tget start(): number {\n\t\treturn this._start;\n\t}\n\n\t/**\n\t * The ending time of this transform tag.\n\t *\n\t * @type {?number}\n\t */\n\tget end(): number {\n\t\treturn this._end;\n\t}\n\n\t/**\n\t * The acceleration of this transform tag.\n\t *\n\t * @type {?number}\n\t */\n\tget accel(): number {\n\t\treturn this._accel;\n\t}\n\n\t/**\n\t * The tags animated by this transform tag.\n\t *\n\t * @type {!Array.<!libjass.parts.Tag>}\n\t */\n\tget tags(): Part[] {\n\t\treturn this._tags;\n\t}\n}\n\n/**\n * A rectangular clip tag {\\clip} or {\\iclip}\n *\n * @param {number} x1\n * @param {number} y1\n * @param {number} x2\n * @param {number} y2\n * @param {boolean} inside\n */\nexport class RectangularClip {\n\tconstructor(private _x1: number, private _y1: number, private _x2: number, private _y2: number, private _inside: boolean) { }\n\n\t/**\n\t * The X coordinate of the starting position of this rectangular clip tag.\n\t *\n\t * @type {number}\n\t */\n\tget x1(): number {\n\t\treturn this._x1;\n\t}\n\n\t/**\n\t * The Y coordinate of the starting position of this rectangular clip tag.\n\t *\n\t * @type {number}\n\t */\n\tget y1(): number {\n\t\treturn this._y1;\n\t}\n\n\t/**\n\t * The X coordinate of the ending position of this rectangular clip tag.\n\t *\n\t * @type {number}\n\t */\n\tget x2(): number {\n\t\treturn this._x2;\n\t}\n\n\t/**\n\t * The Y coordinate of the ending position of this rectangular clip tag.\n\t *\n\t * @type {number}\n\t */\n\tget y2(): number {\n\t\treturn this._y2;\n\t}\n\n\t/**\n\t * Whether this rectangular clip tag clips the region it encloses or the region it excludes.\n\t *\n\t * @type {boolean}\n\t */\n\tget inside(): boolean {\n\t\treturn this._inside;\n\t}\n}\n\n/**\n * A vector clip tag {\\clip} or {\\iclip}\n *\n * @param {number} scale\n * @param {!Array.<!libjass.parts.drawing.Instruction>} instructions\n * @param {boolean} inside\n */\nexport class VectorClip {\n\tconstructor(private _scale: number, private _instructions: drawing.Instruction[], private _inside: boolean) { }\n\n\t/**\n\t * The scale of this vector clip tag.\n\t *\n\t * @type {number}\n\t */\n\tget scale(): number {\n\t\treturn this._scale;\n\t}\n\n\t/**\n\t * The clip commands of this vector clip tag.\n\t *\n\t * @type {string}\n\t */\n\tget instructions(): drawing.Instruction[] {\n\t\treturn this._instructions;\n\t}\n\n\t/**\n\t * Whether this vector clip tag clips the region it encloses or the region it excludes.\n\t *\n\t * @type {boolean}\n\t */\n\tget inside(): boolean {\n\t\treturn this._inside;\n\t}\n}\n\n/**\n * A drawing mode tag {\\p}\n *\n * @param {number} scale\n */\nexport class DrawingMode {\n\tconstructor(private _scale: number) { }\n\n\t/**\n\t * The scale of this drawing mode tag.\n\t *\n\t * @type {number}\n\t */\n\tget scale(): number {\n\t\treturn this._scale;\n\t}\n}\n\n/**\n * A drawing mode baseline offset tag {\\pbo}\n *\n * @param {number} value\n */\nexport class DrawingBaselineOffset {\n\tconstructor(private _value: number) { }\n\n\t/**\n\t * The value of this drawing mode baseline offset tag.\n\t *\n\t * @type {number}\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n}\n\n/**\n * A pseudo-part representing text interpreted as drawing instructions\n *\n * @param {!Array.<!libjass.parts.drawing.Instruction>} instructions\n */\nexport class DrawingInstructions {\n\tconstructor(private _instructions: drawing.Instruction[]) { }\n\n\t/**\n\t * The instructions contained in this drawing instructions part.\n\t *\n\t * @type {!Array.<!libjass.parts.drawing.Instruction>}\n\t */\n\tget instructions(): drawing.Instruction[] {\n\t\treturn this._instructions;\n\t}\n}\n\nconst addToString = function (ctor: Function, ctorName: string) {\n\tif (!ctor.prototype.hasOwnProperty(\"toString\")) {\n\t\tconst propertyNames = Object.getOwnPropertyNames(ctor.prototype).filter(property => property !== \"constructor\");\n\n\t\tctor.prototype.toString = function () {\n\t\t\treturn (\n\t\t\t\tctorName + \" { \" +\n\t\t\t\tpropertyNames.map(name => `${ name }: ${ (<any>this)[name] }`).join(\", \") +\n\t\t\t\t((propertyNames.length > 0) ? \" \" : \"\") +\n\t\t\t\t\"}\"\n\t\t\t);\n\t\t}\n\t}\n};\n\nimport { registerClassPrototype } from \"../webworker/misc\";\n\ndeclare const exports: any;\n\nfor (const key of Object.keys(exports)) {\n\tconst value: any = exports[key];\n\tif (value instanceof Function) {\n\t\taddToString(value, key);\n\t\tregisterClassPrototype(value.prototype);\n\t}\n}\n\nfor (const key of Object.keys(drawing)) {\n\tconst value: any = (<any>drawing)[key];\n\tif (value instanceof Function) {\n\t\taddToString(value, `Drawing${ key }`);\n\t\tregisterClassPrototype(value.prototype);\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { debugMode } from \"../../settings\";\n\nimport { Clock, ClockEvent } from \"./base\";\nimport { ManualClock } from \"./manual\";\n\n/**\n * An implementation of {@link libjass.renderers.Clock} that automatically ticks and generates {@link libjass.renderers.ClockEvent}s according to the state of an external driver.\n *\n * For example, if you're using libjass to render subtitles on a canvas with your own video controls, these video controls will function as the driver to this AutoClock.\n * It would call {@link libjass.renderers.AutoClock.play}, {@link libjass.renderers.AutoClock.pause}, etc. when the user pressed the corresponding video controls.\n *\n * The difference from ManualClock is that AutoClock does not require the driver to call something like {@link libjass.renderers.ManualClock.tick}. Instead it keeps its\n * own time with a high-resolution requestAnimationFrame-based timer.\n *\n * If using libjass with a <video> element, consider using {@link libjass.renderers.VideoClock} that uses the video element as a driver.\n *\n * @param {function():number} getCurrentTime A callback that will be invoked to get the current time of the external driver.\n * @param {number} autoPauseAfter If two calls to getCurrentTime are more than autoPauseAfter milliseconds apart but return the same time, then the external driver will be\n * considered to have paused.\n */\nexport class AutoClock implements Clock {\n\tprivate _manualClock: ManualClock = new ManualClock();\n\n\tprivate _nextAnimationFrameRequestId: number = null;\n\n\tprivate _lastKnownExternalTime: number = null;\n\tprivate _lastKnownExternalTimeObtainedAt: number = null;\n\n\tconstructor(private _getCurrentTime: () => number, private _autoPauseAfter: number) { }\n\n\t/**\n\t * Tells the clock to start generating ticks.\n\t */\n\tplay(): void {\n\t\tif (!this._manualClock.enabled) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._startTicking();\n\n\t\tthis._manualClock.play();\n\t}\n\n\t/**\n\t * Tells the clock to pause.\n\t */\n\tpause(): void {\n\t\tif (!this._manualClock.enabled) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this._nextAnimationFrameRequestId === null) {\n\t\t\tif (debugMode) {\n\t\t\t\tconsole.warn(\"AutoClock.pause: Abnormal state detected. AutoClock._nextAnimationFrameRequestId should not have been null.\");\n\t\t\t}\n\n\t\t\treturn;\n\t\t}\n\n\t\tthis._stopTicking();\n\n\t\tthis._manualClock.pause();\n\t}\n\n\t/**\n\t * Tells the clock that the external driver is seeking.\n\t */\n\tseeking(): void {\n\t\tthis._manualClock.seek(this._getCurrentTime());\n\t}\n\n\t// Clock members\n\n\t/**\n\t * @type {number}\n\t */\n\tget currentTime(): number {\n\t\treturn this._manualClock.currentTime;\n\t}\n\n\t/**\n\t * @type {boolean}\n\t */\n\tget enabled(): boolean {\n\t\treturn this._manualClock.enabled;\n\t}\n\n\t/**\n\t * @type {boolean}\n\t */\n\tget paused(): boolean {\n\t\treturn this._manualClock.paused;\n\t}\n\n\t/**\n\t * Gets the rate of the clock - how fast the clock ticks compared to real time.\n\t *\n\t * @type {number}\n\t */\n\tget rate(): number {\n\t\treturn this._manualClock.rate;\n\t}\n\n\t/**\n\t * Sets the rate of the clock - how fast the clock ticks compared to real time.\n\t *\n\t * @param {number} rate The new rate of the clock.\n\t */\n\tsetRate(rate: number): void {\n\t\tthis._manualClock.setRate(rate);\n\t}\n\n\t/**\n\t * Enable the clock.\n\t *\n\t * @return {boolean} True if the clock is now enabled, false if it was already enabled.\n\t */\n\tenable(): boolean {\n\t\tif (!this._manualClock.enable()) {\n\t\t\treturn false;\n\t\t}\n\n\t\tthis._startTicking();\n\n\t\treturn true;\n\t}\n\n\t/**\n\t * Disable the clock.\n\t *\n\t * @return {boolean} True if the clock is now disabled, false if it was already disabled.\n\t */\n\tdisable(): boolean {\n\t\tif (!this._manualClock.disable()) {\n\t\t\treturn false;\n\t\t}\n\n\t\tthis._stopTicking();\n\n\t\treturn true;\n\t}\n\n\t/**\n\t * Toggle the clock.\n\t */\n\ttoggle(): void {\n\t\tif (this._manualClock.enabled) {\n\t\t\tthis.disable();\n\t\t}\n\t\telse {\n\t\t\tthis.enable();\n\t\t}\n\t}\n\n\t/**\n\t * Enable or disable the clock.\n\t *\n\t * @param {boolean} enabled If true, the clock is enabled, otherwise it's disabled.\n\t * @return {boolean} True if the clock is now in the given state, false if it was already in that state.\n\t */\n\tsetEnabled(enabled: boolean): boolean {\n\t\tif (enabled) {\n\t\t\treturn this.enable();\n\t\t}\n\t\telse {\n\t\t\treturn this.disable();\n\t\t}\n\t}\n\n\t/**\n\t * @param {number} type\n\t * @param {!Function} listener\n\t */\n\taddEventListener(type: ClockEvent, listener: Function): void {\n\t\tthis._manualClock.addEventListener(type, listener);\n\t};\n\n\t/**\n\t * @param {number} timeStamp\n\t */\n\tprivate _onTimerTick(timeStamp: number): void {\n\t\tif (!this._manualClock.enabled) {\n\t\t\tif (debugMode) {\n\t\t\t\tconsole.warn(\"AutoClock._onTimerTick: Called when disabled.\");\n\t\t\t}\n\n\t\t\treturn;\n\t\t}\n\n\t\tconst currentTime = this._manualClock.currentTime;\n\t\tconst currentExternalTime = this._getCurrentTime();\n\n\t\tif (!this._manualClock.paused) {\n\t\t\tif (this._lastKnownExternalTime !== null && currentExternalTime === this._lastKnownExternalTime) {\n\t\t\t\tif (timeStamp - this._lastKnownExternalTimeObtainedAt > this._autoPauseAfter) {\n\t\t\t\t\tthis._lastKnownExternalTimeObtainedAt = null;\n\t\t\t\t\tthis._manualClock.pause();\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tthis._manualClock.tick((timeStamp - this._lastKnownExternalTimeObtainedAt) / 1000 * this._manualClock.rate + this._lastKnownExternalTime);\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\tthis._lastKnownExternalTime = currentExternalTime;\n\t\t\t\tthis._lastKnownExternalTimeObtainedAt = timeStamp;\n\t\t\t\tthis._manualClock.tick(currentExternalTime);\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\tif (currentTime !== currentExternalTime) {\n\t\t\t\tthis._lastKnownExternalTime = currentExternalTime;\n\t\t\t\tthis._lastKnownExternalTimeObtainedAt = timeStamp;\n\t\t\t\tthis._manualClock.tick(currentExternalTime);\n\t\t\t}\n\t\t}\n\n\t\tthis._nextAnimationFrameRequestId = requestAnimationFrame(timeStamp => this._onTimerTick(timeStamp));\n\t}\n\n\tprivate _startTicking(): void {\n\t\tif (this._nextAnimationFrameRequestId === null) {\n\t\t\tthis._nextAnimationFrameRequestId = requestAnimationFrame(timeStamp => this._onTimerTick(timeStamp));\n\t\t}\n\t}\n\n\tprivate _stopTicking(): void {\n\t\tif (this._nextAnimationFrameRequestId !== null) {\n\t\t\tcancelAnimationFrame(this._nextAnimationFrameRequestId);\n\t\t\tthis._nextAnimationFrameRequestId = null;\n\t\t}\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Map } from \"../../utility/map\";\n\n/**\n * A mixin class that represents an event source.\n */\nexport class EventSource<T> {\n\t/**\n\t * A map from event type to an array of all the listeners registered for that event type.\n\t *\n\t * @type {!Map.<T, !Array.<Function>>}\n\t */\n\t_eventListeners: Map<T, Function[]>;\n\n\t/**\n\t * Add a listener for the given event.\n\t *\n\t * @param {!T} type The type of event to attach the listener for\n\t * @param {!Function} listener The listener\n\t */\n\taddEventListener(type: T, listener: Function): void {\n\t\tlet listeners = this._eventListeners.get(type);\n\n\t\tif (listeners === undefined) {\n\t\t\tthis._eventListeners.set(type, listeners = []);\n\t\t}\n\n\t\tlisteners.push(listener);\n\t}\n\n\t/**\n\t * Calls all listeners registered for the given event type.\n\t *\n\t * @param {!T} type The type of event to dispatch\n\t * @param {!Array.<*>} args Arguments for the listeners of the event\n\t */\n\t_dispatchEvent(type: T, args: Object[]): void {\n\t\tconst listeners = this._eventListeners.get(type);\n\t\tif (listeners !== undefined) {\n\t\t\tfor (const listener of listeners) {\n\t\t\t\tlistener.apply(this, args);\n\t\t\t}\n\t\t}\n\t}\n}\n\n/**\n * The type of clock event.\n */\nexport enum ClockEvent {\n\tPlay,\n\tTick,\n\tPause,\n\tStop,\n\tRateChange,\n}\n\n/**\n * The clock interface. A clock is used by a renderer as a source of {@link libjass.renderers.ClockEvent}s.\n */\nexport interface Clock {\n\t/**\n\t * @type {number}\n\t */\n\tcurrentTime: number;\n\n\t/**\n\t * @type {boolean}\n\t */\n\tenabled: boolean;\n\n\t/**\n\t * @type {boolean}\n\t */\n\tpaused: boolean;\n\n\t/**\n\t * Gets the rate of the clock - how fast the clock ticks compared to real time.\n\t *\n\t * @type {number}\n\t */\n\trate: number;\n\n\t/**\n\t * Enable the clock.\n\t *\n\t * @return {boolean} True if the clock is now enabled, false if it was already enabled.\n\t */\n\tenable(): boolean;\n\n\t/**\n\t * Disable the clock.\n\t *\n\t * @return {boolean} True if the clock is now disabled, false if it was already disabled.\n\t */\n\tdisable(): boolean;\n\n\t/**\n\t * Toggle the clock.\n\t */\n\ttoggle(): void;\n\n\t/**\n\t * Enable or disable the clock.\n\t *\n\t * @param {boolean} enabled If true, the clock is enabled, otherwise it's disabled.\n\t * @return {boolean} True if the clock is now in the given state, false if it was already in that state.\n\t */\n\tsetEnabled(enabled: boolean): boolean;\n\n\t// EventSource members\n\n\t/**\n\t * @param {number} type\n\t * @param {!Function} listener\n\t */\n\taddEventListener(type: ClockEvent, listener: Function): void;\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { mixin } from \"../../utility/mixin\";\nimport { Map } from \"../../utility/map\";\n\nimport { Clock, ClockEvent, EventSource } from \"./base\";\n\n/**\n * An implementation of {@link libjass.renderers.Clock} that allows user script to manually trigger {@link libjass.renderers.ClockEvent}s.\n */\nexport class ManualClock implements Clock, EventSource<ClockEvent> {\n\tprivate _currentTime: number = -1;\n\tprivate _rate: number = 1;\n\n\tprivate _enabled: boolean = true;\n\tprivate _paused: boolean = true;\n\n\t/**\n\t * Trigger a {@link libjass.renderers.ClockEvent.Play}\n\t */\n\tplay(): void {\n\t\tif (!this._enabled) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (!this._paused) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._paused = false;\n\n\t\tthis._dispatchEvent(ClockEvent.Play, []);\n\t}\n\n\t/**\n\t * Trigger a {@link libjass.renderers.ClockEvent.Tick} with the given time.\n\t *\n\t * @param {number} currentTime\n\t */\n\ttick(currentTime: number): void {\n\t\tif (!this._enabled) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this._currentTime === currentTime) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.play();\n\n\t\tthis._currentTime = currentTime;\n\t\tthis._dispatchEvent(ClockEvent.Tick, []);\n\t}\n\n\t/**\n\t * Seek to the given time. Unlike {@link libjass.renderers.ManualClock.tick} this is used to represent a discontinuous jump, such as the user seeking\n\t * via the video element's position bar.\n\t *\n\t * @param {number} time\n\t */\n\tseek(time: number): void {\n\t\tif (!this._enabled) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.pause();\n\n\t\tif (this._currentTime === time) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.stop();\n\n\t\tthis.tick(time);\n\n\t\tthis.pause();\n\t}\n\n\t/**\n\t * Trigger a {@link libjass.renderers.ClockEvent.Pause}\n\t */\n\tpause(): void {\n\t\tif (!this._enabled) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this._paused) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._paused = true;\n\n\t\tthis._dispatchEvent(ClockEvent.Pause, []);\n\t}\n\n\t/**\n\t * Trigger a {@link libjass.renderers.ClockEvent.Stop}\n\t */\n\tstop(): void {\n\t\tthis._dispatchEvent(ClockEvent.Stop, []);\n\t}\n\n\t// Clock members\n\n\t/**\n\t * @type {number}\n\t */\n\tget currentTime(): number {\n\t\treturn this._currentTime;\n\t}\n\n\t/**\n\t * @type {boolean}\n\t */\n\tget enabled(): boolean {\n\t\treturn this._enabled;\n\t}\n\n\t/**\n\t * @type {boolean}\n\t */\n\tget paused(): boolean {\n\t\treturn this._paused;\n\t}\n\n\t/**\n\t * Gets the rate of the clock - how fast the clock ticks compared to real time.\n\t *\n\t * @type {number}\n\t */\n\tget rate(): number {\n\t\treturn this._rate;\n\t}\n\n\t/**\n\t * Sets the rate of the clock - how fast the clock ticks compared to real time.\n\t *\n\t * @param {number} rate The new rate of the clock.\n\t */\n\tsetRate(rate: number): void {\n\t\tif (this._rate === rate) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._rate = rate;\n\n\t\tthis._dispatchEvent(ClockEvent.RateChange, []);\n\t}\n\n\t/**\n\t * Enable the clock.\n\t *\n\t * @return {boolean} True if the clock is now enabled, false if it was already enabled.\n\t */\n\tenable(): boolean {\n\t\tif (this._enabled) {\n\t\t\treturn false;\n\t\t}\n\n\t\tthis._enabled = true;\n\n\t\treturn true;\n\t}\n\n\t/**\n\t * Disable the clock.\n\t *\n\t * @return {boolean} True if the clock is now disabled, false if it was already disabled.\n\t */\n\tdisable(): boolean {\n\t\tif (!this._enabled) {\n\t\t\treturn false;\n\t\t}\n\n\t\tthis.pause();\n\n\t\tthis.stop();\n\n\t\tthis._enabled = false;\n\n\t\treturn true;\n\t}\n\n\t/**\n\t * Toggle the clock.\n\t */\n\ttoggle(): void {\n\t\tif (this._enabled) {\n\t\t\tthis.disable();\n\t\t}\n\t\telse {\n\t\t\tthis.enable();\n\t\t}\n\t}\n\n\t/**\n\t * Enable or disable the clock.\n\t *\n\t * @param {boolean} enabled If true, the clock is enabled, otherwise it's disabled.\n\t * @return {boolean} True if the clock is now in the given state, false if it was already in that state.\n\t */\n\tsetEnabled(enabled: boolean): boolean {\n\t\tif (enabled) {\n\t\t\treturn this.enable();\n\t\t}\n\t\telse {\n\t\t\treturn this.disable();\n\t\t}\n\t}\n\n\t// EventSource members\n\n\t/**\n\t * @type {!Map.<T, !Array.<Function>>}\n\t */\n\t_eventListeners: Map<ClockEvent, Function[]> = new Map<ClockEvent, Function[]>();\n\n\t/**\n\t * @type {function(number, !Function)}\n\t */\n\taddEventListener: (type: ClockEvent, listener: Function) => void;\n\n\t/**\n\t * @type {function(number, Array.<*>)}\n\t */\n\t_dispatchEvent: (type: ClockEvent, args: Object[]) => void;\n}\nmixin(ManualClock, [EventSource]);\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { AutoClock } from \"./auto\";\nimport { Clock, ClockEvent } from \"./base\";\n\n/**\n * An implementation of libjass.renderers.Clock that generates {@link libjass.renderers.ClockEvent}s according to the state of a <video> element.\n *\n * @param {!HTMLVideoElement} video\n */\nexport class VideoClock implements Clock {\n\tprivate _autoClock: AutoClock;\n\n\tconstructor(video: HTMLVideoElement) {\n\t\tthis._autoClock = new AutoClock(() => video.currentTime, 100);\n\t\tvideo.addEventListener(\"playing\", () => this._autoClock.play(), false);\n\t\tvideo.addEventListener(\"pause\", () => this._autoClock.pause(), false);\n\t\tvideo.addEventListener(\"seeking\", () => this._autoClock.seeking(), false);\n\t\tvideo.addEventListener(\"ratechange\", () => this._autoClock.setRate(video.playbackRate), false);\n\t}\n\n\t/**\n\t * @type {number}\n\t */\n\tget currentTime(): number {\n\t\treturn this._autoClock.currentTime;\n\t}\n\n\t/**\n\t * @type {boolean}\n\t */\n\tget enabled(): boolean {\n\t\treturn this._autoClock.enabled;\n\t}\n\n\t/**\n\t * @type {boolean}\n\t */\n\tget paused(): boolean {\n\t\treturn this._autoClock.paused;\n\t}\n\n\t/**\n\t * Gets the rate of the clock - how fast the clock ticks compared to real time.\n\t *\n\t * @type {number}\n\t */\n\tget rate(): number {\n\t\treturn this._autoClock.rate;\n\t}\n\n\t/**\n\t * Enable the clock.\n\t *\n\t * @return {boolean} True if the clock is now enabled, false if it was already enabled.\n\t */\n\tenable(): boolean {\n\t\treturn this._autoClock.enable();\n\t}\n\n\t/**\n\t * Disable the clock.\n\t *\n\t * @return {boolean} True if the clock is now disabled, false if it was already disabled.\n\t */\n\tdisable(): boolean {\n\t\treturn this._autoClock.disable();\n\t}\n\n\t/**\n\t * Toggle the clock.\n\t */\n\ttoggle(): void {\n\t\tif (this._autoClock.enabled) {\n\t\t\tthis.disable();\n\t\t}\n\t\telse {\n\t\t\tthis.enable();\n\t\t}\n\t}\n\n\t/**\n\t * Enable or disable the clock.\n\t *\n\t * @param {boolean} enabled If true, the clock is enabled, otherwise it's disabled.\n\t * @return {boolean} True if the clock is now in the given state, false if it was already in that state.\n\t */\n\tsetEnabled(enabled: boolean): boolean {\n\t\tif (enabled) {\n\t\t\treturn this.enable();\n\t\t}\n\t\telse {\n\t\t\treturn this.disable();\n\t\t}\n\t}\n\n\t/**\n\t * @param {number} type\n\t * @param {!Function} listener\n\t */\n\taddEventListener(type: ClockEvent, listener: Function): void {\n\t\tthis._autoClock.addEventListener(type, listener);\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { VideoClock } from \"./clocks/video\";\nimport { RendererSettings } from \"./settings\";\nimport { WebRenderer } from \"./web/renderer\";\n\nimport { ASS } from \"../types/ass\";\n\n/**\n * A default renderer implementation.\n *\n * @param {!HTMLVideoElement} video\n * @param {!libjass.ASS} ass\n * @param {libjass.renderers.RendererSettings} settings\n */\nexport class DefaultRenderer extends WebRenderer {\n\tconstructor(private _video: HTMLVideoElement, ass: ASS, settings?: RendererSettings) {\n\t\tsuper(ass, new VideoClock(_video), document.createElement(\"div\"), settings);\n\n\t\tthis._video.parentElement.replaceChild(this.libjassSubsWrapper, this._video);\n\t\tthis.libjassSubsWrapper.insertBefore(this._video, this.libjassSubsWrapper.firstElementChild);\n\t}\n\n\t/**\n\t * Resize the subtitles to the dimensions of the video element.\n\t *\n\t * This method accounts for letterboxing if the video element's size is not the same ratio as the video resolution.\n\t */\n\tresize(): void {\n\t\t// Handle letterboxing around the video. If the width or height are greater than the video can be, then consider that dead space.\n\n\t\tconst videoWidth = this._video.videoWidth;\n\t\tconst videoHeight = this._video.videoHeight;\n\t\tconst videoOffsetWidth = this._video.offsetWidth;\n\t\tconst videoOffsetHeight = this._video.offsetHeight;\n\n\t\tconst ratio = Math.min(videoOffsetWidth / videoWidth, videoOffsetHeight / videoHeight);\n\t\tconst subsWrapperWidth = videoWidth * ratio;\n\t\tconst subsWrapperHeight = videoHeight * ratio;\n\t\tconst subsWrapperLeft = (videoOffsetWidth - subsWrapperWidth) / 2;\n\t\tconst subsWrapperTop = (videoOffsetHeight - subsWrapperHeight) / 2;\n\n\t\tsuper.resize(subsWrapperWidth, subsWrapperHeight, subsWrapperLeft, subsWrapperTop);\n\t}\n\n\t/**\n\t * @deprecated\n\t */\n\tresizeVideo(): void {\n\t\tconsole.warn(\"`DefaultRenderer.resizeVideo(width, height)` has been deprecated. Use `DefaultRenderer.resize()` instead.\");\n\t\tthis.resize();\n\t}\n\n\tprotected _ready(): void {\n\t\tthis.resize();\n\n\t\tsuper._ready();\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport { Clock, ClockEvent, EventSource } from \"./clocks/base\";\nexport { AutoClock } from \"./clocks/auto\";\nexport { ManualClock } from \"./clocks/manual\";\nexport { VideoClock } from \"./clocks/video\";\n\nexport { DefaultRenderer } from \"./default\";\nexport { NullRenderer } from \"./null\";\nexport { WebRenderer } from \"./web/renderer\";\nexport { RendererSettings } from \"./settings\";\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Clock, ClockEvent } from \"./clocks/base\";\n\nimport { RendererSettings } from \"./settings\";\n\nimport { verboseMode } from \"../settings\";\n\nimport { ASS } from \"../types/ass\";\nimport { Dialogue } from \"../types/dialogue\";\n\n/**\n * A renderer implementation that doesn't output anything.\n *\n * @param {!libjass.ASS} ass\n * @param {!libjass.renderers.Clock} clock\n * @param {libjass.renderers.RendererSettings} settings\n */\nexport class NullRenderer {\n\tprivate static _lastRendererId = -1;\n\n\tprivate _id: number;\n\n\tprivate _settings: RendererSettings;\n\n\tconstructor(private _ass: ASS, private _clock: Clock, settings?: RendererSettings) {\n\t\tthis._id = ++NullRenderer._lastRendererId;\n\n\t\tthis._settings = RendererSettings.from(settings);\n\n\t\tthis._clock.addEventListener(ClockEvent.Play, () => this._onClockPlay());\n\t\tthis._clock.addEventListener(ClockEvent.Tick, () => this._onClockTick());\n\t\tthis._clock.addEventListener(ClockEvent.Pause, () => this._onClockPause());\n\t\tthis._clock.addEventListener(ClockEvent.Stop, () => this._onClockStop());\n\t\tthis._clock.addEventListener(ClockEvent.RateChange, () => this._onClockRateChange());\n\t}\n\n\t/**\n\t * The unique ID of this renderer. Auto-generated.\n\t *\n\t * @type {number}\n\t */\n\tget id(): number {\n\t\treturn this._id;\n\t}\n\n\t/**\n\t * @type {!libjass.ASS}\n\t */\n\tget ass(): ASS {\n\t\treturn this._ass;\n\t}\n\n\t/**\n\t * @type {!libjass.renderers.Clock}\n\t */\n\tget clock(): Clock {\n\t\treturn this._clock;\n\t}\n\n\t/**\n\t * @type {!libjass.renderers.RendererSettings}\n\t */\n\tget settings(): RendererSettings {\n\t\treturn this._settings;\n\t}\n\n\t/**\n\t * Pre-render a dialogue. This is a no-op for this type.\n\t *\n\t * @param {!libjass.Dialogue} dialogue\n\t */\n\tpreRender(dialogue: Dialogue): void { }\n\n\t/**\n\t * Draw a dialogue. This is a no-op for this type.\n\t *\n\t * @param {!libjass.Dialogue} dialogue\n\t */\n\tdraw(dialogue: Dialogue): void { }\n\n\t/**\n\t * Enable the renderer.\n\t *\n\t * @return {boolean} True if the renderer is now enabled, false if it was already enabled.\n\t */\n\tenable(): boolean {\n\t\treturn this._clock.enable();\n\t}\n\n\t/**\n\t * Disable the renderer.\n\t *\n\t * @return {boolean} True if the renderer is now disabled, false if it was already disabled.\n\t */\n\tdisable(): boolean {\n\t\treturn this._clock.disable();\n\t}\n\n\t/**\n\t * Toggle the renderer.\n\t */\n\ttoggle(): void {\n\t\tthis._clock.toggle();\n\t}\n\n\t/**\n\t * Enable or disable the renderer.\n\t *\n\t * @param {boolean} enabled If true, the renderer is enabled, otherwise it's disabled.\n\t * @return {boolean} True if the renderer is now in the given state, false if it was already in that state.\n\t */\n\tsetEnabled(enabled: boolean): boolean {\n\t\treturn this._clock.setEnabled(enabled);\n\t}\n\n\t/**\n\t * @type {boolean}\n\t */\n\tget enabled(): boolean {\n\t\treturn this._clock.enabled;\n\t}\n\n\t/**\n\t * Runs when the clock is enabled, or starts playing, or is resumed from pause.\n\t */\n\tprotected _onClockPlay(): void {\n\t\tif (verboseMode) {\n\t\t\tconsole.log(\"NullRenderer._onClockPlay\");\n\t\t}\n\t}\n\n\t/**\n\t * Runs when the clock's current time changed. This might be a result of either regular playback or seeking.\n\t */\n\tprotected _onClockTick(): void {\n\t\tconst currentTime = this._clock.currentTime;\n\n\t\tif (verboseMode) {\n\t\t\tconsole.log(`NullRenderer._onClockTick: currentTime = ${ currentTime }`);\n\t\t}\n\n\t\tfor (const dialogue of this._ass.dialogues) {\n\t\t\tif (dialogue.end > currentTime) {\n\t\t\t\tif (dialogue.start <= currentTime) {\n\t\t\t\t\t// This dialogue is visible right now. Draw it.\n\t\t\t\t\tthis.draw(dialogue);\n\t\t\t\t}\n\t\t\t\telse if (dialogue.start <= (currentTime + this._settings.preRenderTime)) {\n\t\t\t\t\t// This dialogue will be visible soon. Pre-render it.\n\t\t\t\t\tthis.preRender(dialogue);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t/**\n\t * Runs when the clock is paused.\n\t */\n\tprotected _onClockPause(): void {\n\t\tif (verboseMode) {\n\t\t\tconsole.log(\"NullRenderer._onClockPause\");\n\t\t}\n\t}\n\n\t/**\n\t * Runs when the clock is disabled.\n\t */\n\tprotected _onClockStop(): void {\n\t\tif (verboseMode) {\n\t\t\tconsole.log(\"NullRenderer._onClockStop\");\n\t\t}\n\t}\n\n\t/**\n\t * Runs when the clock changes its rate.\n\t */\n\tprotected _onClockRateChange(): void {\n\t\tif (verboseMode) {\n\t\t\tconsole.log(\"NullRenderer._onClockRateChange\");\n\t\t}\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Map } from \"../utility/map\";\n\n/**\n * Settings for the renderer.\n */\nexport class RendererSettings {\n\t/**\n\t * A map of font name to one or more URLs of that font. If provided, the fonts in this map are pre-loaded by the WebRenderer when it's created.\n\t *\n\t * The key of each entry of the map is the font name used in the ASS script. There are three choices for the value:\n\t *\n\t * - A single string that you would use for the src attribute of a @font-face rule. Eg: `'url(\"/fonts.foo.ttf\"), url(\"/fonts/foo-fallback.ttf\"), local(\"Arial.ttf\")'`\n\t *\n\t * - An array of the individual sources that you would use for the src attribute of a @font-face rule. Eg: `['url(\"/fonts.foo.ttf\")', 'url(\"/fonts/foo-fallback.ttf\")', 'local(\"Arial\")']`\n\t *\n\t * - An array of URLs. Eg: `[\"/fonts.foo.ttf\", \"/fonts/foo-fallback.ttf\"]`\n\t *\n\t * Only the first and second forms allow you to use local fonts. The third form only allows you to use remote fonts.\n\t *\n\t * If you have a <style> or <link> element on the page containing @font-face rules, you can use the {@link libjass.renderers.RendererSettings.makeFontMapFromStyleElement}\n\t * convenience method to create a font map.\n\t *\n\t * Defaults to null.\n\t *\n\t * @type {!Map.<string, (string|!Array.<string>)>}\n\t */\n\tfontMap: Map<string, string | string[]>;\n\n\t/**\n\t * Subtitles will be pre-rendered for this amount of time (seconds).\n\t *\n\t * Defaults to 5.\n\t *\n\t * @type {number}\n\t */\n\tpreRenderTime: number;\n\n\t/**\n\t * Subtitle outlines will be rendered in full detail. When false, the value of blur is used to draw less outlines for better performance and (hopefully) similar output.\n\t *\n\t * Defaults to false.\n\t *\n\t * @type {boolean}\n\t */\n\tpreciseOutlines: boolean;\n\n\t/**\n\t * Outlines and blur are implemented using SVG filters by default. When false, they will be rendered using alternative means.\n\t *\n\t * IE 11 and below do not support SVG filters on HTML elements so this should be set to false there. See http://caniuse.com/svg-html for details.\n\t *\n\t * Defaults to true.\n\t *\n\t * @type {boolean}\n\t */\n\tenableSvg: boolean;\n\n\t/**\n\t * Comma-separated list of fonts to be used when font specified in ASS Styles not loaded.\n\t *\n\t * The value should be a valid CSS font-family property (i.e. comma-separated and individual names in quotes if necessary). Use empty string to disable fallback.\n\t *\n\t * Defaults to 'Arial, Helvetica, sans-serif, \"Segoe UI Symbol\"'.\n\t *\n\t * @type {string}\n\t */\n\tfallbackFonts: string;\n\n\t/**\n\t * If true, attached TTF fonts in the ASS script will be used. The font is loaded as a data: URI. Requires ES6 typed arrays (ArrayBuffer, DataView, Uint8Array, etc).\n\t *\n\t * The font is naively parsed to extract the strings that will be used as the font family. Do not use this option with untrusted fonts or scripts.\n\t *\n\t * Defaults to false.\n\t *\n\t * @type {boolean}\n\t */\n\tuseAttachedFonts: boolean;\n\n\t/**\n\t * A convenience method to create a font map from a <style> or <link> element that contains @font-face rules. There should be one @font-face rule for each font name, mapping to a font file URL.\n\t *\n\t * For example:\n\t *\n\t * @font-face {\n\t * font-family: \"Helvetica\";\n\t * src: url(\"/fonts/helvetica.ttf\"), local(\"Arial\");\n\t * }\n\t *\n\t * @param {!LinkStyle} linkStyle\n\t * @return {!Map.<string, string>}\n\t */\n\tstatic makeFontMapFromStyleElement(linkStyle: LinkStyle): Map<string, string> {\n\t\tconst fontMap = new Map<string, string>();\n\n\t\tconst styleSheet = <CSSStyleSheet>linkStyle.sheet;\n\t\tfor (let i = 0; i < styleSheet.cssRules.length; i++) {\n\t\t\tconst rule = styleSheet.cssRules[i];\n\n\t\t\tif (isFontFaceRule(rule)) {\n\t\t\t\tconst name = rule.style.getPropertyValue(\"font-family\").match(/^[\"']?(.*?)[\"']?$/)[1];\n\n\t\t\t\tlet src = rule.style.getPropertyValue(\"src\");\n\t\t\t\tif (!src) {\n\t\t\t\t\tsrc = rule.cssText.split(\"\\n\")\n\t\t\t\t\t\t.map(line => line.match(/src:\\s*([^;]+?)\\s*;/))\n\t\t\t\t\t\t.filter(matches => matches !== null)\n\t\t\t\t\t\t.map(matches => matches[1])[0];\n\t\t\t\t}\n\n\t\t\t\tfontMap.set(name, src);\n\t\t\t}\n\t\t}\n\n\t\treturn fontMap;\n\t}\n\n\t/**\n\t * Converts an arbitrary object into a {@link libjass.renderers.RendererSettings} object.\n\t *\n\t * @param {*} object\n\t * @return {!libjass.renderers.RendererSettings}\n\t */\n\tstatic from(object?: any): RendererSettings {\n\t\tif (object === undefined || object === null) {\n\t\t\tobject = {};\n\t\t}\n\n\t\tconst { fontMap = null, preRenderTime = 5, preciseOutlines = false, enableSvg = true, fallbackFonts = 'Arial, Helvetica, sans-serif, \"Segoe UI Symbol\"', useAttachedFonts = false } = <RendererSettings>object;\n\t\tconst result = new RendererSettings();\n\t\tresult.fontMap = fontMap;\n\t\tresult.preRenderTime = preRenderTime;\n\t\tresult.preciseOutlines = preciseOutlines;\n\t\tresult.enableSvg = enableSvg;\n\t\tresult.fallbackFonts = fallbackFonts;\n\t\tresult.useAttachedFonts = useAttachedFonts;\n\n\t\treturn result;\n\t}\n}\n\n/**\n * @param {!CSSRule} rule\n * @return {boolean}\n */\nfunction isFontFaceRule(rule: CSSRule): rule is CSSFontFaceRule {\n\treturn rule.type === CSSRule.FONT_FACE_RULE;\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Keyframe } from \"./keyframe\";\n\nimport { NullRenderer } from \"../null\";\n\nimport { Map } from \"../../utility/map\";\n\n/**\n * This class represents a collection of animations. Each animation contains one or more keyframes.\n * The collection can then be converted to a CSS3 representation.\n *\n * @param {!libjass.renderers.NullRenderer} renderer The renderer that this collection is associated with\n * @param {!HTMLStyleElement} style A <style> element to insert the animation rules into\n */\nexport class AnimationCollection {\n\tprivate static _nextId: number = 0;\n\n\tprivate _id: string;\n\tprivate _rate: number;\n\n\tprivate _animationStyle: string = \"\";\n\tprivate _animationDelays: Map<string, number> = new Map<string, number>();\n\tprivate _numAnimations: number = 0;\n\n\tconstructor(renderer: NullRenderer, private _style: HTMLStyleElement) {\n\t\tthis._id = `${ renderer.id }-${ AnimationCollection._nextId++ }`;\n\t\tthis._rate = renderer.clock.rate;\n\t}\n\n\t/**\n\t * This string should be set as the \"animation\" CSS property of the target element.\n\t *\n\t * @type {string}\n\t */\n\tget animationStyle(): string {\n\t\treturn this._animationStyle;\n\t}\n\n\t/**\n\t * This array should be used to set the \"animation-delay\" CSS property of the target element.\n\t *\n\t * @type {!Array.<number>}\n\t */\n\tget animationDelays(): Map<string, number> {\n\t\treturn this._animationDelays;\n\t}\n\n\t/**\n\t * Add an animation to this collection. The given keyframes together make one animation.\n\t *\n\t * @param {string} timingFunction One of the acceptable values for the \"animation-timing-function\" CSS property\n\t * @param {!Array.<!libjass.renderers.Keyframe>} keyframes\n\t */\n\tadd(timingFunction: string, keyframes: Keyframe[]): void {\n\t\tlet start: number = null;\n\t\tlet end: number = null;\n\n\t\tfor (const keyframe of keyframes) {\n\t\t\tif (start === null) {\n\t\t\t\tstart = keyframe.time;\n\t\t\t}\n\n\t\t\tend = keyframe.time;\n\t\t}\n\n\t\tlet ruleCssText = \"\";\n\n\t\tfor (const keyframe of keyframes) {\n\t\t\truleCssText +=\n`\t${ (100 * ((end - start === 0) ? 1 : ((keyframe.time - start) / (end - start)))).toFixed(3) }% {\n`;\n\n\t\t\tkeyframe.properties.forEach((value, name) => {\n\t\t\t\truleCssText +=\n`\t\t${ name }: ${ value };\n`;\n\t\t\t});\n\n\t\t\truleCssText +=\n`\t}\n`;\n\t\t}\n\n\t\tconst animationName = `animation-${ this._id }-${ this._numAnimations++ }`;\n\n\t\tthis._style.appendChild(document.createTextNode(\n`@-webkit-keyframes ${ animationName } {\n${ ruleCssText }\n}`));\n\n\t\tthis._style.appendChild(document.createTextNode(\n`@keyframes ${ animationName } {\n${ ruleCssText }\n}`));\n\n\t\tif (this._animationStyle !== \"\") {\n\t\t\tthis._animationStyle += \",\";\n\t\t}\n\n\t\tthis._animationStyle += `${ animationName } ${ ((end - start) / this._rate).toFixed(3) }s ${ timingFunction }`;\n\t\tthis._animationDelays.set(animationName, start);\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as parts from \"../../parts\";\n\n/**\n * This class represents an ASS drawing - a set of drawing instructions between {\\p} tags.\n *\n * @param {number} outputScaleX\n * @param {number} outputScaleY\n */\nexport class DrawingStyles {\n\tprivate _scale: number = 1;\n\tprivate _baselineOffset: number = 0;\n\n\tconstructor(private _outputScaleX: number, private _outputScaleY: number) { }\n\n\t/**\n\t * @type {number}\n\t */\n\tset scale(value: number) {\n\t\tthis._scale = value;\n\t}\n\n\t/**\n\t * @type {number}\n\t */\n\tset baselineOffset(value: number) {\n\t\tthis._baselineOffset = value;\n\t}\n\n\t/**\n\t * Converts this drawing to an <svg> element.\n\t *\n\t * @param {!libjass.parts.DrawingInstructions} drawingInstructions\n\t * @param {!libjass.parts.Color} fillColor\n\t * @return {!SVGSVGElement}\n\t */\n\ttoSVG(drawingInstructions: parts.DrawingInstructions, fillColor: parts.Color): SVGSVGElement {\n\t\tconst scaleFactor = Math.pow(2, this._scale - 1);\n\t\tconst scaleX = this._outputScaleX / scaleFactor;\n\t\tconst scaleY = this._outputScaleY / scaleFactor;\n\n\t\tconst path = document.createElementNS(\"http://www.w3.org/2000/svg\", \"path\");\n\n\t\tlet bboxWidth = 0;\n\t\tlet bboxHeight = 0;\n\n\t\tfor (const instruction of drawingInstructions.instructions) {\n\t\t\tif (instruction instanceof parts.drawing.MoveInstruction) {\n\t\t\t\tpath.pathSegList.appendItem(path.createSVGPathSegMovetoAbs(instruction.x, instruction.y + this._baselineOffset));\n\t\t\t\tbboxWidth = Math.max(bboxWidth, instruction.x);\n\t\t\t\tbboxHeight = Math.max(bboxHeight, instruction.y + this._baselineOffset);\n\t\t\t}\n\t\t\telse if (instruction instanceof parts.drawing.LineInstruction) {\n\t\t\t\tpath.pathSegList.appendItem(path.createSVGPathSegLinetoAbs(instruction.x, instruction.y + this._baselineOffset));\n\t\t\t\tbboxWidth = Math.max(bboxWidth, instruction.x);\n\t\t\t\tbboxHeight = Math.max(bboxHeight, instruction.y + this._baselineOffset);\n\t\t\t}\n\t\t\telse if (instruction instanceof parts.drawing.CubicBezierCurveInstruction) {\n\t\t\t\tpath.pathSegList.appendItem(path.createSVGPathSegCurvetoCubicAbs(instruction.x3, instruction.y3 + this._baselineOffset, instruction.x1, instruction.y1 + this._baselineOffset, instruction.x2, instruction.y2 + this._baselineOffset));\n\t\t\t\tbboxWidth = Math.max(bboxWidth, instruction.x1, instruction.x2, instruction.x3);\n\t\t\t\tbboxHeight = Math.max(bboxHeight, instruction.y1 + this._baselineOffset, instruction.y2 + this._baselineOffset, instruction.y3 + this._baselineOffset);\n\t\t\t}\n\t\t}\n\n\t\tconst svg = document.createElementNS(\"http://www.w3.org/2000/svg\", \"svg\");\n\t\tsvg.setAttribute(\"version\", \"1.1\");\n\t\tsvg.width.baseVal.valueAsString = `${ (bboxWidth * scaleX).toFixed(3) }px`;\n\t\tsvg.height.baseVal.valueAsString = `${ (bboxHeight * scaleY).toFixed(3) }px`;\n\n\t\tconst g = document.createElementNS(\"http://www.w3.org/2000/svg\", \"g\");\n\t\tsvg.appendChild(g);\n\t\tg.setAttribute(\"transform\", `scale(${ scaleX.toFixed(3) } ${ scaleY.toFixed(3) })`);\n\n\t\tg.appendChild(path);\n\t\tpath.setAttribute(\"fill\", fillColor.toString());\n\n\t\treturn svg;\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Map } from \"../../utility/map\";\nimport { Promise } from \"../../utility/promise\";\n\n/**\n * @param {string} fontFamily\n * @param {number} fontSize\n * @param {string} fallbackFonts\n * @param {!HTMLDivElement} fontSizeElement\n */\nfunction prepareFontSizeElement(fontFamily: string, fontSize: number, fallbackFonts: string, fontSizeElement: HTMLDivElement): void {\n\tlet fonts = `\"${ fontFamily }\"`;\n\tif (fallbackFonts !== \"\") {\n\t\tfonts += `, ${ fallbackFonts }`;\n\t}\n\n\tfontSizeElement.style.fontFamily = fonts;\n\tfontSizeElement.style.fontSize = `${ fontSize }px`;\n}\n\n/**\n * @param {string} fontFamily\n * @param {number} fontSize\n * @param {string} fallbackFonts\n * @param {!HTMLDivElement} fontSizeElement\n * @return {!Promise.<number>}\n */\nfunction lineHeightForFontSize(fontFamily: string, fontSize: number, fallbackFonts: string, fontSizeElement: HTMLDivElement): Promise<number> {\n\tprepareFontSizeElement(fontFamily, fontSize, fallbackFonts, fontSizeElement);\n\n\treturn new Promise(resolve => setTimeout(() => resolve(fontSizeElement.offsetHeight), 1000));\n}\n\n/**\n * @param {string} fontFamily\n * @param {number} fontSize\n * @param {string} fallbackFonts\n * @param {!HTMLDivElement} fontSizeElement\n * @return {number}\n */\nfunction lineHeightForFontSizeSync(fontFamily: string, fontSize: number, fallbackFonts: string, fontSizeElement: HTMLDivElement): number {\n\tprepareFontSizeElement(fontFamily, fontSize, fallbackFonts, fontSizeElement);\n\n\treturn fontSizeElement.offsetHeight;\n}\n\n/**\n * @param {number} lowerLineHeight\n * @param {number} upperLineHeight\n * @return {[number, number]}\n */\nfunction fontMetricsFromLineHeights(lowerLineHeight: number, upperLineHeight: number): [number, number] {\n\treturn [lowerLineHeight, (360 - 180) / (upperLineHeight - lowerLineHeight)];\n}\n\n/**\n * Calculates font metrics for the given font family.\n *\n * @param {string} fontFamily\n * @param {string} fallbackFonts\n * @param {!HTMLDivElement} fontSizeElement\n * @return {!Promise.<number>}\n */\nexport function calculateFontMetrics(fontFamily: string, fallbackFonts: string, fontSizeElement: HTMLDivElement): Promise<[number, number]> {\n\treturn lineHeightForFontSize(fontFamily, 180, fallbackFonts, fontSizeElement).then(lowerLineHeight =>\n\t\tlineHeightForFontSize(fontFamily, 360, fallbackFonts, fontSizeElement).then(upperLineHeight =>\n\t\t\tfontMetricsFromLineHeights(lowerLineHeight, upperLineHeight)\n\t\t)\n\t);\n}\n\n/**\n * @param {number} lineHeight\n * @param {number} lowerLineHeight\n * @param {number} factor\n * @return {number}\n */\nfunction fontSizeFromMetrics(lineHeight: number, lowerLineHeight: number, factor: number): number {\n\treturn 180 + (lineHeight - lowerLineHeight) * factor;\n}\n\n/**\n * Uses linear interpolation to calculate the CSS font size that would give the specified line height for the specified font family.\n *\n * WARNING: If fontMetricsCache doesn't already contain a cached value for this font family, and it is not a font already installed on the user's device, then this function\n * may return wrong values. To avoid this, make sure to preload the font using the {@link libjass.renderers.RendererSettings.fontMap} property when constructing the renderer.\n *\n * @param {string} fontFamily\n * @param {number} lineHeight\n * @param {string} fallbackFonts\n * @param {!HTMLDivElement} fontSizeElement\n * @param {!Map.<string, [number, number]>} fontMetricsCache\n * @return {number}\n */\nexport function fontSizeForLineHeight(fontFamily: string, lineHeight: number, fallbackFonts: string, fontSizeElement: HTMLDivElement, fontMetricsCache: Map<string, [number, number]>): number {\n\tlet existingMetrics = fontMetricsCache.get(fontFamily);\n\tif (existingMetrics === undefined) {\n\t\tconst lowerLineHeight = lineHeightForFontSizeSync(fontFamily, 180, fallbackFonts, fontSizeElement);\n\t\tconst upperLineHeight = lineHeightForFontSizeSync(fontFamily, 360, fallbackFonts, fontSizeElement);\n\t\tfontMetricsCache.set(fontFamily, existingMetrics = fontMetricsFromLineHeights(lowerLineHeight, upperLineHeight));\n\t}\n\n\tconst [lowerLineHeight, factor] = existingMetrics;\n\treturn fontSizeFromMetrics(lineHeight, lowerLineHeight, factor);\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Map } from \"../../utility/map\";\n\n/**\n * This class represents a single keyframe. It has a list of CSS properties (names and values) associated with a point in time. Multiple keyframes make up an animation.\n *\n * @param {number} time\n * @param {!Map.<string, string>} properties\n */\nexport class Keyframe {\n\tconstructor(private _time: number, private _properties: Map<string, string>) { }\n\n\t/**\n\t * @type {number}\n\t */\n\tget time(): number {\n\t\treturn this._time;\n\t}\n\n\t/**\n\t * @type {!Map.<string, string>}\n\t */\n\tget properties(): Map<string, string> {\n\t\treturn this._properties;\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { AnimationCollection } from \"./animation-collection\";\nimport { DrawingStyles } from \"./drawing-styles\";\nimport { calculateFontMetrics } from \"./font-size\";\nimport { Keyframe } from \"./keyframe\";\nimport { SpanStyles } from \"./span-styles\";\n\nimport { Clock, EventSource } from \"../clocks/base\";\n\nimport { NullRenderer } from \"../null\";\nimport { RendererSettings } from \"../settings\";\n\nimport { getTtfNames } from \"../../parser/ttf\";\n\nimport * as parts from \"../../parts\";\n\nimport { debugMode } from \"../../settings\";\n\nimport { ASS } from \"../../types/ass\";\nimport { AttachmentType } from \"../../types/attachment\";\nimport { Dialogue } from \"../../types/dialogue\";\nimport { WrappingStyle } from \"../../types/misc\";\n\nimport { mixin } from \"../../utility/mixin\";\nimport { Map } from \"../../utility/map\";\nimport { Promise, any as Promise_any, first as Promise_first, lastly as Promise_finally } from \"../../utility/promise\";\nimport { Set } from \"../../utility/set\";\n\ndeclare const global: {\n\tdocument: {\n\t\tfonts?: FontFaceSet;\n\t};\n};\n\ninterface FontFaceSet {\n\t/**\n\t * @param {!FontFace} fontFace\n\t * @return {!FontFaceSet}\n\t */\n\tadd(fontFace: FontFace): FontFaceSet;\n\n\t/**\n\t * @param {function(!FontFace, !FontFace, !FontFaceSet)} callbackfn A function that is called with each value in the set.\n\t * @param {*} thisArg\n\t */\n\tforEach(callbackfn: (fontFace: FontFace, index: FontFace, set: FontFaceSet) => void, thisArg?: any): void;\n}\n\ninterface FontFace {\n\t/** @type {string} */\n\tfamily: string;\n\n\t/**\n\t * @return {!Promise.<!FontFace>}\n\t */\n\tload(): Promise<FontFace>;\n}\n\ndeclare var FontFace: {\n\tnew (family: string, source: string): FontFace;\n};\n\nconst fontSrcUrlRegex = /^(url|local)\\([\"']?(.+?)[\"']?\\)$/;\n\n/**\n * A renderer implementation that draws subtitles to the given <div>\n *\n * After the renderer fires its ready event, {@link libjass.renderers.WebRenderer.resize} must be called to initialize its size before starting the clock.\n *\n * @param {!libjass.ASS} ass\n * @param {!libjass.renderers.Clock} clock\n * @param {!HTMLDivElement} libjassSubsWrapper Subtitles will be rendered to this <div>\n * @param {!libjass.renderers.RendererSettings} settings\n */\nexport class WebRenderer extends NullRenderer implements EventSource<string> {\n\tprivate _subsWrapper: HTMLDivElement;\n\tprivate _subsWrapperWidth: number; // this._subsWrapper.offsetWidth is expensive, so cache this.\n\n\tprivate _layerWrappers: HTMLDivElement[] = [];\n\tprivate _layerAlignmentWrappers: HTMLDivElement[][] = [];\n\tprivate _fontSizeElement: HTMLDivElement;\n\n\tprivate _fontMetricsCache: Map<string, [number, number]> = new Map<string, [number, number]>();\n\n\tprivate _currentSubs: Map<Dialogue, HTMLDivElement> = new Map<Dialogue, HTMLDivElement>();\n\tprivate _preRenderedSubs: Map<number, PreRenderedSub> = new Map<number, PreRenderedSub>();\n\n\tprivate _scaleX: number;\n\tprivate _scaleY: number;\n\n\tconstructor(ass: ASS, clock: Clock, private _libjassSubsWrapper: HTMLDivElement, settings?: RendererSettings) {\n\t\tsuper(ass, clock, (() => {\n\t\t\tif (!(_libjassSubsWrapper instanceof HTMLDivElement)) {\n\t\t\t\tconst temp = settings;\n\t\t\t\tsettings = <any>_libjassSubsWrapper;\n\t\t\t\t_libjassSubsWrapper = <any>temp;\n\t\t\t\tconsole.warn(\"WebRenderer's constructor now takes libjassSubsWrapper as the third parameter and settings as the fourth parameter. Please update the caller.\");\n\t\t\t}\n\n\t\t\treturn settings;\n\t\t})());\n\n\t\tthis._libjassSubsWrapper.classList.add(\"libjass-wrapper\");\n\n\t\tthis._subsWrapper = document.createElement(\"div\");\n\t\tthis._libjassSubsWrapper.appendChild(this._subsWrapper);\n\t\tthis._subsWrapper.className = \"libjass-subs\";\n\n\t\tthis._fontSizeElement = document.createElement(\"div\");\n\t\tthis._libjassSubsWrapper.appendChild(this._fontSizeElement);\n\t\tthis._fontSizeElement.className = \"libjass-font-measure\";\n\t\tthis._fontSizeElement.appendChild(document.createTextNode(\"M\"));\n\n\t\t// Preload fonts\n\n\t\tif (debugMode) {\n\t\t\tconsole.log(`Preloading fonts...`);\n\t\t}\n\n\t\tconst preloadFontPromises: Promise<any>[] = [];\n\n\t\tconst fontFetchPromisesCache = new Map<string, Promise<any>>();\n\n\t\tconst fontMap = (this.settings.fontMap === null) ? new Map<string, string | string[]>() : this.settings.fontMap;\n\n\t\tconst attachedFontsMap = new Map<string, string[]>();\n\t\tif (this.settings.useAttachedFonts) {\n\t\t\tass.attachments.forEach(attachment => {\n\t\t\t\tif (attachment.type !== AttachmentType.Font) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tlet ttfNames: Set<string> = null;\n\t\t\t\ttry {\n\t\t\t\t\tttfNames = getTtfNames(attachment);\n\t\t\t\t}\n\t\t\t\tcatch (ex) {\n\t\t\t\t\tconsole.error(ex);\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tconst attachmentUrl = `data:application/x-font-ttf;base64,${ attachment.contents }`;\n\n\t\t\t\tttfNames.forEach(name => {\n\t\t\t\t\tlet correspondingFontMapEntry = fontMap.get(name);\n\t\t\t\t\tif (correspondingFontMapEntry !== undefined) {\n\t\t\t\t\t\t// Also defined in fontMap.\n\t\t\t\t\t\tif (typeof correspondingFontMapEntry !== \"string\") {\n\t\t\t\t\t\t\t// Entry in fontMap is an array. Append this URL to it.\n\t\t\t\t\t\t\tcorrespondingFontMapEntry.push(attachmentUrl);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t/* The entry in fontMap is a string. Don't append this URL to it. Instead, put it in attachedFontsMap now\n\t\t\t\t\t\t\t * and it'll be merged with the entry from fontMap later. If it was added here, and later the string needed\n\t\t\t\t\t\t\t * to be split on commas, then the commas in the data URI would break the result.\n\t\t\t\t\t\t\t */\n\t\t\t\t\t\t\tlet existingList = attachedFontsMap.get(name);\n\t\t\t\t\t\t\tif (existingList === undefined) {\n\t\t\t\t\t\t\t\tattachedFontsMap.set(name, existingList = []);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\texistingList.push(attachmentUrl);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\t// Not defined in fontMap. Add it there.\n\t\t\t\t\t\tfontMap.set(name, [attachmentUrl]);\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t});\n\t\t}\n\n\t\tfontMap.forEach((srcs, fontFamily) => {\n\t\t\tlet fontFamilyMetricsPromise: Promise<[number, number]>;\n\n\t\t\tif (global.document.fonts && global.document.fonts.add) {\n\t\t\t\t// value should be string. If it's string[], combine it into string\n\t\t\t\tlet source =\n\t\t\t\t\t(typeof srcs === \"string\") ?\n\t\t\t\t\t\tsrcs :\n\t\t\t\t\t\tsrcs.map(src =>\n\t\t\t\t\t\t\t(src.match(fontSrcUrlRegex) !== null) ?\n\t\t\t\t\t\t\t\tsrc :\n\t\t\t\t\t\t\t\t`url(\"${ src }\")`).join(\", \");\n\n\t\t\t\tconst attachedFontUrls = attachedFontsMap.get(fontFamily);\n\t\t\t\tif (attachedFontUrls !== undefined) {\n\t\t\t\t\tfor (const url of attachedFontUrls) {\n\t\t\t\t\t\tsource += `, url(\"${ url }\")`;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tlet existingFontFaces: FontFace[] = [];\n\t\t\t\tglobal.document.fonts.forEach(fontFace => {\n\t\t\t\t\tif (fontFace.family === fontFamily || fontFace.family === `\"${ fontFamily }\"`) {\n\t\t\t\t\t\texistingFontFaces.push(fontFace);\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tlet fontFetchPromise: Promise<FontFace>;\n\t\t\t\tif (existingFontFaces.length === 0) {\n\t\t\t\t\tconst fontFace = new FontFace(fontFamily, source);\n\t\t\t\t\tconst quotedFontFace = new FontFace(`\"${ fontFamily }\"`, source);\n\n\t\t\t\t\tglobal.document.fonts.add(fontFace);\n\t\t\t\t\tglobal.document.fonts.add(quotedFontFace);\n\n\t\t\t\t\tfontFetchPromise = Promise_any([fontFace.load(), quotedFontFace.load()])\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tfontFetchPromise = Promise_any(existingFontFaces.map(fontFace => fontFace.load()));\n\t\t\t\t}\n\n\t\t\t\tfontFamilyMetricsPromise = this._calculateFontMetricsAfterFetch(fontFamily, fontFetchPromise.catch(reason => {\n\t\t\t\t\tconsole.warn(`Fetching fonts for ${ fontFamily } at ${ source } failed: %o`, reason);\n\t\t\t\t\treturn null;\n\t\t\t\t}));\n\t\t\t}\n\t\t\telse {\n\t\t\t\t// value should be string[]. If it's string, split it into string[]\n\t\t\t\tlet urls =\n\t\t\t\t\t((typeof srcs === \"string\") ?\n\t\t\t\t\t\tsrcs.split(/,/) :\n\t\t\t\t\t\tsrcs).map(url => url.trim()).map(url => {\n\t\t\t\t\t\t\tconst match = url.match(fontSrcUrlRegex);\n\n\t\t\t\t\t\t\tif (match === null) {\n\t\t\t\t\t\t\t\t// A URL\n\t\t\t\t\t\t\t\treturn url;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (match[1] === \"local\") {\n\t\t\t\t\t\t\t\t// A local() URL. Don't fetch it.\n\t\t\t\t\t\t\t\treturn null;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// A url() URL. Extract the raw URL.\n\t\t\t\t\t\t\treturn match[2];\n\t\t\t\t\t\t}).filter(url => url !== null);\n\n\t\t\t\tconst attachedFontUrls = attachedFontsMap.get(fontFamily);\n\t\t\t\tif (attachedFontUrls !== undefined) {\n\t\t\t\t\turls = urls.concat(attachedFontUrls);\n\t\t\t\t}\n\n\t\t\t\tconst thisFontFamilysFetchPromises =\n\t\t\t\t\turls.map(url => {\n\t\t\t\t\t\tlet fontFetchPromise = fontFetchPromisesCache.get(url);\n\t\t\t\t\t\tif (fontFetchPromise === undefined) {\n\t\t\t\t\t\t\tfontFetchPromise =\n\t\t\t\t\t\t\t\tnew Promise<void>((resolve, reject) => {\n\t\t\t\t\t\t\t\t\tconst xhr = new XMLHttpRequest();\n\t\t\t\t\t\t\t\t\txhr.addEventListener(\"load\", () => {\n\t\t\t\t\t\t\t\t\t\tif (debugMode) {\n\t\t\t\t\t\t\t\t\t\t\tconsole.log(`Preloaded ${ url }.`);\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\tresolve(null);\n\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\txhr.addEventListener(\"error\", err => {\n\t\t\t\t\t\t\t\t\t\treject(err);\n\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\txhr.open(\"GET\", url, true);\n\t\t\t\t\t\t\t\t\txhr.send();\n\t\t\t\t\t\t\t\t});\n\n\t\t\t\t\t\t\tfontFetchPromisesCache.set(url, fontFetchPromise);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\treturn fontFetchPromise;\n\t\t\t\t\t});\n\n\t\t\t\tconst allFontsFetchedPromise =\n\t\t\t\t\t(thisFontFamilysFetchPromises.length === 0) ?\n\t\t\t\t\t\tPromise.resolve<void>(null) :\n\t\t\t\t\t\tPromise_first(thisFontFamilysFetchPromises).catch(reason => {\n\t\t\t\t\t\t\tconsole.warn(`Fetching fonts for ${ fontFamily } at ${ urls.join(\", \") } failed: %o`, reason);\n\t\t\t\t\t\t\treturn null;\n\t\t\t\t\t\t});\n\n\t\t\t\tfontFamilyMetricsPromise = this._calculateFontMetricsAfterFetch(fontFamily, allFontsFetchedPromise);\n\t\t\t}\n\n\t\t\tpreloadFontPromises.push(fontFamilyMetricsPromise.then(metrics => this._fontMetricsCache.set(fontFamily, metrics)));\n\t\t});\n\n\t\tPromise.all(preloadFontPromises).then(() => {\n\t\t\tif (debugMode) {\n\t\t\t\tconsole.log(\"All fonts have been preloaded.\");\n\t\t\t}\n\n\t\t\tthis._ready();\n\t\t});\n\t}\n\n\t/**\n\t * @type {!HTMLDivElement}\n\t */\n\tget libjassSubsWrapper(): HTMLDivElement {\n\t\treturn this._libjassSubsWrapper;\n\t}\n\n\t/**\n\t * Resize the subtitles to the given new dimensions.\n\t *\n\t * @param {number} width\n\t * @param {number} height\n\t * @param {number=0} left\n\t * @param {number=0} top\n\t */\n\tresize(width: number, height: number, left: number = 0, top: number = 0): void {\n\t\tthis._removeAllSubs();\n\n\t\tthis._subsWrapper.style.width = `${ width.toFixed(3) }px`;\n\t\tthis._subsWrapper.style.height = `${ height.toFixed(3) }px`;\n\t\tthis._subsWrapper.style.left = `${ left.toFixed(3) }px`;\n\t\tthis._subsWrapper.style.top = `${ top.toFixed(3) }px`;\n\n\t\tthis._subsWrapperWidth = width;\n\n\t\tthis._scaleX = width / this.ass.properties.resolutionX;\n\t\tthis._scaleY = height / this.ass.properties.resolutionY;\n\n\t\t// Any dialogues which have been pre-rendered will need to be pre-rendered again.\n\t\tthis._preRenderedSubs.clear();\n\n\t\t// this.currentTime will be -1 if resize() is called before the clock begins playing for the first time. In this situation, there is no need to force a redraw.\n\t\tif (this.clock.currentTime !== -1) {\n\t\t\tthis._onClockTick();\n\t\t}\n\t}\n\n\t/**\n\t * The magic happens here. The subtitle div is rendered and stored. Call {@link libjass.renderers.WebRenderer.draw} to get a clone of the div to display.\n\t *\n\t * @param {!libjass.Dialogue} dialogue\n\t * @return {PreRenderedSub}\n\t */\n\tpreRender(dialogue: Dialogue): PreRenderedSub {\n\t\tconst alreadyPreRenderedSub = this._preRenderedSubs.get(dialogue.id);\n\t\tif (alreadyPreRenderedSub) {\n\t\t\treturn alreadyPreRenderedSub;\n\t\t}\n\n\t\tconst currentTimeRelativeToDialogueStart = this.clock.currentTime - dialogue.start;\n\n\t\tif (dialogue.containsTransformTag && currentTimeRelativeToDialogueStart < 0) {\n\t\t\t// draw() expects this function to always return non-null, but it only calls this function when currentTimeRelativeToDialogueStart would be >= 0\n\t\t\treturn null;\n\t\t}\n\n\t\tconst sub = document.createElement(\"div\");\n\n\t\tsub.style.marginLeft = `${ (this._scaleX * dialogue.style.marginLeft).toFixed(3) }px`;\n\t\tsub.style.marginRight = `${ (this._scaleX * dialogue.style.marginRight).toFixed(3) }px`;\n\t\tsub.style.marginTop = sub.style.marginBottom = `${ (this._scaleY * dialogue.style.marginVertical).toFixed(3) }px`;\n\t\tsub.style.minWidth = `${ (this._subsWrapperWidth - this._scaleX * (dialogue.style.marginLeft + dialogue.style.marginRight)).toFixed(3) }px`;\n\n\t\tconst dialogueAnimationStylesElement = document.createElement(\"style\");\n\t\tdialogueAnimationStylesElement.id = `libjass-animation-styles-${ this.id }-${ dialogue.id }`;\n\t\tdialogueAnimationStylesElement.type = \"text/css\";\n\n\t\tconst dialogueAnimationCollection = new AnimationCollection(this, dialogueAnimationStylesElement);\n\n\t\tconst svgElement = document.createElementNS(\"http://www.w3.org/2000/svg\", \"svg\");\n\t\tsvgElement.setAttribute(\"version\", \"1.1\");\n\t\tsvgElement.setAttribute(\"class\", \"libjass-filters\");\n\t\tsvgElement.width.baseVal.valueAsString = \"0\";\n\t\tsvgElement.height.baseVal.valueAsString = \"0\";\n\n\t\tconst svgDefsElement = document.createElementNS(\"http://www.w3.org/2000/svg\", \"defs\");\n\t\tsvgElement.appendChild(svgDefsElement);\n\n\t\tlet currentSpan: HTMLSpanElement = null;\n\t\tconst currentSpanStyles = new SpanStyles(this, dialogue, this._scaleX, this._scaleY, this.settings, this._fontSizeElement, svgDefsElement, this._fontMetricsCache);\n\n\t\tlet currentAnimationCollection: AnimationCollection = null;\n\n\t\tlet previousAddNewLine = false; // If two or more \\N's are encountered in sequence, then all but the first will be created using currentSpanStyles.makeNewLine() instead\n\t\tconst startNewSpan = (addNewLine: boolean): void => {\n\t\t\tif (currentSpan !== null && currentSpan.hasChildNodes()) {\n\t\t\t\tsub.appendChild(currentSpanStyles.setStylesOnSpan(currentSpan, currentAnimationCollection));\n\t\t\t}\n\n\t\t\tif (currentAnimationCollection !== null) {\n\t\t\t\tcurrentAnimationCollection.animationDelays.forEach((delay, name) => dialogueAnimationCollection.animationDelays.set(name, delay));\n\t\t\t}\n\n\t\t\tif (addNewLine) {\n\t\t\t\tif (previousAddNewLine) {\n\t\t\t\t\tsub.appendChild(currentSpanStyles.makeNewLine());\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tsub.appendChild(document.createElement(\"br\"));\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tcurrentSpan = document.createElement(\"span\");\n\t\t\tcurrentAnimationCollection = new AnimationCollection(this, dialogueAnimationStylesElement);\n\n\t\t\tpreviousAddNewLine = addNewLine;\n\t\t};\n\t\tstartNewSpan(false);\n\n\t\tconst currentDrawingStyles = new DrawingStyles(this._scaleX, this._scaleY);\n\n\t\tlet wrappingStyle = this.ass.properties.wrappingStyle;\n\n\t\tlet karaokeTimesAccumulator = 0;\n\n\t\tfor (const part of dialogue.parts) {\n\t\t\tif (part instanceof parts.Italic) {\n\t\t\t\tcurrentSpanStyles.italic = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.Bold) {\n\t\t\t\tcurrentSpanStyles.bold = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.Underline) {\n\t\t\t\tcurrentSpanStyles.underline = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.StrikeThrough) {\n\t\t\t\tcurrentSpanStyles.strikeThrough = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.Border) {\n\t\t\t\tcurrentSpanStyles.outlineWidth = part.value;\n\t\t\t\tcurrentSpanStyles.outlineHeight = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.BorderX) {\n\t\t\t\tcurrentSpanStyles.outlineWidth = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.BorderY) {\n\t\t\t\tcurrentSpanStyles.outlineHeight = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.Shadow) {\n\t\t\t\tcurrentSpanStyles.shadowDepthX = part.value;\n\t\t\t\tcurrentSpanStyles.shadowDepthY = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.ShadowX) {\n\t\t\t\tcurrentSpanStyles.shadowDepthX = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.ShadowY) {\n\t\t\t\tcurrentSpanStyles.shadowDepthY = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.Blur) {\n\t\t\t\tcurrentSpanStyles.blur = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.GaussianBlur) {\n\t\t\t\tcurrentSpanStyles.gaussianBlur = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.FontName) {\n\t\t\t\tcurrentSpanStyles.fontName = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.FontSize) {\n\t\t\t\tcurrentSpanStyles.fontSize = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.FontSizePlus) {\n\t\t\t\tcurrentSpanStyles.fontSize += part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.FontSizeMinus) {\n\t\t\t\tcurrentSpanStyles.fontSize -= part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.FontScaleX) {\n\t\t\t\tcurrentSpanStyles.fontScaleX = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.FontScaleY) {\n\t\t\t\tcurrentSpanStyles.fontScaleY = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.LetterSpacing) {\n\t\t\t\tcurrentSpanStyles.letterSpacing = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.RotateX) {\n\t\t\t\tcurrentSpanStyles.rotationX = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.RotateY) {\n\t\t\t\tcurrentSpanStyles.rotationY = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.RotateZ) {\n\t\t\t\tcurrentSpanStyles.rotationZ = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.SkewX) {\n\t\t\t\tcurrentSpanStyles.skewX = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.SkewY) {\n\t\t\t\tcurrentSpanStyles.skewY = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.PrimaryColor) {\n\t\t\t\tcurrentSpanStyles.primaryColor = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.SecondaryColor) {\n\t\t\t\tcurrentSpanStyles.secondaryColor = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.OutlineColor) {\n\t\t\t\tcurrentSpanStyles.outlineColor = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.ShadowColor) {\n\t\t\t\tcurrentSpanStyles.shadowColor = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.Alpha) {\n\t\t\t\tcurrentSpanStyles.primaryAlpha = part.value;\n\t\t\t\tcurrentSpanStyles.secondaryAlpha = part.value;\n\t\t\t\tcurrentSpanStyles.outlineAlpha = part.value;\n\t\t\t\tcurrentSpanStyles.shadowAlpha = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.PrimaryAlpha) {\n\t\t\t\tcurrentSpanStyles.primaryAlpha = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.SecondaryAlpha) {\n\t\t\t\tcurrentSpanStyles.secondaryAlpha = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.OutlineAlpha) {\n\t\t\t\tcurrentSpanStyles.outlineAlpha = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.ShadowAlpha) {\n\t\t\t\tcurrentSpanStyles.shadowAlpha = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.Alignment) {\n\t\t\t\t// Already handled in Dialogue\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.ColorKaraoke) {\n\t\t\t\tstartNewSpan(false);\n\n\t\t\t\tcurrentAnimationCollection.add(\"step-end\", [\n\t\t\t\t\tnew Keyframe(0, new Map([\n\t\t\t\t\t\t[\"color\", currentSpanStyles.secondaryColor.withAlpha(currentSpanStyles.secondaryAlpha).toString()],\n\t\t\t\t\t])), new Keyframe(karaokeTimesAccumulator, new Map([\n\t\t\t\t\t\t[\"color\", currentSpanStyles.primaryColor.withAlpha(currentSpanStyles.primaryAlpha).toString()],\n\t\t\t\t\t]))\n\t\t\t\t]);\n\n\t\t\t\tkaraokeTimesAccumulator += part.duration;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.WrappingStyle) {\n\t\t\t\twrappingStyle = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.Reset) {\n\t\t\t\tcurrentSpanStyles.reset(this.ass.styles.get(part.value));\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.Position) {\n\t\t\t\tsub.style.position = \"absolute\";\n\t\t\t\tsub.style.left = `${ (this._scaleX * part.x).toFixed(3) }px`;\n\t\t\t\tsub.style.top = `${ (this._scaleY * part.y).toFixed(3) }px`;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.Move) {\n\t\t\t\tsub.style.position = \"absolute\";\n\t\t\t\tdialogueAnimationCollection.add(\"linear\", [new Keyframe(0, new Map([\n\t\t\t\t\t[\"left\", `${ (this._scaleX * part.x1).toFixed(3) }px`],\n\t\t\t\t\t[\"top\", `${ (this._scaleY * part.y1).toFixed(3) }px`],\n\t\t\t\t])), new Keyframe(part.t1, new Map([\n\t\t\t\t\t[\"left\", `${ (this._scaleX * part.x1).toFixed(3) }px`],\n\t\t\t\t\t[\"top\", `${ (this._scaleY * part.y1).toFixed(3) }px`],\n\t\t\t\t])), new Keyframe(part.t2, new Map([\n\t\t\t\t\t[\"left\", `${ (this._scaleX * part.x2).toFixed(3) }px`],\n\t\t\t\t\t[\"top\", `${ (this._scaleY * part.y2).toFixed(3) }px`],\n\t\t\t\t])), new Keyframe(dialogue.end - dialogue.start, new Map([\n\t\t\t\t\t[\"left\", `${ (this._scaleX * part.x2).toFixed(3) }px`],\n\t\t\t\t\t[\"top\", `${ (this._scaleY * part.y2).toFixed(3) }px`],\n\t\t\t\t]))]);\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.Fade) {\n\t\t\t\tdialogueAnimationCollection.add(\"linear\", [new Keyframe(0, new Map([\n\t\t\t\t\t[\"opacity\", \"0\"],\n\t\t\t\t])), new Keyframe(part.start, new Map([\n\t\t\t\t\t[\"opacity\", \"1\"],\n\t\t\t\t])), new Keyframe(dialogue.end - dialogue.start - part.end, new Map([\n\t\t\t\t\t[\"opacity\", \"1\"],\n\t\t\t\t])), new Keyframe(dialogue.end - dialogue.start, new Map([\n\t\t\t\t\t[\"opacity\", \"0\"],\n\t\t\t\t]))]);\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.ComplexFade) {\n\t\t\t\tdialogueAnimationCollection.add(\"linear\", [new Keyframe(0, new Map([\n\t\t\t\t\t[\"opacity\", part.a1.toFixed(3)],\n\t\t\t\t])), new Keyframe(part.t1, new Map([\n\t\t\t\t\t[\"opacity\", part.a1.toFixed(3)],\n\t\t\t\t])), new Keyframe(part.t2, new Map([\n\t\t\t\t\t[\"opacity\", part.a2.toFixed(3)],\n\t\t\t\t])), new Keyframe(part.t3, new Map([\n\t\t\t\t\t[\"opacity\", part.a2.toFixed(3)],\n\t\t\t\t])), new Keyframe(part.t4, new Map([\n\t\t\t\t\t[\"opacity\", part.a3.toFixed(3)],\n\t\t\t\t])), new Keyframe(dialogue.end - dialogue.start, new Map([\n\t\t\t\t\t[\"opacity\", part.a3.toFixed(3)],\n\t\t\t\t]))]);\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.Transform) {\n\t\t\t\tconst progression =\n\t\t\t\t\t(currentTimeRelativeToDialogueStart <= part.start) ? 0 :\n\t\t\t\t\t(currentTimeRelativeToDialogueStart >= part.end) ? 1 :\n\t\t\t\t\tMath.pow((currentTimeRelativeToDialogueStart - part.start) / (part.end - part.start), part.accel);\n\n\t\t\t\tfor (const tag of part.tags) {\n\t\t\t\t\tif (tag instanceof parts.Border) {\n\t\t\t\t\t\tcurrentSpanStyles.outlineWidth += progression * (tag.value - currentSpanStyles.outlineWidth);\n\t\t\t\t\t\tcurrentSpanStyles.outlineHeight += progression * (tag.value - currentSpanStyles.outlineHeight);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.BorderX) {\n\t\t\t\t\t\tcurrentSpanStyles.outlineWidth += progression * (tag.value - currentSpanStyles.outlineWidth);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.BorderY) {\n\t\t\t\t\t\tcurrentSpanStyles.outlineHeight += progression * (tag.value - currentSpanStyles.outlineHeight);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.Shadow) {\n\t\t\t\t\t\tcurrentSpanStyles.shadowDepthX += progression * (tag.value - currentSpanStyles.shadowDepthX);\n\t\t\t\t\t\tcurrentSpanStyles.shadowDepthY += progression * (tag.value - currentSpanStyles.shadowDepthY);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.ShadowX) {\n\t\t\t\t\t\tcurrentSpanStyles.shadowDepthX += progression * (tag.value - currentSpanStyles.shadowDepthX);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.ShadowY) {\n\t\t\t\t\t\tcurrentSpanStyles.shadowDepthY += progression * (tag.value - currentSpanStyles.shadowDepthY);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.Blur) {\n\t\t\t\t\t\tcurrentSpanStyles.blur += progression * (tag.value - currentSpanStyles.blur);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.GaussianBlur) {\n\t\t\t\t\t\tcurrentSpanStyles.gaussianBlur += progression * (tag.value - currentSpanStyles.gaussianBlur);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.FontSize) {\n\t\t\t\t\t\tcurrentSpanStyles.fontSize += progression * (tag.value - currentSpanStyles.fontSize);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.FontSizePlus) {\n\t\t\t\t\t\tcurrentSpanStyles.fontSize += progression * tag.value;\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.FontSizeMinus) {\n\t\t\t\t\t\tcurrentSpanStyles.fontSize -= progression * tag.value;\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.FontScaleX) {\n\t\t\t\t\t\tcurrentSpanStyles.fontScaleX += progression * (tag.value - currentSpanStyles.fontScaleX);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.FontScaleY) {\n\t\t\t\t\t\tcurrentSpanStyles.fontScaleY += progression * (tag.value - currentSpanStyles.fontScaleY);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.LetterSpacing) {\n\t\t\t\t\t\tcurrentSpanStyles.letterSpacing += progression * (tag.value - currentSpanStyles.letterSpacing);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.RotateX) {\n\t\t\t\t\t\tcurrentSpanStyles.rotationX += progression * (tag.value - currentSpanStyles.rotationX);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.RotateY) {\n\t\t\t\t\t\tcurrentSpanStyles.rotationY += progression * (tag.value - currentSpanStyles.rotationY);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.RotateZ) {\n\t\t\t\t\t\tcurrentSpanStyles.rotationZ += progression * (tag.value - currentSpanStyles.rotationZ);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.SkewX) {\n\t\t\t\t\t\tcurrentSpanStyles.skewX += progression * (tag.value - currentSpanStyles.skewX);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.SkewY) {\n\t\t\t\t\t\tcurrentSpanStyles.skewY += progression * (tag.value - currentSpanStyles.skewY);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.PrimaryColor) {\n\t\t\t\t\t\tcurrentSpanStyles.primaryColor = currentSpanStyles.primaryColor.interpolate(tag.value, progression);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.SecondaryColor) {\n\t\t\t\t\t\tcurrentSpanStyles.secondaryColor = currentSpanStyles.secondaryColor.interpolate(tag.value, progression);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.OutlineColor) {\n\t\t\t\t\t\tcurrentSpanStyles.outlineColor = currentSpanStyles.outlineColor.interpolate(tag.value, progression);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.ShadowColor) {\n\t\t\t\t\t\tcurrentSpanStyles.shadowColor = currentSpanStyles.shadowColor.interpolate(tag.value, progression);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.Alpha) {\n\t\t\t\t\t\tcurrentSpanStyles.primaryAlpha += progression * (tag.value - currentSpanStyles.primaryAlpha);\n\t\t\t\t\t\tcurrentSpanStyles.secondaryAlpha += progression * (tag.value - currentSpanStyles.secondaryAlpha);\n\t\t\t\t\t\tcurrentSpanStyles.outlineAlpha += progression * (tag.value - currentSpanStyles.outlineAlpha);\n\t\t\t\t\t\tcurrentSpanStyles.shadowAlpha += progression * (tag.value - currentSpanStyles.shadowAlpha);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.PrimaryAlpha) {\n\t\t\t\t\t\tcurrentSpanStyles.primaryAlpha += progression * (tag.value - currentSpanStyles.primaryAlpha);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.SecondaryAlpha) {\n\t\t\t\t\t\tcurrentSpanStyles.secondaryAlpha += progression * (tag.value - currentSpanStyles.secondaryAlpha);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.OutlineAlpha) {\n\t\t\t\t\t\tcurrentSpanStyles.outlineAlpha += progression * (tag.value - currentSpanStyles.outlineAlpha);\n\t\t\t\t\t}\n\n\t\t\t\t\telse if (tag instanceof parts.ShadowAlpha) {\n\t\t\t\t\t\tcurrentSpanStyles.shadowAlpha += progression * (tag.value - currentSpanStyles.shadowAlpha);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.DrawingMode) {\n\t\t\t\tif (part.scale !== 0) {\n\t\t\t\t\tcurrentDrawingStyles.scale = part.scale;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.DrawingBaselineOffset) {\n\t\t\t\tcurrentDrawingStyles.baselineOffset = part.value;\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.DrawingInstructions) {\n\t\t\t\tcurrentSpan.appendChild(currentDrawingStyles.toSVG(part, currentSpanStyles.primaryColor.withAlpha(currentSpanStyles.primaryAlpha)));\n\t\t\t\tstartNewSpan(false);\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.Text) {\n\t\t\t\tcurrentSpan.appendChild(document.createTextNode(part.value + \"\\u200C\"));\n\t\t\t\tstartNewSpan(false);\n\t\t\t}\n\n\t\t\telse if (debugMode && part instanceof parts.Comment) {\n\t\t\t\tcurrentSpan.appendChild(document.createTextNode(part.value));\n\t\t\t\tstartNewSpan(false);\n\t\t\t}\n\n\t\t\telse if (part instanceof parts.NewLine) {\n\t\t\t\tstartNewSpan(true);\n\t\t\t}\n\t\t}\n\n\t\tfor (const part of dialogue.parts) {\n\t\t\tif (part instanceof parts.Position || part instanceof parts.Move) {\n\t\t\t\tconst transformOrigin = WebRenderer._transformOrigins[dialogue.alignment];\n\n\t\t\t\tconst divTransformStyle = `translate(${ -transformOrigin[0] }%, ${ -transformOrigin[1] }%) translate(-${ sub.style.marginLeft }, -${ sub.style.marginTop })`;\n\t\t\t\tconst transformOriginString = `${ transformOrigin[0] }% ${ transformOrigin[1] }%`;\n\n\t\t\t\tsub.style.webkitTransform = divTransformStyle;\n\t\t\t\tsub.style.webkitTransformOrigin = transformOriginString;\n\n\t\t\t\tsub.style.transform = divTransformStyle;\n\t\t\t\tsub.style.transformOrigin = transformOriginString;\n\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tswitch (wrappingStyle) {\n\t\t\tcase WrappingStyle.EndOfLineWrapping:\n\t\t\t\tsub.style.whiteSpace = \"pre-wrap\";\n\t\t\t\tbreak;\n\n\t\t\tcase WrappingStyle.NoLineWrapping:\n\t\t\t\tsub.style.whiteSpace = \"pre\";\n\t\t\t\tbreak;\n\n\t\t\tcase WrappingStyle.SmartWrappingWithWiderTopLine:\n\t\t\tcase WrappingStyle.SmartWrappingWithWiderBottomLine:\n\t\t\t\t/* Not supported. Treat the same as EndOfLineWrapping */\n\t\t\t\tsub.style.whiteSpace = \"pre-wrap\";\n\t\t\t\tbreak;\n\t\t}\n\n\t\tif (sub.style.position !== \"\") {\n\t\t\t// Explicitly set text alignment on absolutely-positioned subs because they'll go in a .an0 <div> and so won't get alignment CSS text-align.\n\t\t\tswitch (dialogue.alignment) {\n\t\t\t\tcase 1: case 4: case 7: sub.style.textAlign = \"left\"; break;\n\t\t\t\tcase 2: case 5: case 8: sub.style.textAlign = \"center\"; break;\n\t\t\t\tcase 3: case 6: case 9: sub.style.textAlign = \"right\"; break;\n\t\t\t}\n\t\t}\n\n\t\tsub.style.webkitAnimation = dialogueAnimationCollection.animationStyle;\n\t\tsub.style.animation = dialogueAnimationCollection.animationStyle;\n\n\t\tsub.setAttribute(\"data-dialogue-id\", `${ this.id }-${ dialogue.id }`);\n\n\t\tif (dialogueAnimationStylesElement.textContent !== \"\") {\n\t\t\tsub.appendChild(dialogueAnimationStylesElement);\n\t\t}\n\n\t\tif (svgDefsElement.hasChildNodes()) {\n\t\t\tsub.appendChild(svgElement);\n\t\t}\n\n\t\tconst result = { sub, animationDelays: dialogueAnimationCollection.animationDelays };\n\n\t\tif (!dialogue.containsTransformTag) {\n\t\t\tthis._preRenderedSubs.set(dialogue.id, result);\n\t\t}\n\n\t\treturn result;\n\t}\n\n\t/**\n\t * Returns the subtitle div for display. The {@link libjass.renderers.Clock.currentTime} of the {@link libjass.renderers.NullRenderer.clock} is used to shift the\n\t * animations appropriately, so that at the time the div is inserted into the DOM and the animations begin, they are in sync with the clock time.\n\t *\n\t * @param {!libjass.Dialogue} dialogue\n\t */\n\tdraw(dialogue: Dialogue): void {\n\t\tif (this._currentSubs.has(dialogue) && !dialogue.containsTransformTag) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (debugMode) {\n\t\t\tconsole.log(dialogue.toString());\n\t\t}\n\n\t\tlet preRenderedSub = this._preRenderedSubs.get(dialogue.id);\n\n\t\tif (preRenderedSub === undefined) {\n\t\t\tpreRenderedSub = this.preRender(dialogue);\n\n\t\t\tif (debugMode) {\n\t\t\t\tconsole.log(dialogue.toString());\n\t\t\t}\n\t\t}\n\n\t\tconst result = <HTMLDivElement>preRenderedSub.sub.cloneNode(true);\n\n\t\tconst applyAnimationDelays = (node: HTMLElement) => {\n\t\t\tconst animationNames = node.style.animationName || node.style.webkitAnimationName;\n\t\t\tif (animationNames !== undefined && animationNames !== \"\") {\n\t\t\t\tconst animationDelays = animationNames.split(\",\").map(name => {\n\t\t\t\t\tname = name.trim();\n\t\t\t\t\tconst delay = preRenderedSub.animationDelays.get(name);\n\t\t\t\t\treturn `${ ((delay + dialogue.start - this.clock.currentTime) / this.clock.rate).toFixed(3) }s`;\n\t\t\t\t}).join(\", \");\n\n\t\t\t\tnode.style.webkitAnimationDelay = animationDelays;\n\t\t\t\tnode.style.animationDelay = animationDelays;\n\t\t\t}\n\t\t}\n\t\tapplyAnimationDelays(result);\n\t\tconst animatedDescendants = result.querySelectorAll('[style*=\"animation:\"]');\n\t\tfor (let i = 0; i < animatedDescendants.length; i++) {\n\t\t\tapplyAnimationDelays(<HTMLElement>animatedDescendants[i]);\n\t\t}\n\n\t\tconst layer = dialogue.layer;\n\t\tconst alignment = (result.style.position === \"absolute\") ? 0 : dialogue.alignment; // Alignment 0 is for absolutely-positioned subs\n\n\t\t// Create the layer wrapper div and the alignment div inside it if not already created\n\t\tif (this._layerWrappers[layer] === undefined) {\n\t\t\tconst layerWrapper = document.createElement(\"div\");\n\t\t\tlayerWrapper.className = `layer layer${ layer }`;\n\n\t\t\t// Find the next greater layer div and insert this div before that one\n\t\t\tlet insertBeforeElement: HTMLDivElement = null;\n\t\t\tfor (let insertBeforeLayer = layer + 1; insertBeforeLayer < this._layerWrappers.length && insertBeforeElement === null; insertBeforeLayer++) {\n\t\t\t\tif (this._layerWrappers[insertBeforeLayer] !== undefined) {\n\t\t\t\t\tinsertBeforeElement = this._layerWrappers[insertBeforeLayer];\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tthis._subsWrapper.insertBefore(layerWrapper, insertBeforeElement);\n\n\t\t\tthis._layerWrappers[layer] = layerWrapper;\n\t\t\tthis._layerAlignmentWrappers[layer] = [];\n\t\t}\n\n\t\tif (this._layerAlignmentWrappers[layer][alignment] === undefined) {\n\t\t\tconst layerAlignmentWrapper = document.createElement(\"div\");\n\t\t\tlayerAlignmentWrapper.className = `an an${ alignment }`;\n\n\t\t\t// Find the next greater layer,alignment div and insert this div before that one\n\t\t\tconst layerWrapper = this._layerWrappers[layer];\n\t\t\tlet insertBeforeElement: HTMLDivElement = null;\n\t\t\tfor (let insertBeforeAlignment = alignment + 1; insertBeforeAlignment < this._layerAlignmentWrappers[layer].length && insertBeforeElement === null; insertBeforeAlignment++) {\n\t\t\t\tif (this._layerAlignmentWrappers[layer][insertBeforeAlignment] !== undefined) {\n\t\t\t\t\tinsertBeforeElement = this._layerAlignmentWrappers[layer][insertBeforeAlignment];\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tlayerWrapper.insertBefore(layerAlignmentWrapper, insertBeforeElement);\n\n\t\t\tthis._layerAlignmentWrappers[layer][alignment] = layerAlignmentWrapper;\n\t\t}\n\n\t\tthis._layerAlignmentWrappers[layer][alignment].appendChild(result);\n\n\t\t// Workaround for IE\n\t\tconst dialogueAnimationStylesElement = result.getElementsByTagName(\"style\")[0];\n\t\tif (dialogueAnimationStylesElement !== undefined) {\n\t\t\tconst sheet = <CSSStyleSheet>dialogueAnimationStylesElement.sheet;\n\t\t\tif (sheet.cssRules.length === 0) {\n\t\t\t\tsheet.cssText = dialogueAnimationStylesElement.textContent;\n\t\t\t}\n\t\t}\n\n\t\tthis._currentSubs.set(dialogue, result);\n\t}\n\n\tprotected _onClockPlay(): void {\n\t\tsuper._onClockPlay();\n\n\t\tthis._removeAllSubs();\n\n\t\tthis._subsWrapper.style.display = \"\";\n\n\t\tthis._subsWrapper.classList.remove(\"paused\");\n\t}\n\n\tprotected _onClockTick(): void {\n\t\t// Remove dialogues that should be removed before adding new ones via super._onClockTick()\n\n\t\tconst currentTime = this.clock.currentTime;\n\n\t\tthis._currentSubs.forEach((sub: HTMLDivElement, dialogue: Dialogue) => {\n\t\t\tif (dialogue.start > currentTime || dialogue.end < currentTime || dialogue.containsTransformTag) {\n\t\t\t\tthis._currentSubs.delete(dialogue);\n\t\t\t\tthis._removeSub(sub);\n\t\t\t}\n\t\t});\n\n\t\tsuper._onClockTick();\n\t}\n\n\tprotected _onClockPause(): void {\n\t\tsuper._onClockPause();\n\n\t\tthis._subsWrapper.classList.add(\"paused\");\n\t}\n\n\tprotected _onClockStop(): void {\n\t\tsuper._onClockStop();\n\n\t\tthis._subsWrapper.style.display = \"none\";\n\t}\n\n\tprotected _onClockRateChange(): void {\n\t\tsuper._onClockRateChange();\n\n\t\t// Any dialogues which have been pre-rendered will need to be pre-rendered again.\n\t\tthis._preRenderedSubs.clear();\n\t}\n\n\tprotected _ready(): void {\n\t\tthis._dispatchEvent(\"ready\", []);\n\t}\n\n\t/**\n\t * @param {string} fontFamily\n\t * @param {!Promise.<*>} fontFetchPromise\n\t * @return {!Promise.<[number, number]>}\n\t */\n\tprivate _calculateFontMetricsAfterFetch(fontFamily: string, fontFetchPromise: Promise<any>): Promise<[number, number]> {\n\t\treturn fontFetchPromise.then(() => {\n\t\t\tconst fontSizeElement = <HTMLDivElement>this._fontSizeElement.cloneNode(true);\n\t\t\tthis._libjassSubsWrapper.appendChild(fontSizeElement);\n\t\t\treturn Promise_finally(calculateFontMetrics(fontFamily, this.settings.fallbackFonts, fontSizeElement), () => {\n\t\t\t\tthis._libjassSubsWrapper.removeChild(fontSizeElement);\n\t\t\t});\n\t\t});\n\t}\n\n\t/**\n\t * @param {!HTMLDivElement} sub\n\t */\n\tprivate _removeSub(sub: HTMLDivElement): void {\n\t\tsub.parentNode.removeChild(sub);\n\t}\n\n\tprivate _removeAllSubs(): void {\n\t\tthis._currentSubs.forEach((sub: HTMLDivElement) => this._removeSub(sub));\n\t\tthis._currentSubs.clear();\n\t}\n\n\tprivate static _transformOrigins: number[][] = [\n\t\tnull,\n\t\t[0, 100], [50, 100], [100, 100],\n\t\t[0, 50], [50, 50], [100, 50],\n\t\t[0, 0], [50, 0], [100, 0]\n\t];\n\n\t// EventSource members\n\n\t/**\n\t * @type {!Map.<T, !Array.<Function>>}\n\t */\n\t_eventListeners: Map<string, Function[]> = new Map<string, Function[]>();\n\n\t/**\n\t * @type {function(number, !Function)}\n\t */\n\taddEventListener: (type: string, listener: Function) => void;\n\n\t/**\n\t * @type {function(number, Array.<*>)}\n\t */\n\t_dispatchEvent: (type: string, args: Object[]) => void;\n}\nmixin(WebRenderer, [EventSource]);\n\ninterface PreRenderedSub {\n\t/** @type {!HTMLDivElement} */\n\tsub: HTMLDivElement;\n\n\t/** @type {!Map.<string, number>} */\n\tanimationDelays: Map<string, number>;\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { AnimationCollection } from \"./animation-collection\";\n\nimport { fontSizeForLineHeight } from \"./font-size\";\n\nimport { WebRenderer } from \"./renderer\";\n\nimport { RendererSettings } from \"../settings\";\n\nimport { Color } from \"../../parts\";\n\nimport { Style } from \"../../types/style\";\nimport { Dialogue } from \"../../types/dialogue\";\n\nimport { Map } from \"../../utility/map\";\n\n/**\n * This class represents the style attribute of a span.\n * As a Dialogue's div is rendered, individual parts are added to span's, and this class is used to maintain the style attribute of those.\n *\n * @param {!libjass.renderers.NullRenderer} renderer The renderer that this set of styles is associated with\n * @param {!libjass.Dialogue} dialogue The Dialogue that this set of styles is associated with\n * @param {number} scaleX The horizontal scaling of the subtitles\n * @param {number} scaleY The vertical scaling of the subtitles\n * @param {!libjass.renderers.RendererSettings} settings The renderer settings\n * @param {!HTMLDivElement} fontSizeElement A <div> element to measure font sizes with\n * @param {!SVGDefsElement} svgDefsElement An SVG <defs> element to append filter definitions to\n * @param {!Map<string, [number, number]>} fontMetricsCache Font metrics cache\n */\nexport class SpanStyles {\n\tprivate _id: string;\n\tprivate _defaultStyle: Style;\n\n\tprivate _italic: boolean;\n\tprivate _bold: Object;\n\tprivate _underline: boolean;\n\tprivate _strikeThrough: boolean;\n\n\tprivate _outlineWidth: number;\n\tprivate _outlineHeight: number;\n\n\tprivate _shadowDepthX: number;\n\tprivate _shadowDepthY: number;\n\n\tprivate _fontName: string;\n\tprivate _fontSize: number;\n\n\tprivate _fontScaleX: number;\n\tprivate _fontScaleY: number;\n\n\tprivate _letterSpacing: number;\n\n\tprivate _rotationX: number;\n\tprivate _rotationY: number;\n\tprivate _rotationZ: number;\n\n\tprivate _skewX: number;\n\tprivate _skewY: number;\n\n\tprivate _primaryColor: Color;\n\tprivate _secondaryColor: Color;\n\tprivate _outlineColor: Color;\n\tprivate _shadowColor: Color;\n\n\tprivate _primaryAlpha: number;\n\tprivate _secondaryAlpha: number;\n\tprivate _outlineAlpha: number;\n\tprivate _shadowAlpha: number;\n\n\tprivate _blur: number;\n\tprivate _gaussianBlur: number;\n\n\tprivate _nextFilterId = 0;\n\n\tconstructor(renderer: WebRenderer, dialogue: Dialogue, private _scaleX: number, private _scaleY: number, private _settings: RendererSettings, private _fontSizeElement: HTMLDivElement, private _svgDefsElement: SVGDefsElement, private _fontMetricsCache: Map<string, [number, number]>) {\n\t\tthis._id = `${ renderer.id }-${ dialogue.id }`;\n\t\tthis._defaultStyle = dialogue.style;\n\n\t\tthis.reset(null);\n\t}\n\n\t/**\n\t * Resets the styles to the defaults provided by the argument.\n\t *\n\t * @param {libjass.Style} newStyle The new defaults to reset the style to. If null, the styles are reset to the default style of the Dialogue.\n\t */\n\treset(newStyle: Style): void {\n\t\tif (newStyle === undefined || newStyle === null) {\n\t\t\tnewStyle = this._defaultStyle;\n\t\t}\n\n\t\tthis.italic = newStyle.italic;\n\t\tthis.bold = newStyle.bold;\n\t\tthis.underline = newStyle.underline;\n\t\tthis.strikeThrough = newStyle.strikeThrough;\n\n\t\tthis.outlineWidth = newStyle.outlineThickness;\n\t\tthis.outlineHeight = newStyle.outlineThickness;\n\n\t\tthis.shadowDepthX = newStyle.shadowDepth;\n\t\tthis.shadowDepthY = newStyle.shadowDepth;\n\n\t\tthis.fontName = newStyle.fontName;\n\t\tthis.fontSize = newStyle.fontSize;\n\n\t\tthis.fontScaleX = newStyle.fontScaleX;\n\t\tthis.fontScaleY = newStyle.fontScaleY;\n\n\t\tthis.letterSpacing = newStyle.letterSpacing;\n\n\t\tthis._rotationX = null;\n\t\tthis._rotationY = null;\n\t\tthis._rotationZ = newStyle.rotationZ;\n\n\t\tthis._skewX = null;\n\t\tthis._skewY = null;\n\n\t\tthis.primaryColor = newStyle.primaryColor;\n\t\tthis.secondaryColor = newStyle.secondaryColor;\n\t\tthis.outlineColor = newStyle.outlineColor;\n\t\tthis.shadowColor = newStyle.shadowColor;\n\n\t\tthis.primaryAlpha = newStyle.primaryColor.alpha;\n\t\tthis.secondaryAlpha = newStyle.secondaryColor.alpha;\n\t\tthis.outlineAlpha = newStyle.outlineColor.alpha;\n\t\tthis.shadowAlpha = newStyle.shadowColor.alpha;\n\n\t\tthis.blur = null;\n\t\tthis.gaussianBlur = null;\n\t}\n\n\t/**\n\t * Sets the style attribute on the given span element.\n\t *\n\t * @param {!HTMLSpanElement} span\n\t * @param {!AnimationCollection} animationCollection\n\t * @return {!HTMLSpanElement} The resulting <span> with the CSS styles applied. This may be a wrapper around the input <span> if the styles were applied using SVG filters.\n\t */\n\tsetStylesOnSpan(span: HTMLSpanElement, animationCollection: AnimationCollection): HTMLSpanElement {\n\t\tconst isTextOnlySpan = span.childNodes[0] instanceof Text;\n\n\t\tlet fontStyleOrWeight = \"\";\n\t\tif (this._italic) {\n\t\t\tfontStyleOrWeight += \"italic \";\n\t\t}\n\t\tif (this._bold === true) {\n\t\t\tfontStyleOrWeight += \"bold \";\n\t\t}\n\t\telse if (this._bold !== false) {\n\t\t\tfontStyleOrWeight += this._bold + \" \";\n\t\t}\n\t\tconst fontSize = (\n\t\t\tthis._scaleY *\n\t\t\tfontSizeForLineHeight(this._fontName, this._fontSize * (isTextOnlySpan ? this._fontScaleX : 1), this._settings.fallbackFonts, this._fontSizeElement, this._fontMetricsCache)\n\t\t).toFixed(3);\n\t\tconst lineHeight = (this._scaleY * this._fontSize).toFixed(3);\n\n\t\tlet fonts = this._fontName;\n\n\t\t// Quote the font family unless it's a generic family, as those must never be quoted\n\t\tswitch (fonts) {\n\t\t\tcase \"cursive\":\n\t\t\tcase \"fantasy\":\n\t\t\tcase \"monospace\":\n\t\t\tcase \"sans-serif\":\n\t\t\tcase \"serif\":\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tfonts = `\"${ fonts }\"`;\n\t\t\t\tbreak;\n\t\t}\n\n\t\tif (this._settings.fallbackFonts !== \"\") {\n\t\t\tfonts += `, ${ this._settings.fallbackFonts }`;\n\t\t}\n\n\t\tspan.style.font = `${ fontStyleOrWeight }${ fontSize }px/${ lineHeight }px ${ fonts }`;\n\n\t\tlet textDecoration = \"\";\n\t\tif (this._underline) {\n\t\t\ttextDecoration = \"underline\";\n\t\t}\n\t\tif (this._strikeThrough) {\n\t\t\ttextDecoration += \" line-through\";\n\t\t}\n\t\tspan.style.textDecoration = textDecoration.trim();\n\n\t\tlet transform = \"\";\n\t\tif (isTextOnlySpan) {\n\t\t\tif (this._fontScaleY !== this._fontScaleX) {\n\t\t\t\ttransform += `scaleY(${ (this._fontScaleY / this._fontScaleX).toFixed(3) }) `;\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\tif (this._fontScaleX !== 1) {\n\t\t\t\ttransform += `scaleX(${ this._fontScaleX }) `;\n\t\t\t}\n\t\t\tif (this._fontScaleY !== 1) {\n\t\t\t\ttransform += `scaleY(${ this._fontScaleY }) `;\n\t\t\t}\n\t\t}\n\t\tif (this._rotationY !== null) {\n\t\t\ttransform += `rotateY(${ this._rotationY }deg) `;\n\t\t}\n\t\tif (this._rotationX !== null) {\n\t\t\ttransform += `rotateX(${ this._rotationX }deg) `;\n\t\t}\n\t\tif (this._rotationZ !== 0) {\n\t\t\ttransform += `rotateZ(${ -1 * this._rotationZ }deg) `;\n\t\t}\n\t\tif (this._skewX !== null || this._skewY !== null) {\n\t\t\tconst skewX = SpanStyles._valueOrDefault(this._skewX, 0);\n\t\t\tconst skewY = SpanStyles._valueOrDefault(this._skewY, 0);\n\t\t\ttransform += `matrix(1, ${ skewY }, ${ skewX }, 1, 0, 0) `;\n\t\t}\n\t\tif (transform !== \"\") {\n\t\t\tspan.style.webkitTransform = transform;\n\t\t\tspan.style.webkitTransformOrigin = \"50% 50%\";\n\t\t\tspan.style.transform = transform;\n\t\t\tspan.style.transformOrigin = \"50% 50%\";\n\t\t\tspan.style.display = \"inline-block\";\n\t\t}\n\n\t\tspan.style.letterSpacing = `${ (this._scaleX * this._letterSpacing).toFixed(3) }px`;\n\n\t\tconst outlineWidth = this._scaleX * this._outlineWidth;\n\t\tconst outlineHeight = this._scaleY * this._outlineHeight;\n\n\t\tconst filterWrapperSpan = document.createElement(\"span\");\n\t\tfilterWrapperSpan.appendChild(span);\n\n\t\tlet primaryColor = this._primaryColor.withAlpha(this._primaryAlpha);\n\t\tlet outlineColor = this._outlineColor.withAlpha(this._outlineAlpha);\n\t\tlet shadowColor = this._shadowColor.withAlpha(this._shadowAlpha);\n\n\t\t// If we're in non-SVG mode and all colors have the same alpha, then set all colors to alpha === 1 and set the common alpha as the span's opacity property instead\n\t\tif (\n\t\t\t!this._settings.enableSvg &&\n\t\t\t((outlineWidth === 0 && outlineHeight === 0) || outlineColor.alpha === primaryColor.alpha) &&\n\t\t\t((this._shadowDepthX === 0 && this._shadowDepthY === 0) || shadowColor.alpha === primaryColor.alpha)\n\t\t) {\n\t\t\tprimaryColor = this._primaryColor.withAlpha(1);\n\t\t\toutlineColor = this._outlineColor.withAlpha(1);\n\t\t\tshadowColor = this._shadowColor.withAlpha(1);\n\n\t\t\tspan.style.opacity = this._primaryAlpha.toFixed(3);\n\t\t}\n\n\t\tspan.style.color = primaryColor.toString();\n\n\t\tif (this._settings.enableSvg) {\n\t\t\tthis._setSvgOutlineOnSpan(filterWrapperSpan, outlineWidth, outlineHeight, outlineColor, this._primaryAlpha);\n\t\t}\n\t\telse {\n\t\t\tthis._setTextShadowOutlineOnSpan(span, outlineWidth, outlineHeight, outlineColor);\n\t\t}\n\n\t\tif (this._shadowDepthX !== 0 || this._shadowDepthY !== 0) {\n\t\t\tconst shadowCssString = `${ shadowColor.toString() } ${ (this._shadowDepthX * this._scaleX).toFixed(3) }px ${ (this._shadowDepthY * this._scaleY).toFixed(3) }px 0px`;\n\t\t\tif (span.style.textShadow === \"\") {\n\t\t\t\tspan.style.textShadow = shadowCssString;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tspan.style.textShadow += \", \" + shadowCssString;\n\t\t\t}\n\t\t}\n\n\t\tif (this._rotationX !== 0 || this._rotationY !== 0) {\n\t\t\t// Perspective needs to be set on a \"transformable element\"\n\t\t\tfilterWrapperSpan.style.display = \"inline-block\";\n\t\t}\n\n\t\tspan.style.webkitAnimation = animationCollection.animationStyle;\n\t\tspan.style.animation = animationCollection.animationStyle;\n\n\t\treturn filterWrapperSpan;\n\t}\n\n\t/**\n\t * @param {!HTMLSpanElement} filterWrapperSpan\n\t * @param {number} outlineWidth\n\t * @param {number} outlineHeight\n\t * @param {!libjass.parts.Color} outlineColor\n\t * @param {number} primaryAlpha\n\t */\n\tprivate _setSvgOutlineOnSpan(filterWrapperSpan: HTMLSpanElement, outlineWidth: number, outlineHeight: number, outlineColor: Color, primaryAlpha: number): void {\n\t\tconst filterId = `svg-filter-${ this._id }-${ this._nextFilterId++ }`;\n\n\t\tconst filterElement = document.createElementNS(\"http://www.w3.org/2000/svg\", \"filter\");\n\t\tfilterElement.id = filterId;\n\t\tfilterElement.x.baseVal.valueAsString = \"-50%\";\n\t\tfilterElement.width.baseVal.valueAsString = \"200%\";\n\t\tfilterElement.y.baseVal.valueAsString = \"-50%\";\n\t\tfilterElement.height.baseVal.valueAsString = \"200%\";\n\n\t\tif (outlineWidth > 0 || outlineHeight > 0) {\n\t\t\t/* Construct an elliptical border by merging together many rectangles. The border is creating using dilate morphology filters, but these only support\n\t\t\t * generating rectangles. http://lists.w3.org/Archives/Public/public-fx/2012OctDec/0003.html\n\t\t\t */\n\n\t\t\tlet outlineNumber = 0;\n\n\t\t\tconst increment = (!this._settings.preciseOutlines && this._gaussianBlur > 0) ? this._gaussianBlur : 1;\n\n\t\t\t((addOutline: (x: number, y: number) => void) => {\n\t\t\t\tif (outlineWidth <= outlineHeight) {\n\t\t\t\t\tif (outlineWidth > 0) {\n\t\t\t\t\t\tlet x: number;\n\t\t\t\t\t\tfor (x = 0; x <= outlineWidth; x += increment) {\n\t\t\t\t\t\t\taddOutline(x, outlineHeight / outlineWidth * Math.sqrt(outlineWidth * outlineWidth - x * x));\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (x !== outlineWidth + increment) {\n\t\t\t\t\t\t\taddOutline(outlineWidth, 0);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\taddOutline(0, outlineHeight);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tif (outlineHeight > 0) {\n\t\t\t\t\t\tlet y: number;\n\t\t\t\t\t\tfor (y = 0; y <= outlineHeight; y += increment) {\n\t\t\t\t\t\t\taddOutline(outlineWidth / outlineHeight * Math.sqrt(outlineHeight * outlineHeight - y * y), y);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (y !== outlineHeight + increment) {\n\t\t\t\t\t\t\taddOutline(0, outlineHeight);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\taddOutline(outlineWidth, 0);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t})((x: number, y: number): void => {\n\t\t\t\tconst outlineFilter = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feMorphology\");\n\t\t\t\tfilterElement.appendChild(outlineFilter);\n\t\t\t\toutlineFilter.in1.baseVal = \"source\";\n\t\t\t\toutlineFilter.operator.baseVal = SVGFEMorphologyElement.SVG_MORPHOLOGY_OPERATOR_DILATE;\n\t\t\t\toutlineFilter.radiusX.baseVal = x;\n\t\t\t\toutlineFilter.radiusY.baseVal = y;\n\t\t\t\toutlineFilter.result.baseVal = `outline${ outlineNumber }`;\n\n\t\t\t\toutlineNumber++;\n\t\t\t});\n\n\t\t\t// Start with SourceAlpha. Leave the alpha as 0 if it's 0, and set it to 1 if it's greater than 0\n\t\t\tconst source = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feComponentTransfer\");\n\t\t\tfilterElement.insertBefore(source, filterElement.firstElementChild);\n\t\t\tsource.in1.baseVal = \"SourceAlpha\";\n\t\t\tsource.result.baseVal = \"source\";\n\n\t\t\tconst sourceAlphaTransferNode = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feFuncA\");\n\t\t\tsource.appendChild(sourceAlphaTransferNode);\n\t\t\tsourceAlphaTransferNode.type.baseVal = SVGComponentTransferFunctionElement.SVG_FECOMPONENTTRANSFER_TYPE_LINEAR;\n\n\t\t\t/* The alphas of all colored pixels of the SourceAlpha should be made as close to 1 as possible. This way the summed outlines below will be uniformly dark.\n\t\t\t * Multiply the pixels by 1 / primaryAlpha so that the primaryAlpha pixels become 1. A higher value would make the outline larger and too sharp,\n\t\t\t * leading to jagged outer edge and transparent space around the inner edge between itself and the SourceGraphic.\n\t\t\t */\n\t\t\tsourceAlphaTransferNode.slope.baseVal = (primaryAlpha === 0) ? 1 : (1 / primaryAlpha);\n\n\t\t\tsourceAlphaTransferNode.intercept.baseVal = 0;\n\n\t\t\t// Merge the individual outlines\n\t\t\tconst mergedOutlines = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feMerge\");\n\t\t\tfilterElement.appendChild(mergedOutlines);\n\n\t\t\tfor (let i = 0; i < outlineNumber; i++) {\n\t\t\t\tconst outlineReferenceNode = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feMergeNode\");\n\t\t\t\tmergedOutlines.appendChild(outlineReferenceNode);\n\t\t\t\toutlineReferenceNode.in1.baseVal = `outline${ i }`;\n\t\t\t}\n\n\t\t\t// Color it with the outline color\n\t\t\tconst coloredSource = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feComponentTransfer\");\n\t\t\tfilterElement.appendChild(coloredSource);\n\t\t\tcoloredSource.setAttribute(\"color-interpolation-filters\", \"sRGB\");\n\n\t\t\tconst outlineRedTransferNode = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feFuncR\");\n\t\t\tcoloredSource.appendChild(outlineRedTransferNode);\n\t\t\toutlineRedTransferNode.type.baseVal = SVGComponentTransferFunctionElement.SVG_FECOMPONENTTRANSFER_TYPE_LINEAR;\n\t\t\toutlineRedTransferNode.slope.baseVal = 0;\n\t\t\toutlineRedTransferNode.intercept.baseVal = outlineColor.red / 255 * outlineColor.alpha;\n\n\t\t\tconst outlineGreenTransferNode = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feFuncG\");\n\t\t\tcoloredSource.appendChild(outlineGreenTransferNode);\n\t\t\toutlineGreenTransferNode.type.baseVal = SVGComponentTransferFunctionElement.SVG_FECOMPONENTTRANSFER_TYPE_LINEAR;\n\t\t\toutlineGreenTransferNode.slope.baseVal = 0;\n\t\t\toutlineGreenTransferNode.intercept.baseVal = outlineColor.green / 255 * outlineColor.alpha;\n\n\t\t\tconst outlineBlueTransferNode = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feFuncB\");\n\t\t\tcoloredSource.appendChild(outlineBlueTransferNode);\n\t\t\toutlineBlueTransferNode.type.baseVal = SVGComponentTransferFunctionElement.SVG_FECOMPONENTTRANSFER_TYPE_LINEAR;\n\t\t\toutlineBlueTransferNode.slope.baseVal = 0;\n\t\t\toutlineBlueTransferNode.intercept.baseVal = outlineColor.blue / 255 * outlineColor.alpha;\n\n\t\t\tconst outlineAlphaTransferNode = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feFuncA\");\n\t\t\tcoloredSource.appendChild(outlineAlphaTransferNode);\n\t\t\toutlineAlphaTransferNode.type.baseVal = SVGComponentTransferFunctionElement.SVG_FECOMPONENTTRANSFER_TYPE_LINEAR;\n\t\t\toutlineAlphaTransferNode.slope.baseVal = outlineColor.alpha;\n\t\t\toutlineAlphaTransferNode.intercept.baseVal = 0;\n\n\t\t\t// Blur the merged outline\n\t\t\tif (this._gaussianBlur > 0) {\n\t\t\t\tconst gaussianBlurFilter = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feGaussianBlur\");\n\t\t\t\tfilterElement.appendChild(gaussianBlurFilter);\n\t\t\t\tgaussianBlurFilter.stdDeviationX.baseVal = this._gaussianBlur;\n\t\t\t\tgaussianBlurFilter.stdDeviationY.baseVal = this._gaussianBlur;\n\t\t\t}\n\t\t\tfor (let i = 0; i < this._blur; i++) {\n\t\t\t\tconst blurFilter = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feConvolveMatrix\");\n\t\t\t\tfilterElement.appendChild(blurFilter);\n\t\t\t\tblurFilter.setAttribute(\"kernelMatrix\", \"1 2 1 2 4 2 1 2 1\");\n\t\t\t\tblurFilter.edgeMode.baseVal = SVGFEConvolveMatrixElement.SVG_EDGEMODE_NONE;\n\t\t\t}\n\n\t\t\t// Cut out the source, so only the outline remains\n\t\t\tconst outlineCutoutNode = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feComposite\");\n\t\t\tfilterElement.appendChild(outlineCutoutNode);\n\t\t\toutlineCutoutNode.in2.baseVal = \"source\";\n\t\t\toutlineCutoutNode.operator.baseVal = SVGFECompositeElement.SVG_FECOMPOSITE_OPERATOR_OUT;\n\n\t\t\t// Merge the outline with the SourceGraphic\n\t\t\tconst mergedOutlineAndSourceGraphic = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feMerge\");\n\t\t\tfilterElement.appendChild(mergedOutlineAndSourceGraphic);\n\n\t\t\tconst outlineReferenceNode = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feMergeNode\");\n\t\t\tmergedOutlineAndSourceGraphic.appendChild(outlineReferenceNode);\n\n\t\t\tconst sourceGraphicReferenceNode = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feMergeNode\");\n\t\t\tmergedOutlineAndSourceGraphic.appendChild(sourceGraphicReferenceNode);\n\t\t\tsourceGraphicReferenceNode.in1.baseVal = \"SourceGraphic\";\n\t\t}\n\t\telse {\n\t\t\t// Blur the source graphic directly\n\t\t\tif (this._gaussianBlur > 0) {\n\t\t\t\tconst gaussianBlurFilter = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feGaussianBlur\");\n\t\t\t\tfilterElement.appendChild(gaussianBlurFilter);\n\t\t\t\tgaussianBlurFilter.stdDeviationX.baseVal = this._gaussianBlur;\n\t\t\t\tgaussianBlurFilter.stdDeviationY.baseVal = this._gaussianBlur;\n\t\t\t}\n\t\t\tfor (let i = 0; i < this._blur; i++) {\n\t\t\t\tconst blurFilter = document.createElementNS(\"http://www.w3.org/2000/svg\", \"feConvolveMatrix\");\n\t\t\t\tfilterElement.appendChild(blurFilter);\n\t\t\t\tblurFilter.setAttribute(\"kernelMatrix\", \"1 2 1 2 4 2 1 2 1\");\n\t\t\t\tblurFilter.edgeMode.baseVal = SVGFEConvolveMatrixElement.SVG_EDGEMODE_NONE;\n\t\t\t}\n\t\t}\n\n\t\tif (filterElement.childElementCount > 0) {\n\t\t\tthis._svgDefsElement.appendChild(filterElement);\n\n\t\t\tfilterWrapperSpan.style.webkitFilter = `url(\"#${ filterId }\")`;\n\t\t\tfilterWrapperSpan.style.filter = `url(\"#${ filterId }\")`;\n\t\t}\n\t}\n\n\t/**\n\t * @param {!HTMLSpanElement} span\n\t * @param {number} outlineWidth\n\t * @param {number} outlineHeight\n\t * @param {!libjass.parts.Color} outlineColor\n\t */\n\tprivate _setTextShadowOutlineOnSpan(span: HTMLSpanElement, outlineWidth: number, outlineHeight: number, outlineColor: Color): void {\n\t\tif (outlineWidth > 0 || outlineHeight > 0) {\n\t\t\tlet outlineCssString = \"\";\n\n\t\t\t((addOutline: (x: number, y: number) => void) => {\n\t\t\t\tfor (let x = 0; x <= outlineWidth; x++) {\n\t\t\t\t\tconst maxY = (outlineWidth === 0) ? outlineHeight : outlineHeight * Math.sqrt(1 - ((x * x) / (outlineWidth * outlineWidth)));\n\t\t\t\t\tfor (let y = 0; y <= maxY; y++) {\n\t\t\t\t\t\taddOutline(x, y);\n\n\t\t\t\t\t\tif (x !== 0) {\n\t\t\t\t\t\t\taddOutline(-x, y);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (y !== 0) {\n\t\t\t\t\t\t\taddOutline(x, -y);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (x !== 0 && y !== 0) {\n\t\t\t\t\t\t\taddOutline(-x, -y);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t})((x: number, y: number): void => {\n\t\t\t\toutlineCssString += `, ${ outlineColor.toString() } ${ x }px ${ y }px ${ this._gaussianBlur.toFixed(3) }px`;\n\t\t\t});\n\n\t\t\tspan.style.textShadow = outlineCssString.substr(\", \".length);\n\t\t}\n\t}\n\n\t/**\n\t * @return {!HTMLBRElement}\n\t */\n\tmakeNewLine(): HTMLBRElement {\n\t\tconst result = document.createElement(\"br\");\n\t\tresult.style.lineHeight = `${ (this._scaleY * this._fontSize).toFixed(3) }px`;\n\t\treturn result;\n\t}\n\n\t/**\n\t * Sets the italic property. null defaults it to the default style's value.\n\t *\n\t * @type {?boolean}\n\t */\n\tset italic(value: boolean) {\n\t\tthis._italic = SpanStyles._valueOrDefault(value, this._defaultStyle.italic);\n\t}\n\n\t/**\n\t * Sets the bold property. null defaults it to the default style's value.\n\t *\n\t * @type {(?number|?boolean)}\n\t */\n\tset bold(value: Object) {\n\t\tthis._bold = SpanStyles._valueOrDefault(value, this._defaultStyle.bold);\n\t}\n\n\t/**\n\t * Sets the underline property. null defaults it to the default style's value.\n\t *\n\t * @type {?boolean}\n\t */\n\tset underline(value: boolean) {\n\t\tthis._underline = SpanStyles._valueOrDefault(value, this._defaultStyle.underline);\n\t}\n\n\t/**\n\t * Sets the strike-through property. null defaults it to the default style's value.\n\t *\n\t * @type {?boolean}\n\t */\n\tset strikeThrough(value: boolean) {\n\t\tthis._strikeThrough = SpanStyles._valueOrDefault(value, this._defaultStyle.strikeThrough);\n\t}\n\n\t/**\n\t * Gets the outline width property.\n\t *\n\t * @type {number}\n\t */\n\tget outlineWidth() {\n\t\treturn this._outlineWidth;\n\t}\n\n\t/**\n\t * Sets the outline width property. null defaults it to the style's original outline width value.\n\t *\n\t * @type {?number}\n\t */\n\tset outlineWidth(value: number) {\n\t\tthis._outlineWidth = SpanStyles._valueOrDefault(value, this._defaultStyle.outlineThickness);\n\t}\n\n\t/**\n\t * Gets the outline width property.\n\t *\n\t * @type {number}\n\t */\n\tget outlineHeight() {\n\t\treturn this._outlineWidth;\n\t}\n\n\t/**\n\t * Sets the outline height property. null defaults it to the style's original outline height value.\n\t *\n\t * @type {?number}\n\t */\n\tset outlineHeight(value: number) {\n\t\tthis._outlineHeight = SpanStyles._valueOrDefault(value, this._defaultStyle.outlineThickness);\n\t}\n\n\t/**\n\t * Gets the shadow width property.\n\t *\n\t * @type {number}\n\t */\n\tget shadowDepthX() {\n\t\treturn this._shadowDepthX;\n\t}\n\n\t/**\n\t * Sets the shadow width property. null defaults it to the style's original shadow depth value.\n\t *\n\t * @type {?number}\n\t */\n\tset shadowDepthX(value: number) {\n\t\tthis._shadowDepthX = SpanStyles._valueOrDefault(value, this._defaultStyle.shadowDepth);\n\t}\n\n\t/**\n\t * Gets the shadow height property.\n\t *\n\t * @type {number}\n\t */\n\tget shadowDepthY() {\n\t\treturn this._shadowDepthY;\n\t}\n\n\t/**\n\t * Sets the shadow height property. null defaults it to the style's original shadow depth value.\n\t *\n\t * @type {?number}\n\t */\n\tset shadowDepthY(value: number) {\n\t\tthis._shadowDepthY = SpanStyles._valueOrDefault(value, this._defaultStyle.shadowDepth);\n\t}\n\n\t/**\n\t * Gets the blur property.\n\t *\n\t * @type {number}\n\t */\n\tget blur() {\n\t\treturn this._blur;\n\t}\n\n\t/**\n\t * Sets the blur property. null defaults it to 0.\n\t *\n\t * @type {?number}\n\t */\n\tset blur(value: number) {\n\t\tthis._blur = SpanStyles._valueOrDefault(value, 0);\n\t}\n\n\t/**\n\t * Gets the Gaussian blur property.\n\t *\n\t * @type {number}\n\t */\n\tget gaussianBlur() {\n\t\treturn this._gaussianBlur;\n\t}\n\n\t/**\n\t * Sets the Gaussian blur property. null defaults it to 0.\n\t *\n\t * @type {?number}\n\t */\n\tset gaussianBlur(value: number) {\n\t\tthis._gaussianBlur = SpanStyles._valueOrDefault(value, 0);\n\t}\n\n\t/**\n\t * Sets the font name property. null defaults it to the default style's value.\n\t *\n\t * @type {?string}\n\t */\n\tset fontName(value: string) {\n\t\tthis._fontName = SpanStyles._valueOrDefault(value, this._defaultStyle.fontName);\n\t}\n\n\t/**\n\t * Gets the font size property.\n\t *\n\t * @type {number}\n\t */\n\tget fontSize() {\n\t\treturn this._fontSize;\n\t}\n\n\t/**\n\t * Sets the font size property. null defaults it to the default style's value.\n\t *\n\t * @type {?number}\n\t */\n\tset fontSize(value: number) {\n\t\tthis._fontSize = SpanStyles._valueOrDefault(value, this._defaultStyle.fontSize);\n\t}\n\n\t/**\n\t * Gets the horizontal font scaling property.\n\t *\n\t * @type {number}\n\t */\n\tget fontScaleX() {\n\t\treturn this._fontScaleX;\n\t}\n\n\t/**\n\t * Sets the horizontal font scaling property. null defaults it to the default style's value.\n\t *\n\t * @type {?number}\n\t */\n\tset fontScaleX(value: number) {\n\t\tthis._fontScaleX = SpanStyles._valueOrDefault(value, this._defaultStyle.fontScaleX);\n\t}\n\n\t/**\n\t * Gets the vertical font scaling property.\n\t *\n\t * @type {number}\n\t */\n\tget fontScaleY() {\n\t\treturn this._fontScaleY;\n\t}\n\n\t/**\n\t * Sets the vertical font scaling property. null defaults it to the default style's value.\n\t *\n\t * @type {?number}\n\t */\n\tset fontScaleY(value: number) {\n\t\tthis._fontScaleY = SpanStyles._valueOrDefault(value, this._defaultStyle.fontScaleY);\n\t}\n\n\t/**\n\t * Gets the letter spacing property.\n\t *\n\t * @type {number}\n\t */\n\tget letterSpacing() {\n\t\treturn this._letterSpacing;\n\t}\n\n\t/**\n\t * Sets the letter spacing property. null defaults it to the default style's value.\n\t *\n\t * @type {?number}\n\t */\n\tset letterSpacing(value: number) {\n\t\tthis._letterSpacing = SpanStyles._valueOrDefault(value, this._defaultStyle.letterSpacing);\n\t}\n\n\t/**\n\t * Gets the X-axis rotation property.\n\t *\n\t * @type {?number}\n\t */\n\tget rotationX() {\n\t\treturn this._rotationX;\n\t}\n\n\t/**\n\t * Sets the X-axis rotation property.\n\t *\n\t * @type {?number}\n\t */\n\tset rotationX(value: number) {\n\t\tthis._rotationX = value;\n\t}\n\n\t/**\n\t * Gets the Y-axis rotation property.\n\t *\n\t * @type {?number}\n\t */\n\tget rotationY() {\n\t\treturn this._rotationY;\n\t}\n\n\t/**\n\t * Sets the Y-axis rotation property.\n\t *\n\t * @type {?number}\n\t */\n\tset rotationY(value: number) {\n\t\tthis._rotationY = value;\n\t}\n\n\t/**\n\t * Gets the Z-axis rotation property.\n\t *\n\t * @type {?number}\n\t */\n\tget rotationZ() {\n\t\treturn this._rotationZ;\n\t}\n\n\t/**\n\t * Sets the Z-axis rotation property.\n\t *\n\t * @type {?number}\n\t */\n\tset rotationZ(value: number) {\n\t\tthis._rotationZ = SpanStyles._valueOrDefault(value, this._defaultStyle.rotationZ);\n\t}\n\n\t/**\n\t * Gets the X-axis skew property.\n\t *\n\t * @type {?number}\n\t */\n\tget skewX() {\n\t\treturn this._skewX;\n\t}\n\n\t/**\n\t * Sets the X-axis skew property.\n\t *\n\t * @type {?number}\n\t */\n\tset skewX(value: number) {\n\t\tthis._skewX = value;\n\t}\n\n\t/**\n\t * Gets the Y-axis skew property.\n\t *\n\t * @type {?number}\n\t */\n\tget skewY() {\n\t\treturn this._skewY;\n\t}\n\n\t/**\n\t * Sets the Y-axis skew property.\n\t *\n\t * @type {?number}\n\t */\n\tset skewY(value: number) {\n\t\tthis._skewY = value;\n\t}\n\n\t/**\n\t * Gets the primary color property.\n\t *\n\t * @type {!libjass.Color}\n\t */\n\tget primaryColor(): Color {\n\t\treturn this._primaryColor;\n\t}\n\n\t/**\n\t * Sets the primary color property. null defaults it to the default style's value.\n\t *\n\t * @type {libjass.Color}\n\t */\n\tset primaryColor(value: Color) {\n\t\tthis._primaryColor = SpanStyles._valueOrDefault(value, this._defaultStyle.primaryColor);\n\t}\n\n\t/**\n\t * Gets the secondary color property.\n\t *\n\t * @type {!libjass.Color}\n\t */\n\tget secondaryColor(): Color {\n\t\treturn this._secondaryColor;\n\t}\n\n\t/**\n\t * Sets the secondary color property. null defaults it to the default style's value.\n\t *\n\t * @type {libjass.Color}\n\t */\n\tset secondaryColor(value: Color) {\n\t\tthis._secondaryColor = SpanStyles._valueOrDefault(value, this._defaultStyle.secondaryColor);\n\t}\n\n\t/**\n\t * Gets the outline color property.\n\t *\n\t * @type {!libjass.Color}\n\t */\n\tget outlineColor(): Color {\n\t\treturn this._outlineColor;\n\t}\n\n\t/**\n\t * Sets the outline color property. null defaults it to the default style's value.\n\t *\n\t * @type {libjass.Color}\n\t */\n\tset outlineColor(value: Color) {\n\t\tthis._outlineColor = SpanStyles._valueOrDefault(value, this._defaultStyle.outlineColor);\n\t}\n\n\t/**\n\t * Gets the shadow color property.\n\t *\n\t * @type {!libjass.Color}\n\t */\n\tget shadowColor(): Color {\n\t\treturn this._shadowColor;\n\t}\n\n\t/**\n\t * Sets the shadow color property. null defaults it to the default style's value.\n\t *\n\t * @type {libjass.Color}\n\t */\n\tset shadowColor(value: Color) {\n\t\tthis._shadowColor = SpanStyles._valueOrDefault(value, this._defaultStyle.shadowColor);\n\t}\n\n\t/**\n\t * Gets the primary alpha property.\n\t *\n\t * @type {number}\n\t */\n\tget primaryAlpha(): number {\n\t\treturn this._primaryAlpha;\n\t}\n\n\t/**\n\t * Sets the primary alpha property.\n\t *\n\t * @type {?number}\n\t */\n\tset primaryAlpha(value: number) {\n\t\tthis._primaryAlpha = SpanStyles._valueOrDefault(value, this._defaultStyle.primaryColor.alpha);\n\t}\n\n\t/**\n\t * Gets the secondary alpha property.\n\t *\n\t * @type {number}\n\t */\n\tget secondaryAlpha(): number {\n\t\treturn this._secondaryAlpha;\n\t}\n\n\t/**\n\t * Sets the secondary alpha property.\n\t *\n\t * @type {?number}\n\t */\n\tset secondaryAlpha(value: number) {\n\t\tthis._secondaryAlpha = SpanStyles._valueOrDefault(value, this._defaultStyle.secondaryColor.alpha);\n\t}\n\n\t/**\n\t * Gets the outline alpha property.\n\t *\n\t * @type {number}\n\t */\n\tget outlineAlpha(): number {\n\t\treturn this._outlineAlpha;\n\t}\n\n\t/**\n\t * Sets the outline alpha property.\n\t *\n\t * @type {?number}\n\t */\n\tset outlineAlpha(value: number) {\n\t\tthis._outlineAlpha = SpanStyles._valueOrDefault(value, this._defaultStyle.outlineColor.alpha);\n\t}\n\n\t/**\n\t * Gets the shadow alpha property.\n\t *\n\t * @type {number}\n\t */\n\tget shadowAlpha(): number {\n\t\treturn this._shadowAlpha;\n\t}\n\n\t/**\n\t * Sets the shadow alpha property.\n\t *\n\t * @type {?number}\n\t */\n\tset shadowAlpha(value: number) {\n\t\tthis._shadowAlpha = SpanStyles._valueOrDefault(value, this._defaultStyle.shadowColor.alpha);\n\t}\n\n\tprivate static _valueOrDefault = <T>(newValue: T, defaultValue: T): T => ((newValue !== null) ? newValue : defaultValue);\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * Debug mode. When true, libjass logs some debug messages.\n *\n * @type {boolean}\n */\nexport let debugMode: boolean = false;\n\n/**\n * Verbose debug mode. When true, libjass logs some more debug messages. This setting is independent of {@link libjass.debugMode}\n *\n * @type {boolean}\n */\nexport let verboseMode: boolean = false;\n\n/**\n * Sets the debug mode.\n *\n * @param {boolean} value\n */\nexport function setDebugMode(value: boolean): void {\n\tdebugMode = value;\n}\n\n/**\n * Sets the verbose debug mode.\n *\n * @param {boolean} value\n */\nexport function setVerboseMode(value: boolean): void {\n\tverboseMode = value;\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Attachment } from \"./attachment\";\nimport { Dialogue } from \"./dialogue\";\nimport { Style } from \"./style\";\nimport { ScriptProperties } from \"./script-properties\";\n\nimport { Format } from \"./misc\";\n\nimport { verboseMode } from \"../settings\";\n\nimport * as parser from \"../parser\";\nimport { parseLineIntoTypedTemplate } from \"../parser/misc\";\nimport { ReadableStream, TextDecoder, TextDecoderConstructor } from \"../parser/streams\";\n\nimport { Map } from \"../utility/map\";\nimport { Promise } from \"../utility/promise\";\n\ndeclare const global: {\n\tfetch?(url: string): Promise<{ body: ReadableStream; ok?: boolean; status?: number; }>;\n\tReadableStream?: { prototype: ReadableStream; };\n\tTextDecoder?: TextDecoderConstructor;\n};\n\n/**\n * This class represents an ASS script. It contains the {@link libjass.ScriptProperties}, an array of {@link libjass.Style}s, and an array of {@link libjass.Dialogue}s.\n */\nexport class ASS {\n\tprivate _properties: ScriptProperties = new ScriptProperties();\n\tprivate _styles: Map<string, Style> = new Map<string, Style>();\n\tprivate _dialogues: Dialogue[] = [];\n\tprivate _attachments: Attachment[] = [];\n\n\tprivate _stylesFormatSpecifier: string[] = null;\n\tprivate _dialoguesFormatSpecifier: string[] = null;\n\n\t/**\n\t * The properties of this script.\n\t *\n\t * @type {!libjass.ScriptProperties}\n\t */\n\tget properties(): ScriptProperties {\n\t\treturn this._properties;\n\t}\n\n\t/**\n\t * The styles in this script.\n\t *\n\t * @type {!Map.<string, !libjass.Style>}\n\t */\n\tget styles(): Map<string, Style> {\n\t\treturn this._styles;\n\t}\n\n\t/**\n\t * The dialogues in this script.\n\t *\n\t * @type {!Array.<!libjass.Dialogue>}\n\t */\n\tget dialogues(): Dialogue[] {\n\t\treturn this._dialogues;\n\t}\n\n\t/**\n\t * The attachments of this script.\n\t *\n\t * @type {!Array.<!libjass.Attachment>}\n\t */\n\tget attachments(): Attachment[] {\n\t\treturn this._attachments;\n\t}\n\n\t/**\n\t * The format specifier for the styles section.\n\t *\n\t * @type {!Array.<string>}\n\t */\n\tget stylesFormatSpecifier(): string[] {\n\t\treturn this._stylesFormatSpecifier;\n\t}\n\n\t/**\n\t * The format specifier for the styles section.\n\t *\n\t * @type {!Array.<string>}\n\t */\n\tget dialoguesFormatSpecifier(): string[] {\n\t\treturn this._dialoguesFormatSpecifier;\n\t}\n\n\t/**\n\t * The format specifier for the events section.\n\t *\n\t * @type {!Array.<string>}\n\t */\n\tset stylesFormatSpecifier(value: string[]) {\n\t\tthis._stylesFormatSpecifier = value;\n\t}\n\n\t/**\n\t * The format specifier for the events section.\n\t *\n\t * @type {!Array.<string>}\n\t */\n\tset dialoguesFormatSpecifier(value: string[]) {\n\t\tthis._dialoguesFormatSpecifier = value;\n\t}\n\n\tconstructor() {\n\t\t// Deprecated constructor argument\n\t\tif (arguments.length === 1) {\n\t\t\tthrow new Error(\"Constructor `new ASS(rawASS)` has been deprecated. Use `ASS.fromString(rawASS)` instead.\");\n\t\t}\n\n\t\tthis._styles.set(\"Default\", new Style(new Map([[\"Name\", \"Default\"]])));\n\t}\n\n\t/**\n\t * Add a style to this ASS script.\n\t *\n\t * @param {string} line The line from the script that contains the new style.\n\t */\n\taddStyle(line: string): void {\n\t\tconst styleLine = parseLineIntoTypedTemplate(line, this._stylesFormatSpecifier);\n\t\tif (styleLine === null || styleLine.type !== \"Style\") {\n\t\t\treturn;\n\t\t}\n\n\t\tconst styleTemplate = styleLine.template;\n\n\t\tif (verboseMode) {\n\t\t\tlet repr = \"\";\n\t\t\tstyleTemplate.forEach((value, key) => repr += `${ key } = ${ value }, `);\n\t\t\tconsole.log(`Read style: ${ repr }`);\n\t\t}\n\n\t\t// Create the dialogue and add it to the dialogues array\n\t\tconst style = new Style(styleTemplate);\n\t\tthis._styles.set(style.name, style);\n\t}\n\n\t/**\n\t * Add an event to this ASS script.\n\t *\n\t * @param {string} line The line from the script that contains the new event.\n\t */\n\taddEvent(line: string): void {\n\t\tconst dialogueLine = parseLineIntoTypedTemplate(line, this._dialoguesFormatSpecifier);\n\t\tif (dialogueLine === null || dialogueLine.type !== \"Dialogue\") {\n\t\t\treturn;\n\t\t}\n\n\t\tconst dialogueTemplate = dialogueLine.template;\n\n\t\tif (verboseMode) {\n\t\t\tlet repr = \"\";\n\t\t\tdialogueTemplate.forEach((value, key) => repr += `${ key } = ${ value }, `);\n\t\t\tconsole.log(`Read dialogue: ${ repr }`);\n\t\t}\n\n\t\t// Create the dialogue and add it to the dialogues array\n\t\tthis.dialogues.push(new Dialogue(dialogueTemplate, this));\n\t}\n\n\t/**\n\t * Add an attachment to this ASS script.\n\t *\n\t * @param {!libjass.Attachment} attachment\n\t */\n\taddAttachment(attachment: Attachment): void {\n\t\tthis._attachments.push(attachment);\n\t}\n\n\t/**\n\t * Creates an ASS object from the raw text of an ASS script.\n\t *\n\t * @param {string} raw The raw text of the script.\n\t * @param {number=0} type The type of the script. One of the {@link libjass.Format} constants.\n\t * @return {!Promise.<!libjass.ASS>}\n\t */\n\tstatic fromString(raw: string, type: Format = Format.ASS): Promise<ASS> {\n\t\treturn ASS.fromStream(new parser.StringStream(raw), type);\n\t}\n\n\t/**\n\t * Creates an ASS object from the given {@link libjass.parser.Stream}.\n\t *\n\t * @param {!libjass.parser.Stream} stream The stream to parse the script from\n\t * @param {number=0} type The type of the script. One of the {@link libjass.Format} constants.\n\t * @return {!Promise.<!libjass.ASS>} A promise that will be resolved with the ASS object when it has been fully parsed\n\t */\n\tstatic fromStream(stream: parser.Stream, type: Format = Format.ASS): Promise<ASS> {\n\t\tswitch (type) {\n\t\t\tcase Format.ASS:\n\t\t\t\treturn new parser.StreamParser(stream).ass;\n\t\t\tcase Format.SRT:\n\t\t\t\treturn new parser.SrtStreamParser(stream).ass;\n\t\t\tdefault:\n\t\t\t\tthrow new Error(`Illegal value of type: ${ type }`);\n\t\t}\n\t}\n\n\t/**\n\t * Creates an ASS object from the given URL.\n\t *\n\t * @param {string} url The URL of the script.\n\t * @param {number=0} type The type of the script. One of the {@link libjass.Format} constants.\n\t * @return {!Promise.<!libjass.ASS>} A promise that will be resolved with the ASS object when it has been fully parsed\n\t */\n\tstatic fromUrl(url: string, type: Format = Format.ASS): Promise<ASS> {\n\t\tlet fetchPromise: Promise<ASS>;\n\n\t\tif (\n\t\t\ttypeof global.fetch === \"function\" &&\n\t\t\ttypeof global.ReadableStream === \"function\" && typeof global.ReadableStream.prototype.getReader === \"function\" &&\n\t\t\ttypeof global.TextDecoder === \"function\"\n\t\t) {\n\t\t\tfetchPromise = global.fetch(url).then(response => {\n\t\t\t\tif (response.ok === false || (response.ok === undefined && (response.status < 200 || response.status > 299))) {\n\t\t\t\t\tthrow new Error(`HTTP request for ${ url } failed with status code ${ response.status }`);\n\t\t\t\t}\n\n\t\t\t\treturn ASS.fromReadableStream(response.body, \"utf-8\", type);\n\t\t\t});\n\t\t}\n\t\telse {\n\t\t\tfetchPromise = Promise.reject<ASS>(new Error(\"Not supported.\"));\n\t\t}\n\n\t\treturn fetchPromise.catch(reason => {\n\t\t\tconsole.warn(\"fetch() failed, falling back to XHR: %o\", reason);\n\n\t\t\tconst xhr = new XMLHttpRequest();\n\t\t\tconst result = ASS.fromStream(new parser.XhrStream(xhr), type);\n\t\t\txhr.open(\"GET\", url, true);\n\t\t\txhr.send();\n\t\t\treturn result;\n\t\t});\n\t}\n\n\t/**\n\t * Creates an ASS object from the given ReadableStream.\n\t *\n\t * @param {!ReadableStream} stream\n\t * @param {string=\"utf-8\"} encoding\n\t * @param {number=0} type The type of the script. One of the {@link libjass.Format} constants.\n\t * @return {!Promise.<!libjass.ASS>} A promise that will be resolved with the ASS object when it has been fully parsed\n\t */\n\tstatic fromReadableStream(stream: ReadableStream, encoding: string = \"utf-8\", type: Format = Format.ASS): Promise<ASS> {\n\t\treturn ASS.fromStream(new parser.BrowserReadableStream(stream, encoding), type);\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * The type of an attachment.\n */\nexport enum AttachmentType {\n\tFont,\n\tGraphic,\n}\n\n/**\n * This class represents an attachment in a {@link libjass.ASS} script.\n *\n * @param {string} filename The filename of this attachment.\n * @param {number} type The type of this attachment.\n */\nexport class Attachment {\n\tprivate _contents: string = \"\";\n\n\tconstructor(private _filename: string, private _type: AttachmentType) { }\n\n\t/**\n\t * The filename of this attachment.\n\t *\n\t * @type {number}\n\t */\n\tget filename(): string {\n\t\treturn this._filename;\n\t}\n\n\t/**\n\t * The type of this attachment.\n\t *\n\t * @type {number}\n\t */\n\tget type(): AttachmentType {\n\t\treturn this._type;\n\t}\n\n\t/**\n\t * The contents of this attachment in base64 encoding.\n\t *\n\t * @type {number}\n\t */\n\tget contents(): string {\n\t\treturn this._contents;\n\t}\n\n\t/**\n\t * The contents of this attachment in base64 encoding.\n\t *\n\t * @type {number}\n\t */\n\tset contents(value: string) {\n\t\tthis._contents = value;\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { ASS } from \"./ass\";\nimport { Style } from \"./style\";\n\nimport { valueOrDefault } from \"./misc\";\n\nimport { parseLineIntoTypedTemplate } from \"../parser/misc\";\n\nimport { parse } from \"../parser/parse\";\n\nimport * as parts from \"../parts\";\n\nimport { debugMode } from \"../settings\";\n\nimport { Map } from \"../utility/map\";\n\n/**\n * This class represents a dialogue in a {@link libjass.ASS} script.\n *\n * @param {!Map.<string, string>} template The template object that contains the dialogue's properties. It is a map of the string values read from the ASS file.\n * @param {string} template[\"Style\"] The name of the default style of this dialogue\n * @param {string} template[\"Start\"] The start time\n * @param {string} template[\"End\"] The end time\n * @param {string} template[\"Layer\"] The layer number\n * @param {string} template[\"Text\"] The text of this dialogue\n * @param {!libjass.ASS} ass The ASS object to which this dialogue belongs\n */\nexport class Dialogue {\n\tprivate static _lastDialogueId = -1;\n\n\tprivate _id: number;\n\n\tprivate _style: Style;\n\n\tprivate _start: number;\n\tprivate _end: number;\n\n\tprivate _layer: number;\n\tprivate _alignment: number;\n\n\tprivate _rawPartsString: string;\n\tprivate _parts: parts.Part[] = null;\n\n\tprivate _containsTransformTag: boolean = false;\n\n\tconstructor(template: Map<string, string>, ass: ASS) {\n\t\t{\n\t\t\tconst normalizedTemplate = new Map<string, string>();\n\t\t\ttemplate.forEach((value, key) => {\n\t\t\t\tnormalizedTemplate.set(key.toLowerCase(), value);\n\t\t\t});\n\t\t\ttemplate = normalizedTemplate;\n\t\t}\n\n\t\tthis._id = ++Dialogue._lastDialogueId;\n\n\t\tlet styleName = template.get(\"style\");\n\t\tif (styleName !== undefined && styleName !== null && styleName.constructor === String) {\n\t\t\tstyleName = styleName.replace(/^\\*+/, \"\");\n\t\t\tif (styleName.match(/^Default$/i) !== null) {\n\t\t\t\tstyleName = \"Default\";\n\t\t\t}\n\t\t}\n\n\t\tthis._style = ass.styles.get(styleName);\n\t\tif (this._style === undefined) {\n\t\t\tif (debugMode) {\n\t\t\t\tconsole.warn(`Unrecognized style ${ styleName }. Falling back to \"Default\"`);\n\t\t\t}\n\n\t\t\tthis._style = ass.styles.get(\"Default\");\n\t\t}\n\t\tif (this._style === undefined) {\n\t\t\tthrow new Error(`Unrecognized style ${ styleName }`);\n\t\t}\n\n\t\tthis._start = Dialogue._toTime(template.get(\"start\"));\n\t\tthis._end = Dialogue._toTime(template.get(\"end\"));\n\n\t\tthis._layer = Math.max(valueOrDefault(template, \"layer\", parseInt, value => !isNaN(value), \"0\"), 0);\n\n\t\tthis._rawPartsString = template.get(\"text\");\n\t\tif (this._rawPartsString === undefined || this._rawPartsString === null || this._rawPartsString.constructor !== String) {\n\t\t\tthrow new Error(\"Dialogue doesn't have any text.\");\n\t\t}\n\t}\n\n\t/**\n\t * The unique ID of this dialogue. Auto-generated.\n\t *\n\t * @type {number}\n\t */\n\tget id(): number {\n\t\treturn this._id;\n\t}\n\n\t/**\n\t * The start time of this dialogue.\n\t *\n\t * @type {number}\n\t */\n\tget start(): number {\n\t\treturn this._start;\n\t}\n\n\t/**\n\t * The end time of this dialogue.\n\t *\n\t * @type {number}\n\t */\n\tget end(): number {\n\t\treturn this._end;\n\t}\n\n\t/**\n\t * The default style of this dialogue.\n\t *\n\t * @type {!libjass.Style}\n\t */\n\tget style(): Style {\n\t\treturn this._style;\n\t}\n\n\t/**\n\t * The alignment number of this dialogue.\n\t *\n\t * @type {number}\n\t */\n\tget alignment(): number {\n\t\tif (this._parts === null) {\n\t\t\tthis._parsePartsString();\n\t\t}\n\n\t\treturn this._alignment;\n\t}\n\n\t/**\n\t * The layer number of this dialogue.\n\t *\n\t * @type {number}\n\t */\n\tget layer(): number {\n\t\treturn this._layer;\n\t}\n\n\t/**\n\t * The {@link libjass.parts} of this dialogue.\n\t *\n\t * @type {!Array.<!libjass.parts.Part>}\n\t */\n\tget parts(): parts.Part[] {\n\t\tif (this._parts === null) {\n\t\t\tthis._parsePartsString();\n\t\t}\n\n\t\treturn this._parts;\n\t}\n\n\t/**\n\t * Convenience getter for whether this dialogue contains a {\\t} tag.\n\t *\n\t * @type {boolean}\n\t */\n\tget containsTransformTag(): boolean {\n\t\tif (this._parts === null) {\n\t\t\tthis._parsePartsString();\n\t\t}\n\n\t\treturn this._containsTransformTag;\n\t}\n\n\t/**\n\t * @return {string} A simple representation of this dialogue's properties and parts.\n\t */\n\ttoString(): string {\n\t\treturn `#${ this._id } [${ this._start.toFixed(3) }-${ this._end.toFixed(3) }] ${ (this._parts !== null) ? this._parts.join(\", \") : this._rawPartsString }`;\n\t}\n\n\t/**\n\t * Parses this dialogue's parts from the raw parts string.\n\t */\n\tprivate _parsePartsString(): void {\n\t\tthis._parts = <parts.Part[]>parse(this._rawPartsString, \"dialogueParts\");\n\n\t\tthis._alignment = this._style.alignment;\n\n\t\tthis._parts.forEach((part, index) => {\n\t\t\tif (part instanceof parts.Alignment) {\n\t\t\t\tthis._alignment = part.value;\n\t\t\t}\n\t\t\telse if (part instanceof parts.Move) {\n\t\t\t\tif (part.t1 === null || part.t2 === null) {\n\t\t\t\t\tthis._parts[index] =\n\t\t\t\t\t\tnew parts.Move(\n\t\t\t\t\t\t\tpart.x1, part.y1, part.x2, part.y2,\n\t\t\t\t\t\t\t0, this._end - this._start\n\t\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (part instanceof parts.Transform) {\n\t\t\t\tif (part.start === null || part.end === null || part.accel === null) {\n\t\t\t\t\tthis._parts[index] =\n\t\t\t\t\t\tnew parts.Transform(\n\t\t\t\t\t\t\t(part.start === null) ? 0 : part.start,\n\t\t\t\t\t\t\t(part.end === null) ? (this._end - this._start) : part.end,\n\t\t\t\t\t\t\t(part.accel === null) ? 1 : part.accel,\n\t\t\t\t\t\t\tpart.tags\n\t\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\tthis._containsTransformTag = true;\n\t\t\t}\n\t\t});\n\n\t\tif (debugMode) {\n\t\t\tconst possiblyIncorrectParses = this._parts.filter(part => part instanceof parts.Comment && part.value.indexOf(\"\\\\\") !== -1);\n\t\t\tif (possiblyIncorrectParses.length > 0) {\n\t\t\t\tconsole.warn(\n`Possible incorrect parse:\n${ this._rawPartsString }\nwas parsed as\n${ this.toString() }\nThe possibly incorrect parses are:\n${ possiblyIncorrectParses.join(\"\\n\") }`\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t}\n\n\t/**\n\t * Converts this string into the number of seconds it represents. This string must be in the form of hh:mm:ss.MMM\n\t *\n\t * @param {string} str\n\t * @return {number}\n\t */\n\tprivate static _toTime(str: string): number {\n\t\treturn str.split(\":\").reduce<number>((previousValue, currentValue) => previousValue * 60 + parseFloat(currentValue), 0);\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Map } from \"../utility/map\";\n\n/**\n * The format of the string passed to {@link libjass.ASS.fromString}\n */\nexport enum Format {\n\tASS,\n\tSRT,\n}\n\n/**\n * The wrapping style defined in the {@link libjass.ScriptProperties}\n */\nexport enum WrappingStyle {\n\tSmartWrappingWithWiderTopLine = 0,\n\tSmartWrappingWithWiderBottomLine = 3,\n\tEndOfLineWrapping = 1,\n\tNoLineWrapping = 2,\n}\n\n/**\n * The border style defined in the {@link libjass.Style} properties.\n */\nexport enum BorderStyle {\n\tOutline = 1,\n\tOpaqueBox = 3,\n}\n\n/**\n * A property.\n */\nexport interface Property {\n\t/**\n\t * @type {string}\n\t */\n\tname: string;\n\n\t/**\n\t * @type {string}\n\t */\n\tvalue: string;\n}\n\n/**\n * A template object with a particular type.\n */\nexport interface TypedTemplate {\n\t/**\n\t * @type {string}\n\t */\n\ttype: string;\n\n\t/**\n\t * @type {!Map.<string, string>}\n\t */\n\ttemplate: Map<string, string>;\n}\n\n/**\n * @param {!Map.<string, string>} template\n * @param {string} key\n * @param {function(string):T} converter\n * @param {?function(T):boolean} validator\n * @param {T} defaultValue\n * @return {T}\n */\nexport function valueOrDefault<T>(template: Map<string, string>, key: string, converter: (str: string) => T, validator: (value: T) => boolean, defaultValue: string): T {\n\tconst value = template.get(key);\n\tif (value === undefined) {\n\t\treturn converter(defaultValue);\n\t}\n\n\ttry {\n\t\tconst result = converter(value);\n\n\t\tif (validator !== null && !validator(result)) {\n\t\t\tthrow new Error(\"Validation failed.\");\n\t\t}\n\n\t\treturn result;\n\t}\n\tcatch (ex) {\n\t\tthrow new Error(`Property ${ key } has invalid value ${ value } - ${ ex.stack }`);\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { WrappingStyle } from \"./misc\";\n\n/**\n * This class represents the properties of a {@link libjass.ASS} script.\n */\nexport class ScriptProperties {\n\tprivate _resolutionX: number;\n\tprivate _resolutionY: number;\n\tprivate _wrappingStyle: WrappingStyle;\n\tprivate _scaleBorderAndShadow: boolean;\n\n\t/**\n\t * The horizontal script resolution.\n\t *\n\t * @type {number}\n\t */\n\tget resolutionX(): number {\n\t\treturn this._resolutionX;\n\t}\n\n\t/**\n\t * The horizontal script resolution.\n\t *\n\t * @type {number}\n\t */\n\tset resolutionX(value: number) {\n\t\tthis._resolutionX = value;\n\t}\n\n\t/**\n\t * The vertical script resolution.\n\t *\n\t * @type {number}\n\t */\n\tget resolutionY(): number {\n\t\treturn this._resolutionY;\n\t}\n\n\t/**\n\t * The vertical script resolution.\n\t *\n\t * @type {number}\n\t */\n\tset resolutionY(value: number) {\n\t\tthis._resolutionY = value;\n\t}\n\n\t/**\n\t * The wrap style. One of the {@link libjass.WrappingStyle} constants.\n\t *\n\t * @type {number}\n\t */\n\tget wrappingStyle(): WrappingStyle {\n\t\treturn this._wrappingStyle;\n\t}\n\n\t/**\n\t * The wrap style. One of the {@link libjass.WrappingStyle} constants.\n\t *\n\t * @type {number}\n\t */\n\tset wrappingStyle(value: WrappingStyle) {\n\t\tthis._wrappingStyle = value;\n\t}\n\n\t/**\n\t * Whether to scale outline widths and shadow depths from script resolution to video resolution or not. If true, widths and depths are scaled.\n\t *\n\t * @type {boolean}\n\t */\n\tget scaleBorderAndShadow(): boolean {\n\t\treturn this._scaleBorderAndShadow;\n\t}\n\n\t/**\n\t * Whether to scale outline widths and shadow depths from script resolution to video resolution or not. If true, widths and depths are scaled.\n\t *\n\t * @type {boolean}\n\t */\n\tset scaleBorderAndShadow(value: boolean) {\n\t\tthis._scaleBorderAndShadow = value;\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { valueOrDefault, BorderStyle } from \"./misc\";\n\nimport { parse } from \"../parser/parse\";\n\nimport { Color } from \"../parts\";\n\nimport { Map } from \"../utility/map\";\n\n/**\n * This class represents a single global style declaration in a {@link libjass.ASS} script. The styles can be obtained via the {@link libjass.ASS.styles} property.\n *\n * @param {!Map.<string, string>} template The template object that contains the style's properties. It is a map of the string values read from the ASS file.\n * @param {string} template[\"Name\"] The name of the style\n * @param {string} template[\"Italic\"] -1 if the style is italicized\n * @param {string} template[\"Bold\"] -1 if the style is bold\n * @param {string} template[\"Underline\"] -1 if the style is underlined\n * @param {string} template[\"StrikeOut\"] -1 if the style is struck-through\n * @param {string} template[\"Fontname\"] The name of the font\n * @param {string} template[\"Fontsize\"] The size of the font\n * @param {string} template[\"ScaleX\"] The horizontal scaling of the font\n * @param {string} template[\"ScaleY\"] The vertical scaling of the font\n * @param {string} template[\"Spacing\"] The letter spacing of the font\n * @param {string} template[\"PrimaryColour\"] The primary color\n * @param {string} template[\"OutlineColour\"] The outline color\n * @param {string} template[\"BackColour\"] The shadow color\n * @param {string} template[\"Outline\"] The outline thickness\n * @param {string} template[\"Shadow\"] The shadow depth\n * @param {string} template[\"Alignment\"] The alignment number\n * @param {string} template[\"MarginL\"] The left margin\n * @param {string} template[\"MarginR\"] The right margin\n * @param {string} template[\"MarginV\"] The vertical margin\n */\nexport class Style {\n\tprivate _name: string;\n\n\tprivate _italic: boolean;\n\tprivate _bold: boolean;\n\tprivate _underline: boolean;\n\tprivate _strikeThrough: boolean;\n\n\tprivate _fontName: string;\n\tprivate _fontSize: number;\n\n\tprivate _fontScaleX: number;\n\tprivate _fontScaleY: number;\n\n\tprivate _letterSpacing: number;\n\n\tprivate _rotationZ: number;\n\n\tprivate _primaryColor: Color;\n\tprivate _secondaryColor: Color;\n\tprivate _outlineColor: Color;\n\tprivate _shadowColor: Color;\n\n\tprivate _outlineThickness: number;\n\tprivate _borderStyle: BorderStyle;\n\n\tprivate _shadowDepth: number;\n\n\tprivate _alignment: number;\n\n\tprivate _marginLeft: number;\n\tprivate _marginRight: number;\n\tprivate _marginVertical: number;\n\n\tconstructor(template: Map<string, string>) {\n\t\t{\n\t\t\tconst normalizedTemplate = new Map<string, string>();\n\t\t\ttemplate.forEach((value, key) => {\n\t\t\t\tnormalizedTemplate.set(key.toLowerCase(), value);\n\t\t\t});\n\t\t\ttemplate = normalizedTemplate;\n\t\t}\n\n\t\tthis._name = template.get(\"name\");\n\t\tif (this._name === undefined || this._name === null || this._name.constructor !== String) {\n\t\t\tthrow new Error(\"Style doesn't have a name.\");\n\t\t}\n\t\tthis._name = this._name.replace(/^\\*+/, \"\");\n\n\t\tthis._italic = !!valueOrDefault(template, \"italic\", parseFloat, value => !isNaN(value), \"0\");\n\t\tthis._bold = !!valueOrDefault(template, \"bold\", parseFloat, value => !isNaN(value), \"0\");\n\t\tthis._underline = !!valueOrDefault(template, \"underline\", parseFloat, value => !isNaN(value), \"0\");\n\t\tthis._strikeThrough = !!valueOrDefault(template, \"strikeout\", parseFloat, value => !isNaN(value), \"0\");\n\n\t\tthis._fontName = valueOrDefault(template, \"fontname\", str => str, value => value.constructor === String, \"sans-serif\");\n\t\tthis._fontSize = valueOrDefault(template, \"fontsize\", parseFloat, value => !isNaN(value), \"18\");\n\n\t\tthis._fontScaleX = valueOrDefault(template, \"scalex\", parseFloat, value => value >= 0, \"100\") / 100;\n\t\tthis._fontScaleY = valueOrDefault(template, \"scaley\", parseFloat, value => value >= 0, \"100\") / 100;\n\n\t\tthis._letterSpacing = valueOrDefault(template, \"spacing\", parseFloat, value => value >= 0, \"0\");\n\n\t\tthis._rotationZ = valueOrDefault(template, \"angle\", parseFloat, value => !isNaN(value), \"0\");\n\n\t\tthis._primaryColor = valueOrDefault(template, \"primarycolour\", str => <Color>parse(str, \"colorWithAlpha\"), null, \"&H00FFFFFF\");\n\t\tthis._secondaryColor = valueOrDefault(template, \"secondarycolour\", str => <Color>parse(str, \"colorWithAlpha\"), null, \"&H00FFFF00\");\n\t\tthis._outlineColor = valueOrDefault(template, \"outlinecolour\", str => <Color>parse(str, \"colorWithAlpha\"), null, \"&H00000000\");\n\t\tthis._shadowColor = valueOrDefault(template, \"backcolour\", str => <Color>parse(str, \"colorWithAlpha\"), null, \"&H80000000\");\n\n\t\tthis._outlineThickness = valueOrDefault(template, \"outline\", parseFloat, value => value >= 0, \"2\");\n\t\tthis._borderStyle = valueOrDefault(template, \"borderstyle\", parseInt, value => (<any>BorderStyle)[(<any>BorderStyle)[value]] === value, \"1\");\n\n\t\tthis._shadowDepth = valueOrDefault(template, \"shadow\", parseFloat, value => value >= 0, \"3\");\n\n\t\tthis._alignment = valueOrDefault(template, \"alignment\", parseInt, value => value >= 1 && value <= 9, \"2\");\n\n\t\tthis._marginLeft = valueOrDefault(template, \"marginl\", parseFloat, value => !isNaN(value), \"20\");\n\t\tthis._marginRight = valueOrDefault(template, \"marginr\", parseFloat, value => !isNaN(value), \"20\");\n\t\tthis._marginVertical = valueOrDefault(template, \"marginv\", parseFloat, value => !isNaN(value), \"20\");\n\t}\n\n\t/**\n\t * The name of this style.\n\t *\n\t * @type {string}\n\t */\n\tget name(): string {\n\t\treturn this._name;\n\t}\n\n\t/**\n\t * Whether this style is italicized or not.\n\t *\n\t * @type {string}\n\t */\n\tget italic(): boolean {\n\t\treturn this._italic;\n\t}\n\n\t/**\n\t * Whether this style is bold or not.\n\t *\n\t * @type {boolean}\n\t */\n\tget bold(): boolean {\n\t\treturn this._bold;\n\t}\n\n\t/**\n\t * Whether this style is underlined or not.\n\t *\n\t * @type {boolean}\n\t */\n\tget underline(): boolean {\n\t\treturn this._underline;\n\t}\n\n\t/**\n\t * Whether this style is struck-through or not.\n\t *\n\t * @type {boolean}\n\t */\n\tget strikeThrough(): boolean {\n\t\treturn this._strikeThrough;\n\t}\n\n\t/**\n\t * The name of this style's font.\n\t *\n\t * @type {string}\n\t */\n\tget fontName(): string {\n\t\treturn this._fontName;\n\t}\n\n\t/**\n\t * The size of this style's font.\n\t *\n\t * @type {number}\n\t */\n\tget fontSize(): number {\n\t\treturn this._fontSize;\n\t}\n\n\t/**\n\t * The horizontal scaling of this style's font.\n\t *\n\t * @type {number}\n\t */\n\tget fontScaleX(): number {\n\t\treturn this._fontScaleX;\n\t}\n\n\t/**\n\t * The vertical scaling of this style's font.\n\t *\n\t * @type {number}\n\t */\n\tget fontScaleY(): number {\n\t\treturn this._fontScaleY;\n\t}\n\n\t/**\n\t * The letter spacing scaling of this style's font.\n\t *\n\t * @type {number}\n\t */\n\tget letterSpacing(): number {\n\t\treturn this._letterSpacing;\n\t}\n\n\t/**\n\t * The default Z-rotation of this style.\n\t *\n\t * @type {number}\n\t */\n\tget rotationZ(): number {\n\t\treturn this._rotationZ;\n\t}\n\n\t/**\n\t * The color of this style's font.\n\t *\n\t * @type {!libjass.parts.Color}\n\t */\n\tget primaryColor(): Color {\n\t\treturn this._primaryColor;\n\t}\n\n\t/**\n\t * The alternate color of this style's font, used in karaoke.\n\t *\n\t * @type {!libjass.parts.Color}\n\t */\n\tget secondaryColor(): Color {\n\t\treturn this._secondaryColor;\n\t}\n\n\t/**\n\t * The color of this style's outline.\n\t *\n\t * @type {!libjass.parts.Color}\n\t */\n\tget outlineColor(): Color {\n\t\treturn this._outlineColor;\n\t}\n\n\t/**\n\t * The color of this style's shadow.\n\t *\n\t * @type {!libjass.parts.Color}\n\t */\n\tget shadowColor(): Color {\n\t\treturn this._shadowColor;\n\t}\n\n\t/**\n\t * The thickness of this style's outline.\n\t *\n\t * @type {number}\n\t */\n\tget outlineThickness(): number {\n\t\treturn this._outlineThickness;\n\t}\n\n\t/**\n\t * The border style of this style.\n\t *\n\t * @type {number}\n\t */\n\tget borderStyle(): BorderStyle {\n\t\treturn this._borderStyle;\n\t}\n\n\t/**\n\t * The depth of this style's shadow.\n\t *\n\t * @type {number}\n\t */\n\tget shadowDepth(): number {\n\t\treturn this._shadowDepth;\n\t}\n\n\t/**\n\t * The alignment of dialogues of this style.\n\t *\n\t * @type {number}\n\t */\n\tget alignment(): number {\n\t\treturn this._alignment;\n\t}\n\n\t/**\n\t * The left margin of dialogues of this style.\n\t *\n\t * @type {number}\n\t */\n\tget marginLeft(): number {\n\t\treturn this._marginLeft;\n\t}\n\n\t/**\n\t * The right margin of dialogues of this style.\n\t *\n\t * @type {number}\n\t */\n\tget marginRight(): number {\n\t\treturn this._marginRight;\n\t}\n\n\t/**\n\t * The vertical margin of dialogues of this style.\n\t *\n\t * @type {number}\n\t */\n\tget marginVertical(): number {\n\t\treturn this._marginVertical;\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\ndeclare const global: {\n\tMap?: typeof Map;\n};\n\nexport interface Map<K, V> {\n\t/**\n\t * @param {K} key\n\t * @return {V}\n\t */\n\tget(key: K): V;\n\n\t/**\n\t * @param {K} key\n\t * @return {boolean}\n\t */\n\thas(key: K): boolean;\n\n\t/**\n\t * @param {K} key\n\t * @param {V} value\n\t * @return {libjass.Map.<K, V>} This map\n\t */\n\tset(key: K, value?: V): Map<K, V>;\n\n\t/**\n\t * @param {K} key\n\t * @return {boolean} true if the key was present before being deleted, false otherwise\n\t */\n\tdelete(key: K): boolean;\n\n\t/**\n\t */\n\tclear(): void;\n\n\t/**\n\t * @param {function(V, K, libjass.Map.<K, V>)} callbackfn A function that is called with each key and value in the map.\n\t * @param {*} thisArg\n\t */\n\tforEach(callbackfn: (value: V, index: K, map: Map<K, V>) => void, thisArg?: any): void;\n\n\t/**\n\t * @type {number}\n\t */\n\tsize: number;\n}\n\n/**\n * Set to the global implementation of Map if the environment has one, else set to {@link ./utility/map.SimpleMap}\n *\n * Set it to null to force {@link ./utility/map.SimpleMap} to be used even if a global Map is present.\n *\n * @type {function(new:Map, !Array.<!Array.<*>>=)}\n */\nexport var Map: {\n\tnew <K, V>(iterable?: [K, V][]): Map<K, V>;\n\tprototype: Map<any, any>;\n} = global.Map;\n\n/**\n * Map implementation for browsers that don't support it. Only supports keys which are of Number or String type, or which have a property called \"id\".\n *\n * Keys and values are stored as properties of an object, with property names derived from the key type.\n *\n * @param {!Array.<!Array.<*>>=} iterable Only an array of elements (where each element is a 2-tuple of key and value) is supported.\n */\nclass SimpleMap<K, V> {\n\tprivate _keys: { [key: string]: K };\n\tprivate _values: { [key: string]: V };\n\tprivate _size: number;\n\n\tconstructor(iterable?: [K, V][]) {\n\t\tthis.clear();\n\n\t\tif (iterable === undefined) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (!Array.isArray(iterable)) {\n\t\t\tthrow new Error(\"Non-array iterables are not supported by the SimpleMap constructor.\");\n\t\t}\n\n\t\tfor (const element of iterable) {\n\t\t\tthis.set(element[0], element[1]);\n\t\t}\n\t}\n\n\t/**\n\t * @param {K} key\n\t * @return {V}\n\t */\n\tget(key: K): V {\n\t\tconst property = this._keyToProperty(key);\n\n\t\tif (property === null) {\n\t\t\treturn undefined;\n\t\t}\n\n\t\treturn this._values[property];\n\t}\n\n\t/**\n\t * @param {K} key\n\t * @return {boolean}\n\t */\n\thas(key: K): boolean {\n\t\tconst property = this._keyToProperty(key);\n\n\t\tif (property === null) {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn property in this._keys;\n\t}\n\n\t/**\n\t * @param {K} key\n\t * @param {V} value\n\t * @return {libjass.Map.<K, V>} This map\n\t */\n\tset(key: K, value: V): Map<K, V> {\n\t\tconst property = this._keyToProperty(key);\n\n\t\tif (property === null) {\n\t\t\tthrow new Error(\"This Map implementation only supports Number and String keys, or keys with an id property.\");\n\t\t}\n\n\t\tif (!(property in this._keys)) {\n\t\t\tthis._size++;\n\t\t}\n\n\t\tthis._keys[property] = key;\n\t\tthis._values[property] = value;\n\n\t\treturn this;\n\t}\n\n\t/**\n\t * @param {K} key\n\t * @return {boolean} true if the key was present before being deleted, false otherwise\n\t */\n\tdelete(key: K): boolean {\n\t\tconst property = this._keyToProperty(key);\n\n\t\tif (property === null) {\n\t\t\treturn false;\n\t\t}\n\n\t\tconst result = property in this._keys;\n\n\t\tif (result) {\n\t\t\tdelete this._keys[property];\n\t\t\tdelete this._values[property];\n\t\t\tthis._size--;\n\t\t}\n\n\t\treturn result;\n\t}\n\n\t/**\n\t */\n\tclear(): void {\n\t\tthis._keys = Object.create(null);\n\t\tthis._values = Object.create(null);\n\t\tthis._size = 0;\n\t}\n\n\t/**\n\t * @param {function(V, K, libjass.Map.<K, V>)} callbackfn A function that is called with each key and value in the map.\n\t * @param {*} thisArg\n\t */\n\tforEach(callbackfn: (value: V, index: K, map: Map<K, V>) => void, thisArg?: any): void {\n\t\tfor (const property of Object.keys(this._keys)) {\n\t\t\tcallbackfn.call(thisArg, this._values[property], this._keys[property], this);\n\t\t}\n\t}\n\n\t/**\n\t * @type {number}\n\t */\n\tget size(): number {\n\t\treturn this._size;\n\t}\n\n\t/**\n\t * Converts the given key into a property name for the internal map.\n\t *\n\t * @param {K} key\n\t * @return {string}\n\t */\n\tprivate _keyToProperty(key: K): string {\n\t\tif (typeof key === \"number\") {\n\t\t\treturn `#${ key }`;\n\t\t}\n\n\t\tif (typeof key === \"string\") {\n\t\t\treturn `'${ key }`;\n\t\t}\n\n\t\tif ((<any>key).id !== undefined) {\n\t\t\treturn `!${ (<any>key).id }`;\n\t\t}\n\n\t\treturn null;\n\t}\n}\n\nif (Map === undefined || typeof Map.prototype.forEach !== \"function\" || (() => {\n\ttry {\n\t\treturn new Map([[1, \"foo\"], [2, \"bar\"]]).size !== 2;\n\t}\n\tcatch (ex) {\n\t\treturn true;\n\t}\n})()) {\n\tMap = SimpleMap;\n}\n\n/**\n * Sets the Map implementation used by libjass to the provided one. If null, {@link ./utility/map.SimpleMap} is used.\n *\n * @param {?function(new:Map, !Array.<!Array.<*>>=)} value\n */\nexport function setImplementation(value: typeof Map): void {\n\tif (value !== null) {\n\t\tMap = value;\n\t}\n\telse {\n\t\tMap = SimpleMap;\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * Adds properties of the given mixins' prototypes to the given class's prototype.\n *\n * @param {!*} clazz\n * @param {!Array.<*>} mixins\n */\nexport function mixin(clazz: any, mixins: any[]): void {\n\tfor (const mixin of mixins) {\n\t\tfor (const name of Object.getOwnPropertyNames(mixin.prototype)) {\n\t\t\tclazz.prototype[name] = mixin.prototype[name];\n\t\t}\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\ndeclare const global: {\n\tPromise?: typeof Promise;\n\tMutationObserver?: typeof MutationObserver;\n\tWebkitMutationObserver?: typeof MutationObserver;\n\tprocess?: {\n\t\tnextTick(callback: () => void): void;\n\t}\n};\n\nexport interface Thenable<T> {\n\t/** @type {function(this:!Thenable.<T>, function(T|!Thenable.<T>), function(*))} */\n\tthen: ThenableThen<T>;\n}\n\nexport interface ThenableThen<T> {\n\t/** @type {function(this:!Thenable.<T>, function(T|!Thenable.<T>), function(*))} */\n\t(resolve: (resolution: T | Thenable<T>) => void, reject: (reason: any) => void): void;\n}\n\nexport interface Promise<T> extends Thenable<T> {\n\t/**\n\t * @param {?function(T):!Thenable.<U>} onFulfilled\n\t * @param {?function(*):(U|!Thenable.<U>)} onRejected\n\t * @return {!Promise.<U>}\n\t */\n\tthen<U>(onFulfilled?: (value: T) => Thenable<U>, onRejected?: (reason: any) => U | Thenable<U>): Promise<U>;\n\n\t/**\n\t * @param {?function(T):U} onFulfilled\n\t * @param {?function(*):(U|!Thenable.<U>)} onRejected\n\t * @return {!Promise.<U>}\n\t */\n\tthen<U>(onFulfilled?: (value: T) => U, onRejected?: (reason: any) => U | Thenable<U>): Promise<U>;\n\n\t/**\n\t * @param {function(*):(T|!Thenable.<T>)} onRejected\n\t * @return {!Promise.<T>}\n\t */\n\tcatch(onRejected?: (reason: any) => T | Thenable<T>): Promise<T>\n}\n\n/**\n * Set to the global implementation of Promise if the environment has one, else set to {@link ./utility/promise.SimplePromise}\n *\n * Set it to null to force {@link ./utility/promise.SimplePromise} to be used even if a global Promise is present.\n *\n * @type {function(new:Promise)}\n */\nexport var Promise: {\n\tnew <T>(init: (resolve: (value: T | Thenable<T>) => void, reject: (reason: any) => void) => void): Promise<T>;\n\tprototype: Promise<any>;\n\tresolve<T>(value: T | Thenable<T>): Promise<T>;\n\treject<T>(reason: any): Promise<T>;\n\tall<T>(values: (T | Thenable<T>)[]): Promise<T[]>;\n\trace<T>(values: (T | Thenable<T>)[]): Promise<T>;\n} = global.Promise;\n\n// Based on https://github.com/petkaantonov/bluebird/blob/1b1467b95442c12378d0ea280ede61d640ab5510/src/schedule.js\nconst enqueueJob: (callback: () => void) => void = (function () {\n\tconst MutationObserver = global.MutationObserver || global.WebkitMutationObserver;\n\tif (global.process !== undefined && typeof global.process.nextTick === \"function\") {\n\t\treturn (callback: () => void) => {\n\t\t\tglobal.process.nextTick(callback);\n\t\t};\n\t}\n\telse if (MutationObserver !== undefined) {\n\t\tconst pending: (() => void)[] = [];\n\t\tlet currentlyPending = false;\n\n\t\tconst div = document.createElement(\"div\");\n\n\t\tconst observer = new MutationObserver(() => {\n\t\t\tconst processing = pending.splice(0, pending.length);\n\n\t\t\tfor (const callback of processing) {\n\t\t\t\tcallback();\n\t\t\t}\n\n\t\t\tcurrentlyPending = false;\n\n\t\t\tif (pending.length > 0) {\n\t\t\t\tdiv.classList.toggle(\"foo\");\n\t\t\t\tcurrentlyPending = true;\n\t\t\t}\n\t\t});\n\n\t\tobserver.observe(div, { attributes: true });\n\n\t\treturn (callback: () => void) => {\n\t\t\tpending.push(callback);\n\n\t\t\tif (!currentlyPending) {\n\t\t\t\tdiv.classList.toggle(\"foo\");\n\t\t\t\tcurrentlyPending = true;\n\t\t\t}\n\t\t};\n\t}\n\telse {\n\t\treturn (callback: () => void) => setTimeout(callback, 0);\n\t}\n})();\n\n/**\n * Promise implementation for browsers that don't support it.\n *\n * @param {function(function(T|!Thenable.<T>), function(*))} executor\n */\nclass SimplePromise<T> {\n\tprivate _state: SimplePromiseState = SimplePromiseState.PENDING;\n\n\tprivate _fulfillReactions: FulfilledPromiseReaction<T, any>[] = [];\n\tprivate _rejectReactions: RejectedPromiseReaction<any>[] = [];\n\n\tprivate _fulfilledValue: T = null;\n\tprivate _rejectedReason: any = null;\n\n\tconstructor(executor: (resolve: (resolution: T | Thenable<T>) => void, reject: (reason: any) => void) => void) {\n\t\tif (typeof executor !== \"function\") {\n\t\t\tthrow new TypeError(`typeof executor !== \"function\"`);\n\t\t}\n\n\t\tconst { resolve, reject } = this._createResolvingFunctions();\n\t\ttry {\n\t\t\texecutor(resolve, reject);\n\t\t}\n\t\tcatch (ex) {\n\t\t\treject(ex);\n\t\t}\n\t}\n\n\t/**\n\t * @param {?function(T):(U|!Thenable.<U>)} onFulfilled\n\t * @param {?function(*):(U|!Thenable.<U>)} onRejected\n\t * @return {!Promise.<U>}\n\t */\n\tthen<U>(onFulfilled: (value: T) => U | Thenable<U>, onRejected: (reason: any) => U | Thenable<U>): Promise<U> {\n\t\tconst resultCapability = new DeferredPromise<U>();\n\n\t\tif (typeof onFulfilled !== \"function\") {\n\t\t\tonFulfilled = (value: T) => <U><any>value;\n\t\t}\n\n\t\tif (typeof onRejected !== \"function\") {\n\t\t\tonRejected = (reason: any): U => { throw reason; };\n\t\t}\n\n\t\tconst fulfillReaction: FulfilledPromiseReaction<T, U> = {\n\t\t\tcapabilities: resultCapability,\n\t\t\thandler: onFulfilled,\n\t\t};\n\n\t\tconst rejectReaction: RejectedPromiseReaction<U> = {\n\t\t\tcapabilities: resultCapability,\n\t\t\thandler: onRejected,\n\t\t};\n\n\t\tswitch (this._state) {\n\t\t\tcase SimplePromiseState.PENDING:\n\t\t\t\tthis._fulfillReactions.push(fulfillReaction);\n\t\t\t\tthis._rejectReactions.push(rejectReaction);\n\t\t\t\tbreak;\n\n\t\t\tcase SimplePromiseState.FULFILLED:\n\t\t\t\tthis._enqueueFulfilledReactionJob(fulfillReaction, this._fulfilledValue);\n\t\t\t\tbreak;\n\n\t\t\tcase SimplePromiseState.REJECTED:\n\t\t\t\tthis._enqueueRejectedReactionJob(rejectReaction, this._rejectedReason);\n\t\t\t\tbreak;\n\t\t}\n\n\t\treturn resultCapability.promise;\n\t}\n\n\t/**\n\t * @param {function(*):(T|!Thenable.<T>)} onRejected\n\t * @return {!Promise.<T>}\n\t */\n\tcatch(onRejected?: (reason: any) => T | Thenable<T>): Promise<T> {\n\t\treturn this.then(null, onRejected);\n\t}\n\n\t/**\n\t * @param {T|!Thenable.<T>} value\n\t * @return {!Promise.<T>}\n\t */\n\tstatic resolve<T>(value: T | Thenable<T>): Promise<T> {\n\t\tif (value instanceof SimplePromise) {\n\t\t\treturn value;\n\t\t}\n\n\t\treturn new Promise<T>(resolve => resolve(value));\n\t}\n\n\t/**\n\t * @param {*} reason\n\t * @return {!Promise.<T>}\n\t */\n\tstatic reject<T>(reason: any): Promise<T> {\n\t\treturn new Promise<T>((/* ujs:unreferenced */ resolve, reject) => reject(reason));\n\t}\n\n\t/**\n\t * @param {!Array.<T|!Thenable.<T>>} values\n\t * @return {!Promise.<!Array.<T>>}\n\t */\n\tstatic all<T>(values: (T | Thenable<T>)[]): Promise<T[]> {\n\t\treturn new Promise<T[]>((resolve, reject) => {\n\t\t\tconst result: T[] = [];\n\n\t\t\tlet numUnresolved = values.length;\n\t\t\tif (numUnresolved === 0) {\n\t\t\t\tresolve(result);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvalues.forEach((value, index) => Promise.resolve(value).then(value => {\n\t\t\t\tresult[index] = value;\n\t\t\t\tnumUnresolved--;\n\n\t\t\t\tif (numUnresolved === 0) {\n\t\t\t\t\tresolve(result);\n\t\t\t\t}\n\t\t\t}, reject));\n\t\t});\n\t}\n\n\t/**\n\t * @param {!Array.<T|!Thenable.<T>>} values\n\t * @return {!Promise.<T>}\n\t */\n\tstatic race<T>(values: (T | Thenable<T>)[]): Promise<T> {\n\t\treturn new Promise<T>((resolve, reject) => {\n\t\t\tfor (const value of values) {\n\t\t\t\tPromise.resolve(value).then(resolve, reject);\n\t\t\t}\n\t\t});\n\t}\n\n\t/**\n\t * @return {{ resolve(T|!Thenable.<T>), reject(*) }}\n\t */\n\tprivate _createResolvingFunctions(): { resolve(resolution: T | Thenable<T>): void; reject(reason: any): void; } {\n\t\tlet alreadyResolved = false;\n\n\t\tconst resolve = (resolution: T | Thenable<T>): void => {\n\t\t\tif (alreadyResolved) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\talreadyResolved = true;\n\n\t\t\tif (resolution === this) {\n\t\t\t\tthis._reject(new TypeError(`resolution === this`));\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (resolution === null || (typeof resolution !== \"object\" && typeof resolution !== \"function\")) {\n\t\t\t\tthis._fulfill(<T>resolution);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\ttry {\n\t\t\t\tvar then = (<Thenable<T>>resolution).then;\n\t\t\t}\n\t\t\tcatch (ex) {\n\t\t\t\tthis._reject(ex);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (typeof then !== \"function\") {\n\t\t\t\tthis._fulfill(<T>resolution);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tenqueueJob(() => this._resolveWithThenable(<Thenable<T>>resolution, then));\n\t\t};\n\n\t\tconst reject = (reason: any): void => {\n\t\t\tif (alreadyResolved) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\talreadyResolved = true;\n\n\t\t\tthis._reject(reason);\n\t\t};\n\n\t\treturn { resolve, reject };\n\t}\n\n\t/**\n\t * @param {!Thenable.<T>} thenable\n\t * @param {{function(this:!Thenable.<T>, function(T|!Thenable.<T>), function(*))}} then\n\t */\n\tprivate _resolveWithThenable(thenable: Thenable<T>, then: ThenableThen<T>): void {\n\t\tconst { resolve, reject } = this._createResolvingFunctions();\n\n\t\ttry {\n\t\t\tthen.call(thenable, resolve, reject);\n\t\t}\n\t\tcatch (ex) {\n\t\t\treject(ex);\n\t\t}\n\t}\n\n\t/**\n\t * @param {T} value\n\t */\n\tprivate _fulfill(value: T): void {\n\t\tconst reactions = this._fulfillReactions;\n\n\t\tthis._fulfilledValue = value;\n\t\tthis._fulfillReactions = undefined;\n\t\tthis._rejectReactions = undefined;\n\t\tthis._state = SimplePromiseState.FULFILLED;\n\n\t\tfor (const reaction of reactions) {\n\t\t\tthis._enqueueFulfilledReactionJob(reaction, value);\n\t\t}\n\t}\n\n\t/**\n\t * @param {*} reason\n\t */\n\tprivate _reject(reason: any): void {\n\t\tconst reactions = this._rejectReactions;\n\n\t\tthis._rejectedReason = reason;\n\t\tthis._fulfillReactions = undefined;\n\t\tthis._rejectReactions = undefined;\n\t\tthis._state = SimplePromiseState.REJECTED;\n\n\t\tfor (const reaction of reactions) {\n\t\t\tthis._enqueueRejectedReactionJob(reaction, reason);\n\t\t}\n\t}\n\n\t/**\n\t * @param {!FulfilledPromiseReaction.<T, *>} reaction\n\t * @param {T} value\n\t */\n\tprivate _enqueueFulfilledReactionJob(reaction: FulfilledPromiseReaction<T, any>, value: T): void {\n\t\tenqueueJob(() => {\n\t\t\tconst { capabilities: { resolve, reject }, handler } = reaction;\n\n\t\t\tlet handlerResult: any | Thenable<any>;\n\n\t\t\ttry {\n\t\t\t\thandlerResult = handler(value);\n\t\t\t}\n\t\t\tcatch (ex) {\n\t\t\t\treject(ex);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tresolve(handlerResult);\n\t\t});\n\t}\n\n\t/**\n\t * @param {!RejectedPromiseReaction.<*>} reaction\n\t * @param {*} reason\n\t */\n\tprivate _enqueueRejectedReactionJob(reaction: RejectedPromiseReaction<any>, reason: any): void {\n\t\tenqueueJob(() => {\n\t\t\tconst { capabilities: { resolve, reject }, handler } = reaction;\n\n\t\t\tlet handlerResult: any | Thenable<any>;\n\n\t\t\ttry {\n\t\t\t\thandlerResult = handler(reason);\n\t\t\t}\n\t\t\tcatch (ex) {\n\t\t\t\treject(ex);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tresolve(handlerResult);\n\t\t});\n\t}\n}\n\nif (Promise === undefined) {\n\tPromise = SimplePromise;\n}\n\ninterface FulfilledPromiseReaction<T, U> {\n\t/** @type {!libjass.DeferredPromise.<U>} */\n\tcapabilities: DeferredPromise<U>;\n\n\t/**\n\t * @param {T} value\n\t * @return {U|!Thenable.<U>}\n\t */\n\thandler(value: T): U | Thenable<U>;\n}\n\ninterface RejectedPromiseReaction<U> {\n\t/** @type {!libjass.DeferredPromise.<U>} */\n\tcapabilities: DeferredPromise<U>;\n\n\t/**\n\t * @param {*} reason\n\t * @return {U|!Thenable.<U>}\n\t */\n\thandler(reason: any): U | Thenable<U>;\n}\n\n/**\n * The state of the {@link ./utility/promise.SimplePromise}\n */\nenum SimplePromiseState {\n\tPENDING = 0,\n\tFULFILLED = 1,\n\tREJECTED = 2,\n}\n\n/**\n * Sets the Promise implementation used by libjass to the provided one. If null, {@link ./utility/promise.SimplePromise} is used.\n *\n * @param {?function(new:Promise)} value\n */\nexport function setImplementation(value: typeof Promise): void {\n\tif (value !== null) {\n\t\tPromise = value;\n\t}\n\telse {\n\t\tPromise = SimplePromise;\n\t}\n}\n\n/**\n * A deferred promise.\n */\nexport class DeferredPromise<T> {\n\tprivate _promise: Promise<T>;\n\n\t/**\n\t * @type {function(T|!Thenable.<T>)}\n\t */\n\tresolve: (value: T | Thenable<T>) => void;\n\n\t/**\n\t * @type {function(*)} reason\n\t */\n\treject: (reason: any) => void;\n\n\tconstructor() {\n\t\tthis._promise = new Promise<T>((resolve, reject) => {\n\t\t\tObject.defineProperties(this, {\n\t\t\t\tresolve: { value: resolve, enumerable: true },\n\t\t\t\treject: { value: reject, enumerable: true },\n\t\t\t});\n\t\t});\n\t}\n\n\t/**\n\t * @type {!Promise.<T>}\n\t */\n\tget promise(): Promise<T> {\n\t\treturn this._promise;\n\t}\n}\n\n/**\n * Returns a promise that resolves to the first (in iteration order) promise that fulfills, and rejects if all the promises reject.\n *\n * @param {!Array.<!Promise.<T>>} promises\n * @return {!Promise.<T>}\n */\nexport function first<T>(promises: Promise<T>[]): Promise<T> {\n\treturn first_rec(promises, []);\n}\n\n/**\n * @param {!Array.<!Promise.<T>>} promises\n * @param {!Array.<*>} previousRejections\n * @return {!Promise.<T>}\n */\nfunction first_rec<T>(promises: Promise<T>[], previousRejections: any[]): Promise<T> {\n\tif (promises.length === 0) {\n\t\treturn Promise.reject(previousRejections);\n\t}\n\n\tconst [head, ...tail] = promises;\n\treturn head.catch(reason => first_rec(tail, previousRejections.concat(reason)));\n}\n\n/**\n * Returns a promise that resolves to the first (in time order) promise that fulfills, and rejects if all the promises reject.\n *\n * @param {!Array.<!Promise.<T>>} promises\n * @return {!Promise.<T>}\n */\nexport function any<T>(promises: Promise<T>[]): Promise<T> {\n\treturn new Promise<T>((resolve, reject) =>\n\t\tPromise.all<any>(promises.map(promise => promise.then(resolve, reason => reason))).then(reject));\n}\n\n/**\n * Returns a promise that runs the given callback when the promise has resolved regardless of whether it fulfilled or rejected.\n *\n * @param {!Promise.<T>} promise\n * @param {function()} body\n * @return {!Promise.<T>}\n */\nexport function lastly<T>(promise: Promise<T>, body: () => void): Promise<T> {\n\treturn promise.then<any>(value => {\n\t\tbody();\n\t\treturn value;\n\t}, reason => {\n\t\tbody();\n\t\tthrow reason;\n\t});\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\ndeclare const global: {\n\tSet?: typeof Set;\n};\n\nexport interface Set<T> {\n\t/**\n\t * @param {T} value\n\t * @return {libjass.Set.<T>} This set\n\t */\n\tadd(value: T): Set<T>;\n\n\t/**\n\t */\n\tclear(): void;\n\n\t/**\n\t * @param {T} value\n\t * @return {boolean}\n\t */\n\thas(value: T): boolean;\n\n\t/**\n\t * @param {function(T, T, libjass.Set.<T>)} callbackfn A function that is called with each value in the set.\n\t * @param {*} thisArg\n\t */\n\tforEach(callbackfn: (value: T, index: T, set: Set<T>) => void, thisArg?: any): void;\n\n\t/**\n\t * @type {number}\n\t */\n\tsize: number;\n}\n\n/**\n * Set to the global implementation of Set if the environment has one, else set to {@link ./utility/set.SimpleSet}\n *\n * Set it to null to force {@link ./utility/set.SimpleSet} to be used even if a global Set is present.\n *\n * @type {function(new:Set, !Array.<T>=)}\n */\nexport var Set: {\n\tnew <T>(iterable?: T[]): Set<T>;\n\tprototype: Set<any>;\n} = global.Set;\n\n/**\n * Set implementation for browsers that don't support it. Only supports Number and String elements.\n *\n * Elements are stored as properties of an object, with names derived from their type.\n *\n * @param {!Array.<T>=} iterable Only an array of values is supported.\n */\nclass SimpleSet<T> {\n\tprivate _elements: { [key: string]: T };\n\tprivate _size: number;\n\n\tconstructor(iterable?: T[]) {\n\t\tthis.clear();\n\n\t\tif (iterable === undefined) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (!Array.isArray(iterable)) {\n\t\t\tthrow new Error(\"Non-array iterables are not supported by the SimpleSet constructor.\");\n\t\t}\n\n\t\tfor (const value of iterable) {\n\t\t\tthis.add(value);\n\t\t}\n\t}\n\n\t/**\n\t * @param {T} value\n\t * @return {libjass.Set.<T>} This set\n\t */\n\tadd(value: T): Set<T> {\n\t\tconst property = this._toProperty(value);\n\n\t\tif (property === null) {\n\t\t\tthrow new Error(\"This Set implementation only supports Number and String values.\");\n\t\t}\n\n\t\tif (!(property in this._elements)) {\n\t\t\tthis._size++;\n\t\t}\n\n\t\tthis._elements[property] = value;\n\n\t\treturn this;\n\t}\n\n\t/**\n\t */\n\tclear(): void {\n\t\tthis._elements = Object.create(null);\n\t\tthis._size = 0;\n\t}\n\n\t/**\n\t * @param {T} value\n\t * @return {boolean}\n\t */\n\thas(value: T): boolean {\n\t\tconst property = this._toProperty(value);\n\n\t\tif (property === null) {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn property in this._elements;\n\t}\n\n\t/**\n\t * @param {function(T, T, libjass.Set.<T>)} callbackfn A function that is called with each value in the set.\n\t * @param {*} thisArg\n\t */\n\tforEach(callbackfn: (value: T, index: T, set: Set<T>) => void, thisArg?: any): void {\n\t\tfor (const property of Object.keys(this._elements)) {\n\t\t\tconst element = this._elements[property];\n\t\t\tcallbackfn.call(thisArg, element, element, this);\n\t\t}\n\t}\n\n\t/**\n\t * @type {number}\n\t */\n\tget size(): number {\n\t\treturn this._size;\n\t}\n\n\t/**\n\t * Converts the given value into a property name for the internal map.\n\t *\n\t * @param {T} value\n\t * @return {string}\n\t */\n\tprivate _toProperty(value: T): string {\n\t\tif (typeof value === \"number\") {\n\t\t\treturn `#${ value }`;\n\t\t}\n\n\t\tif (typeof value === \"string\") {\n\t\t\treturn `'${ value }`;\n\t\t}\n\n\t\treturn null;\n\t}\n}\n\nif (Set === undefined || typeof Set.prototype.forEach !== \"function\" || (() => {\n\ttry {\n\t\treturn new Set([1, 2]).size !== 2;\n\t}\n\tcatch (ex) {\n\t\treturn true;\n\t}\n})()) {\n\tSet = SimpleSet;\n}\n\n/**\n * Sets the Set implementation used by libjass to the provided one. If null, {@link ./utility/set.SimpleSet} is used.\n *\n * @param {?function(new:Set, !Array.<T>=)} value\n */\nexport function setImplementation(value: typeof Set): void {\n\tif (value !== null) {\n\t\tSet = value;\n\t}\n\telse {\n\t\tSet = SimpleSet;\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * Class inheritance shim.\n *\n * @param {!Function} derived\n * @param {!Function} base\n */\nexport function __extends(derived: any, base: any): void {\n\tfor (const property in base) {\n\t\tif (base.hasOwnProperty(property)) {\n\t\t\tderived[property] = base[property];\n\t\t}\n\t}\n\n\tfunction __() {\n\t\tthis.constructor = derived;\n\t}\n\n\t__.prototype = base.prototype;\n\n\tderived.prototype = new (<any>__)();\n}\n\n/**\n * Decorator shim.\n *\n * @param {!Array.<!Function>} decorators\n * @param {!*} target\n * @param {string=} key\n * @return {*}\n */\nexport function __decorate(decorators: Function[], target: any, key?: string): any {\n\tif (arguments.length < 3) {\n\t\treturn decorateClass(<any>decorators.reverse(), target);\n\t}\n\telse {\n\t\tdecorateField(<any>decorators.reverse(), target, key);\n\t}\n}\n\n/**\n * Class decorator shim.\n *\n * @param {!Array.<function(function(new(): T)): function(new(): T)>} decorators\n * @param {function(new(): T)} clazz\n * @return {function(new(): T)}\n */\nfunction decorateClass<T>(decorators: ((clazz: { new (...args: any[]): T }) => { new (...args: any[]): T })[], clazz: { new (...args: any[]): T }): { new (...args: any[]): T } {\n\tfor (const decorator of decorators) {\n\t\tclazz = decorator(clazz) || clazz;\n\t}\n\n\treturn clazz;\n}\n\n/**\n * Class member decorator shim.\n *\n * @param {!Array.<function(T, string)>} decorators\n * @param {!T} proto\n * @param {string} name\n */\nfunction decorateField<T>(decorators: ((proto: T, name: string) => void)[], proto: T, name: string): void {\n\tfor (const decorator of decorators) {\n\t\tdecorator(proto, name);\n\t}\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Map } from \"../utility/map\";\n\nimport { Promise, DeferredPromise } from \"../utility/promise\";\n\nimport { WorkerCommands } from \"./commands\";\n\nimport { getWorkerCommandHandler, serialize, deserialize, registerWorkerCommand } from \"./misc\";\n\n/**\n * Represents a communication channel between the host and the web worker. An instance of this class is created by calling {@link libjass.webworker.createWorker}\n */\nexport interface WorkerChannel {\n\t/**\n\t * Sends a request to the other side to execute the given command with the given parameters.\n\t *\n\t * @param {number} command\n\t * @param {*} parameters\n\t * @return {!Promise.<*>} A promise that will get resolved when the other side computes the result\n\t */\n\trequest(command: WorkerCommands, parameters: any): Promise<any>;\n}\n\n/**\n * The signature of a handler registered to handle a particular command in {@link libjass.webworker.WorkerCommands}\n */\nexport interface WorkerCommandHandler {\n\t(parameters: any): Promise<any>;\n}\n\n/**\n * The interface implemented by a communication channel to the other side.\n */\ninterface WorkerCommunication {\n\t/**\n\t * @param {\"message\"} type\n\t * @param {function(!MessageEvent): *} listener\n\t * @param {?boolean} useCapture\n\t */\n\taddEventListener(type: \"message\", listener: (ev: MessageEvent) => any, useCapture?: boolean): void;\n\n\t/**\n\t * @param {string} type\n\t * @param {!EventListener} listener\n\t * @param {?boolean} useCapture\n\t */\n\taddEventListener(type: string, listener: EventListener, useCapture?: boolean): void;\n\n\t/**\n\t * @param {*} message\n\t */\n\tpostMessage(message: any): void;\n}\n\n/**\n * The interface implemented by a request sent to the other side of the communication channel.\n */\ninterface WorkerRequestMessage {\n\t/**\n\t * An internal identifier for this request. Used to connect responses to their corresponding requests.\n\t *\n\t * @type {number}\n\t */\n\trequestId: number;\n\n\t/**\n\t * The command type of this request.\n\t *\n\t * @type {number}\n\t */\n\tcommand: WorkerCommands;\n\n\t/**\n\t * Any parameters serialized with this request.\n\t *\n\t * @type {*}\n\t */\n\tparameters: any;\n}\n\n/**\n * The interface implemented by a response received from the other side of the communication channel.\n */\ninterface WorkerResponseMessage {\n\t/**\n\t * An internal identifier for this response. Used to connect responses to their corresponding requests.\n\t *\n\t * @type {number}\n\t */\n\trequestId: number;\n\n\t/**\n\t * Set if the computation of this response resulted in an error.\n\t *\n\t * @type {*}\n\t */\n\terror: any;\n\n\t/**\n\t * The result of computing this response.\n\t *\n\t * @type {*}\n\t */\n\tresult: any;\n}\n\n/**\n * Internal implementation of libjass.webworker.WorkerChannel\n *\n * @param {!*} comm The object used to talk to the other side of the channel. When created by the main thread, this is the Worker object.\n * When created by the web worker, this is its global object.\n */\nexport class WorkerChannelImpl implements WorkerChannel {\n\tprivate static _lastRequestId: number = -1;\n\n\tprivate _pendingRequests = new Map<number, DeferredPromise<any>>();\n\n\tconstructor(private _comm: WorkerCommunication) {\n\t\tthis._comm.addEventListener(\"message\", ev => this._onMessage(<string>ev.data), false);\n\t}\n\n\t/**\n\t * @param {number} command\n\t * @param {*} parameters\n\t * @return {!Promise.<*>}\n\t */\n\trequest(command: WorkerCommands, parameters: any): Promise<any> {\n\t\tconst deferred = new DeferredPromise<any>();\n\t\tconst requestId = ++WorkerChannelImpl._lastRequestId;\n\t\tthis._pendingRequests.set(requestId, deferred);\n\n\t\tconst requestMessage: WorkerRequestMessage = { requestId, command, parameters };\n\t\tthis._comm.postMessage(serialize(requestMessage));\n\n\t\treturn deferred.promise;\n\t}\n\n\t/**\n\t * @param {number} requestId\n\t */\n\tcancelRequest(requestId: number): void {\n\t\tconst deferred = this._pendingRequests.get(requestId);\n\t\tif (deferred === undefined) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._pendingRequests.delete(requestId);\n\t\tdeferred.reject(new Error(\"Cancelled.\"));\n\t}\n\n\t/**\n\t * @param {!WorkerResponseMessage} message\n\t */\n\tprivate _respond(message: WorkerResponseMessage): void {\n\t\tlet { requestId, error, result } = message;\n\t\tif (error instanceof Error) {\n\t\t\terror = { message: error.message, stack: error.stack };\n\t\t}\n\t\tthis._comm.postMessage(serialize({ command: WorkerCommands.Response, requestId, error, result }));\n\t}\n\n\t/**\n\t * @param {string} rawMessage\n\t */\n\tprivate _onMessage(rawMessage: string): void {\n\t\tconst message = <{ command: WorkerCommands }>deserialize(rawMessage);\n\n\t\tif (message.command === WorkerCommands.Response) {\n\t\t\tconst responseMessage = <WorkerResponseMessage><any>message;\n\n\t\t\tconst deferred = this._pendingRequests.get(responseMessage.requestId);\n\t\t\tif (deferred !== undefined) {\n\t\t\t\tthis._pendingRequests.delete(responseMessage.requestId);\n\t\t\t\tif (responseMessage.error === null) {\n\t\t\t\t\tdeferred.resolve(responseMessage.result);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tdeferred.reject(responseMessage.error);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\tconst requestMessage = <WorkerRequestMessage>message;\n\t\t\tconst requestId = requestMessage.requestId;\n\n\t\t\tconst commandCallback = getWorkerCommandHandler(requestMessage.command);\n\t\t\tif (commandCallback === undefined) {\n\t\t\t\tthis._respond({ requestId, error: new Error(`No handler registered for command ${ requestMessage.command }`), result: null });\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tcommandCallback(requestMessage.parameters).then<WorkerResponseMessage>(\n\t\t\t\tresult => ({ requestId, error: null, result }),\n\t\t\t\terror => ({ requestId, error, result: null })\n\t\t\t).then(responseMessage => this._respond(responseMessage));\n\t\t}\n\t}\n}\n\nregisterWorkerCommand(WorkerCommands.Ping, parameters => new Promise<void>(resolve => resolve(null)));\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * The commands that can be sent to or from a web worker.\n */\nexport enum WorkerCommands {\n\tResponse = 0,\n\tParse = 1,\n\tPing = 2,\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Map } from \"../utility/map\";\n\nimport { Promise, DeferredPromise } from \"../utility/promise\";\n\nimport { WorkerChannel, WorkerChannelImpl } from \"./channel\";\nexport { WorkerChannel } from \"./channel\";\n\nexport { WorkerCommands } from \"./commands\";\n\ndeclare const exports: any;\n\n/**\n * Indicates whether web workers are supposed in this environment or not.\n *\n * @type {boolean}\n */\nexport const supported = typeof Worker !== \"undefined\";\n\nconst _scriptNode = (typeof document !== \"undefined\" && document.currentScript !== undefined) ? document.currentScript : null;\n\n/**\n * Create a new web worker and returns a {@link libjass.webworker.WorkerChannel} to it.\n *\n * @param {string=} scriptPath The path to libjass.js to be loaded in the web worker. If the browser supports document.currentScript, the parameter is optional and, if not provided,\n * the path will be determined from the src attribute of the <script> element that contains the currently running copy of libjass.js\n * @return {!libjass.webworker.WorkerChannel} A communication channel to the new web worker.\n */\nexport function createWorker(scriptPath: string = _scriptNode.src): WorkerChannel {\n\treturn new WorkerChannelImpl(new Worker(scriptPath));\n}\n\ndeclare const global: any;\n\nif (typeof WorkerGlobalScope !== \"undefined\" && global instanceof WorkerGlobalScope) {\n\t// This is a web worker. Set up a channel to talk back to the main thread.\n\tnew WorkerChannelImpl(global);\n}\n","/**\n * libjass\n *\n * https://github.com/Arnavion/libjass\n *\n * Copyright 2013 Arnav Singh\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Map } from \"../utility/map\";\n\nimport { WorkerCommands } from \"./commands\";\nimport { WorkerCommandHandler } from \"./channel\";\n\nconst workerCommands = new Map<WorkerCommands, WorkerCommandHandler>();\n\nconst classPrototypes = new Map<number, any>();\n\n/**\n * Registers a handler for the given worker command.\n *\n * @param {number} command The command that this handler will handle. One of the {@link libjass.webworker.WorkerCommands} constants.\n * @param {function(*, function(*, *))} handler The handler. A function of the form (parameters: *, response: function(error: *, result: *): void): void\n */\nexport function registerWorkerCommand(command: WorkerCommands, handler: WorkerCommandHandler): void {\n\tworkerCommands.set(command, handler);\n}\n\n/**\n * Gets the handler for the given worker command.\n *\n * @param {number} command\n * @return {?function(*, function(*, *))}\n */\nexport function getWorkerCommandHandler(command: WorkerCommands): WorkerCommandHandler {\n\treturn workerCommands.get(command);\n}\n\n/**\n * Registers a prototype as a deserializable type.\n *\n * @param {!*} prototype\n */\nexport function registerClassPrototype(prototype: any): void {\n\tprototype._classTag = classPrototypes.size;\n\tclassPrototypes.set(prototype._classTag, prototype);\n}\n\n/**\n * @param {*} obj\n * @return {string}\n */\nexport function serialize(obj: any): string {\n\treturn JSON.stringify(obj, (/* ujs:unreferenced */ key: string, value: any) => {\n\t\tif (value && value._classTag !== undefined) {\n\t\t\tvalue._classTag = value._classTag;\n\t\t}\n\n\t\treturn value;\n\t});\n}\n\n/**\n * @param {string} str\n * @return {*}\n */\nexport function deserialize(str: string): any {\n\treturn JSON.parse(str, (/* ujs:unreferenced */ key: string, value: any) => {\n\t\tif (value && value._classTag !== undefined) {\n\t\t\tconst hydratedValue = Object.create(classPrototypes.get(value._classTag));\n\t\t\tfor (const key of Object.keys(value)) {\n\t\t\t\tif (key !== \"_classTag\") {\n\t\t\t\t\thydratedValue[key] = value[key];\n\t\t\t\t}\n\t\t\t}\n\t\t\tvalue = hydratedValue;\n\t\t}\n\n\t\treturn value;\n\t});\n}\n"]}