<(}K      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~                       !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJNoneOTAn iso which converts to/from K -> TextAn iso which converts to/from K -> StringAn iso which converts to/from K -> [K]None2OT1This represents a range between two coordinates ()(Coord Row Column) represents a char in a block of text. (zero indexed) e.g. Coord 0 0 is the first character in the text, Coord 2 1 is the second character of the third rowL-A Helper only used when combining many spans.8A span which maps a piece of Monoidal data over a range.An Q represents an exact position in a file as a number of characters from the start.A type alias to Range' which specializes the types to s.A type alias to ) which specializes the types to integers.%Applies a function over the row of a (Applies a function over the column of a -Applies a function over both functors in any M.Moves a  by a given q It may be unintuitive, but for (Coord row col) a given range will be moved down by row and to the right by col. )Moves a range forward by the given amount!Moves a ' forward by the given amount of columns"+Adds the rows and columns of the given two s.#=Given the text you're operating over, creates an iso from an  to a .N1Given the text you're operating over, converts a  to an .O2Given the text you're operating over, converts an  to a .$This will restrict a given 1 to a valid one which lies within the given text.%This will restrict a given 1 to a valid one which lies within the given text.&Combines a list of spans containing some monoidal data into a list of offsets with with the data that applies from each Offset forwards.'clamp min max val3 restricts val to be within min and max (inclusive)(.Returns the number of rows and columns that a  spans as a )GReturns the number of rows and columns that a chunk of text spans as a * A lens over text before a given +A lens over text after a given ,+A lens over text which is encompassed by a 4 PLQR !"#NO$%&'()*+,-./012#  !"#$%&'()*+,# #$%, )( !"&'*+* PLQR !"#NO$%&'()*+,-./012NoneAT;Retrieve some extension state<Set some extension state=Set some extension state>7Members of this class have access to editor extensions.?'This lens focuses the Extensions States@0A map of extension types to their current value.ADA wrapper around an extension of any type so it can be stored in an @CThis is a lens which will focus the extension state that matches the type inferred as the focal point. It's a little bit of magic, if you treat the focus as a member of your extension state it should just work out.(This lens falls back on the extension's S9 instance (when getting) if nothing has yet been stored. :;<=>?@ABCD :;<=>?@ABC AB@>?:;<=C:;<=>?@ABCDNone /9;AIOTE[A buffer, holds the text in the buffer and any extension states that are set on the buffer.FRAn opaque reference to a buffer. When operating over a BufRef Rasa checks if the E` still exists and simply ignores any operations over non-existent buffers; typically returning TKUThis allows creation of polymorphic lenses over any type which has access to a BufferN2This lens focuses the text of the in-scope buffer.O)Creates a new buffer from the given text.EUVWXFGKLYMZNOPQREFGKLMNOEKLFGNOM EUVWXFGKLYMZNOPQRNoneAOTS(This is the primary state of the editor.TQThis allows polymorphic lenses over anything that has access to an Editor contextV(A lens over the map of available buffersW,A lens over the exiting status of the editorS[\]^TU_`aVWXYZ[FGSTUVWSTUVWFG S[\]^TU_`aVWXYZ[NoneAT \PThis is triggered when text in a buffer is changed. The Event data includes the D that changed and the new text which is now contined in that range.^IThis represents each modifier key that could be pressed along with a key.c}This event is dispatched in response to keyboard key presses. It contains both the char that was pressed and any modifiers (^+) that where held when the key was pressed.sbThis event is dispatched after adding a new buffer. The contained BufRef refers to the new buffer.ulThis event is dispatched before exiting the editor, listen for this to do any clean-up (saving files, etc.)w7This event is dispatched immediately after dispatching y.yKThis event is dispatched when it's time for extensions to render to screen.{=This event is dispatched immediately before dispatching the y event.}kThis event is dispatched immediately before dispatching any events from asyncronous event listeners (like cs)ZThis event is dispatched exactly once when the editor starts up after onInit has occurred.@This event is dispatched exactly once when the editor starts up.'\]^_`abcdefghijklmnopqrstuvwxyz{|}~'\]^b`a_cdefghijklmnopqrstuvwxyz{|}~'}~{|yzwxuvstcdefghijklmnopqr^_`ab\] \]^_`abcdefghijklmnopqrstuvwxyz{|}~None%&/2IFThis is a monad for performing actions on a specific buffer. You run s by embedding them in a  via   or  Within a BufAction you can:Use  liftAction to run an Use liftIO for IO>Access/Edit the buffer's text; some commands are available in Rasa.Internal.Actions.#Access/edit buffer extensions; see bufExtEmbed and sequence s from other extensions Free Monad Actions for BufAction{This is a monad for performing actions against the editor. You can register Actions to be run in response to events using  Within an Action you can:Use liftIO for IO5Access/edit extensions that are stored globally, see C Embed any s exported other extensionsEmbed buffer actions using   or  DAdd/Edit/Focus buffers and a few other Editor-level things, see the Rasa.Internal.Actions module.Free Monad Actions for Action+Embeds a ActionF type into the Action MonadbAllows running IO in BufAction.1Embeds a BufActionF type into the BufAction MonadcAllows running IO in BufAction.$bc  bcNone &Returns the text of the current buffer#Sets the text of the current buffer&Gets the range of text from the buffer&Sets the range of text from the bufferGets the current buffer's F$Retrieve some buffer extension stateSet some buffer extension stateSet some buffer extension stateThis lifts up an  to be run inside a  Noned-Rows can be represented by their line number.&Runs function over given range of text4Deletes the text in the given range from the buffer.9Replaces the text in the given range with the given text.*Inserts text into the buffer at the given .<Gets the range representing a given row (if that row exists)d))d None_dispatchActionAsync allows you to perform a task asynchronously and then apply the result. In dispatchActionAsync asyncAction,  asyncActionw is an IO which resolves to an Action, note that the context in which the second action is executed is NOT the same context in which dispatchActionAsync is called; it is likely that text and other state have changed while the IO executed, so it's a good idea to check (inside the applying Action) that things are in a good state before making changes. Here's an example: PasyncCapitalize :: Action () asyncCapitalize = do txt <- focusDo getText -- We give dispatchActionAsync an IO which resolves in an action dispatchActionAsync $ ioPart txt ioPart :: Text -> IO (Action ()) ioPart txt = do result <- longAsyncronousCapitalizationProgram txt -- Note that this returns an Action, but it's still wrapped in IO return $ maybeApplyResult txt result maybeApplyResult :: Text -> Text -> Action () maybeApplyResult oldTxt capitalized = do -- We get the current buffer's text, which may have changed since we started newTxt <- focusDo getText if newTxt == oldTxt -- If the text is the same as it was, we can apply the transformation then focusDo (setText capitalized) -- Otherwise we can choose to re-queue the whole action and try again -- Or we could just give up. else asyncCapitalizeDon't let the type signature confuse you; it's much simpler than it seems. The first argument is a function which takes an action provider; the action provider will be passed a dispatch function which can be called as often as you like with  Action ()s. When it is passed an % it forks off an IO to dispatch that w to the main event loop. Note that the dispatch function calls forkIO on its own; so there's no need for you to do so.TUse this function when you have some long-running process which dispatches multiple s. Here's an example which fires a Timer event every second. data Timer = TimerFired dispatchTimer :: Action () dispatchTimer = mkDispatcher Timer myTimer :: (Action () -> IO ()) -> IO () myTimer dispatch = forever $ dispatch dispatchTimer >> threadDelay 1000000 myAction :: Action () myAction = onInit $ asyncActionProvider myTimer?Runs a BufAction over the given BufRefs, returning any results.{Result list is not guaranteed to be the same length or positioning as input BufRef list; some buffers may no longer exist.(Adds a new buffer and returns the BufRef"Returns an up-to-date list of all Fs?Retrieve the entire editor state. This is read-only for logging renderingdebugging purposes only.0Retrieve a buffer. This is read-only for logging renderingdebugging purposes only.mThis signals to the editor that you'd like to shutdown. The current events will finish processing, then the  6 event will be dispatched, then the editor will exit. =<;;<= NoneOT This lifts a  to an  which performs the ; on every buffer and collects the return values as a list. This lifts a   to an  which performs the  " on the buffer referred to by the F; If the buffer referred to no longer exists this returns: Nothing.Gets F" that comes after the one providedGets F# that comes before the one provided None%&AOT&BThis is a type alias to make defining your functions for use with  easier; It represents the function your event provider function will be passed to allow dispatching events. Using this type requires the  RankNTypes language pragma.e!Store the listeners in extensionsf:A map of Event types to a list of listeners for that eventwAn opaque reverence to a specific registered event-listener. A ListenerId is used only to remove listeners later with .g:A wrapper around event listeners so they can be stored in f.heThis extracts all event listeners from a map of listeners which match the type of the provided event.i5Extract the listener function from eventType listener Trigger an  on a c Dispatch a c event.DRegisters an action to be performed during the Initialization phase.This phase occurs exactly ONCE when the editor starts up. Though arbitrary actions may be performed in the configuration block; it's recommended to embed such actions in the onInit event listener so that all event listeners are registered before anything Actions occur. Dispatch the  action. Dispatch the  action.<Registers an action to be performed BEFORE each event phase. Dispatch the } action.=Registers an action to be performed BEFORE each render phase.This is a good spot to add information useful to the renderer since all actions have been performed. Only cosmetic changes should occur during this phase. Dispatch the { action.=Registers an action to be performed during each render phase.MThis phase should only be used by extensions which actually render something. Dispatch the y action.<Registers an action to be performed AFTER each render phase.This is useful for cleaning up extension state that was registered for the renderer, but needs to be cleared before the next iteration. Dispatch the w action.:Registers an action to be performed during the exit phase.This is only triggered exactly once when the editor is shutting down. It allows an opportunity to do clean-up, kill any processes you've started, or save any data before the editor terminates. Dispatch the u action.@Registers an action to be performed after a new buffer is added.,The supplied function will be called with a BufRef& to the new buffer, and the resulting  will be run.Run the given  over all new buffers Dispatch the s action.2This is fired every time text in a buffer changes.YThe range of text which was altered and the new value of that text are provided inside a \ event. Dispatch the BufBufTextChanged action.NThis allows long-running IO processes to provide Events to Rasa asyncronously.JDon't let the type signature confuse you; it's much simpler than it seems.Let's break it down: Using the + type with asyncEventProvider requires the  RankNTypes language pragma.;This type as a whole represents a function which accepts a  and returns an j-; the dispatcher itself accepts data of ANY k$ type and emits it as an event (see Rasa.Internal.Events).When you call ( you pass it a function which accepts a dispatchU function as an argument and then calls it with various events within the resulting j.]Note that asyncEventProvider calls forkIO internally, so there's no need to do that yourself. Here's an example which fires a Timer event every second. {-# language RankNTypes #-} data Timer = Timer myTimer :: Dispatcher -> IO () myTimer dispatch = forever $ dispatch Timer >> threadDelay 1000000 myAction :: Action () myAction = onInit $ asyncEventProvider myTimernThis function takes an IO which results in some Event, it runs the IO asynchronously and dispatches the eventl'Event dispatcher generic over its monadm+addListener which is generic over its monadn.removeListener which is generic over its monadDispatches an event of any type. This should be used to define your own custom event dispatchers (with more concrete types) which you can re-export. You can collect results from all listeners if they were registered to return an  Action result where result" is a Monoid (for example a list).8This adds an event listener which listens for events of  eventType and will run the resulting  Action result when triggered by some .iThis should primarily be used to create your own more specific addListener functions which you re-export.9Removes the listener represented by the given ListenerId.@Dispatches an event of any type to the BufAction's buffer. See 0Adds a listener to the BufAction's buffer. See 5Removes a listener from the BufAction's buffer. See 5eofpgqhilmn ''2eofpgqhilmn NonerbThis contains all data representing the editor's state. It acts as the state object for an 'Action Runs an Action into an IOEvals an Action into an IOExecs an Action into an IO5Spawn the channels necessary to run action and do so.sEInterpret the Free Monad; in this case it interprets it down to an IO<This lifts up a bufAction into an Action which performs the K over the referenced buffer and returns the result (if the buffer existed)tJInterpret the Free Monad; in this case it interprets it down to an Action.ruvwxyz{  st    ruvwxyz{  stNoneI NA container which holds a foreground color, background color, and a flair. a T5 represents that we should not change that attribute.EThese represent the possible extra attributes which may be applied. 3 represents the renderer's default text attributes. (These represent the possible colors for * or +. )) represents the renderer's default color.* Create a new  with the given   as the foreground.+ Create a new  with the given   as the background., Create a new  with the given  as its flair.- Pass this a ^ which computes styles based on the current buffer and they'll be collected for the renderer..:Collect all provided styles, this is useful for renderers.09The monoid instance replaces any attributes which have a | in the new  and persists any that are T in the new style (using  for )!}~ !"#$%&'()*+,-./01 !"#$%&'()*+,-.*+, !"#$%&'()-.}~ !"#$%&'()*+,-./01None9;<"Represents how to render an entity>RenderInfo is the data necessary to render something; it consists of a block of text with its associated styles. It is a Monoid and can be appended with other >s.BbCrop text verticaly to only the visible portion according to viewport height and scroll position.C(Add a style to some text resulting in a >HdAppends to RenderInfo by appending the text and styles while preserving proper text/style alignment;<=>?@ABCDEFGH ;<=>?@ABC A@<=>?;BC ;<=>?@ABCDEFGHNoneIIII(C) 2016 Chris PennerMIT+Chris Penner <christopher.penner@gmail.com>None  !#$%&'()*+=<;>?CEFKLNT\]^b`a_cdefghijklmnopqrst !"#$%&'()*+,-.;<=>?@ABCEKLFNT)>?C;<=cdefghijklmnopqr^_`abst\] &#$% (+* !*+, !"#$%&'()-.C'BA@;>?<=NoneAOTJThe main function to run rasa. rasa eventProviders extensionsAThis should be imported by a user-config with and called with an 7 containing any extensions which have event listeners.  rasa $ do cursor vim slateOThis is the main event loop, it runs recursively forever until something sets . It runs the pre-event listeners, then checks if any async events have finished, then runs the post event listeners and repeats.JJJJ !"##$%&'()*+,-./01233445(6789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]]^_`aabcdefghijklmnopqrstuuvwxyz{{|}~                                  !"#$%&'()*+,-./0123456789:;<=>?@ABCCDEFGHIJKLMNOPQRSTUVWXYZ[\]S^_``abcdmefghijkl m n o p q rstuSvw x y z n  p { | } { ~     S^"rasa-0.1.10-G8Pxqy22yGzCW1mY5cAzQhRasa.Internal.TextRasa.Internal.RangeRasa.Internal.ExtensionsRasa.Internal.BufferRasa.Internal.EditorRasa.Internal.EventsRasa.Internal.ActionMonadsRasa.Internal.BufActionRasa.Internal.BufActionsRasa.Internal.ActionRasa.Internal.ActionsRasa.Internal.ListenersRasa.Internal.InterpretersRasa.Internal.StylesRasa.Internal.Utility Rasa.TestingRasabufferDo buffersDoonEveryTriggerbufDoonExit Rasa.Action BufActionActionData AlternativeMaybeRasa.Ext Rasa.EditorexitingasTextasStringasLinesRange_rStart_rEnd $fEqRangeCoord'Coord _coordRow _coordColrEndrStart $fOrdRange$fBitraversableRange$fBifoldableRange$fBifunctorRange $fShowRange $fEqCoord'SpanOffsetCrdRangecoordColcoordRowoverRowoverColoverBoth moveRange moveRangeByN moveCursorByN moveCursorasCoord clampCoord clampRange combineSpansclampsizeOfRsizeOfbeforeCafterCrange $fNumCoord'$fBifunctorSpan $fOrdCoord'$fBiapplicativeCoord'$fBifunctorCoord' $fShowCoord' $fShowOffset $fEqOffset $fShowSpan$fEqSpan $fFunctorSpan $fShowMarker $fEqMarker HasExtMonadgetExtsetExtoverExtHasExtsextsExtMapExtext $fShowExtBufferBufRef $fShowBufRef $fEqBufRef $fOrdBufRef HasBufferbufferreftextmkBuffer$fHasBufferBuffer $fShowBuffer$fHasExtsBufferEditor HasEditoreditorbuffers$fDefaultEditor$fHasExtsEditor$fHasEditorEditor $fShowEditorBufTextChangedModCtrlAltShiftMetaKeypressKEscKBSKEnterKLeftKRightKUpKDownKPrtScrKHomeKPageUpKDelKEnd KPageDownKUnknownBufAddedExit AfterRenderOnRender BeforeRender BeforeEvent AfterInitInit $fShowInit$fEqInit$fShowAfterInit $fEqAfterInit$fShowBeforeEvent$fEqBeforeEvent$fShowBeforeRender$fEqBeforeRender$fShowOnRender $fEqOnRender$fShowAfterRender$fEqAfterRender $fShowExit$fEqExit$fShowBufAdded $fEqBufAdded $fShowMod$fEqMod$fShowKeypress $fEqKeypress$fShowBufTextChanged$fEqBufTextChanged getBufAction BufActionFGetTextSetText GetBufRef GetBufExt SetBufExtSetRange LiftAction BufLiftIO getActionActionFLiftIOBufferDoDispatchActionAsyncAsyncActionProvider AddBuffer GetBufRefsGetExtSetExt GetEditor GetBuffer ShouldExit liftActionF liftBufAction$fHasExtMonadBufAction$fMonadIOBufAction$fHasExtMonadAction$fMonadIOAction$fFunctorBufAction$fApplicativeBufAction$fMonadBufAction$fFunctorAction$fApplicativeAction $fMonadAction$fFunctorBufActionF$fFunctorActionFgetTextsetTextgetRangesetRange getBufRef getBufExt setBufExt overBufExt liftAction overRange deleteRange replaceRangeinsertAt getLineRangedispatchActionAsyncasyncActionProvider addBuffer getBufRefs getEditor getBufferexit shouldExit buffersDo_bufDo_ nextBufRef prevBufRef Dispatcher ListenerId onKeypressdispatchKeypressonInit dispatchInit afterInitdispatchAfterInitbeforeEveryEventbeforeEveryEvent_dispatchBeforeEventbeforeEveryRenderbeforeEveryRender_dispatchBeforeRender onEveryRenderonEveryRender_dispatchOnRenderafterEveryRenderafterEveryRender_dispatchAfterRender dispatchExit onBufAdded onBufAdded_onEveryNewBufferonEveryNewBuffer_dispatchBufAddedonBufTextChangeddispatchBufTextChangedasyncEventProviderdispatchEventAsync dispatchEvent addListener addListener_removeListenerdispatchBufEventaddBufListeneraddBufListener_removeBufListener$fDefaultLocalListeners$fEqListenerId$fShowListener$fShowListenerId$fShowLocalListeners mkActionState runAction evalAction execActionbootstrapAction runBufAction$fHasExtsActionState$fHasEditorActionState$fShowActionStateStylesStyleFlairStandout Underline ReverseVideoBlinkDimBoldDefFlairColorBlackRedGreenYellowBlueMagentaCyanWhiteDefColorfgbgflairaddStyleProvider getStyles$fDefaultStyleMap $fMonoidStyle$fDefaultStyle $fShowColor $fEqColor $fShowFlair $fEqFlair $fShowStyle $fEqStyle$fShowStyleMap $fEqStyleMap$fMonoidStyleMap ScrollPos Renderablerender RenderInfoHeightWidthcropToViewport styleText$fRenderableRenderInfo$fRenderableYiString$fRenderableBufRef$fRenderableMaybe$fMonoidRenderInfo testBufActionrasa$yi-rope-0.7.0.2-4e29TpEi6l7hStEfnaGSYi.RopeYiStringMarkerbaseData.Bifunctor BifunctortoOffsettoCoordIDStartEnd1data-default-class-0.1.2.0-FYQpjIylblBDctdkHAFeXAData.Default.ClassDefaultGHC.BaseNothing_text' _bufExts'_refbufExts'text' _buffers' _exiting' _extState'buffers'exiting' extState'liftFIOliftBufActionFIORowLocalListeners ListenersListenermatchingListeners getListenerghc-prim GHC.TypesIOData.Typeable.InternalTypeabledispatchEventG addListenerGremoveListenerG ActionStateactionInterpreterbufActionInterpreter_ed _nextBufId _actionQueue actionQueueed nextBufIdJust ComputeStylesStyleMap eventLoop