| Safe Haskell | None | 
|---|---|
| Language | Haskell2010 | 
Termonad.App
Synopsis
- setupScreenStyle :: IO ()
- createFontDesc :: TMConfig -> IO FontDescription
- compareScrolledWinAndTab :: ScrolledWindow -> TMNotebookTab -> Bool
- updateFLTabPos :: TMState -> Int -> Int -> IO ()
- askShouldExit :: TMState -> IO ResponseType
- forceQuit :: TMState -> IO ()
- setupTermonad :: TMConfig -> Application -> ApplicationWindow -> Builder -> IO ()
- appActivate :: TMConfig -> Application -> IO ()
- showAboutDialog :: Application -> IO ()
- appStartup :: Application -> IO ()
- start :: TMConfig -> IO ()
- defaultMain :: TMConfig -> IO ()
Documentation
setupScreenStyle :: IO () Source #
askShouldExit :: TMState -> IO ResponseType Source #
Try to figure out whether Termonad should exit. This also used to figure out if Termonad should close a given terminal.
This reads the confirmExit setting from ConfigOptions to check whether
 the user wants to be notified when either Termonad or a given terminal is
 about to be closed.
If confirmExit is True, then a dialog is presented to the user asking
 them if they really want to exit or close the terminal.  Their response is
 sent back as a ResponseType.
If confirmExit is False, then this function always returns
 ResponseTypeYes.
forceQuit :: TMState -> IO () Source #
Force Termonad to exit without asking the user whether or not to do so.
setupTermonad :: TMConfig -> Application -> ApplicationWindow -> Builder -> IO () Source #
appActivate :: TMConfig -> Application -> IO () Source #
showAboutDialog :: Application -> IO () Source #
appStartup :: Application -> IO () Source #
start :: TMConfig -> IO () Source #
Run Termonad with the given TMConfig.
Do not perform any of the recompilation operations that the defaultMain
 function does.
defaultMain :: TMConfig -> IO () Source #
Run Termonad with the given TMConfig.
This function will check if there is a ~/.config/termonad/termonad.hs file
 and a ~/.cache/termonad/termonad-linux-x86_64 binary.  Termonad will
 perform different actions based on whether or not these two files exist.
Here are the four different possible actions based on the existence of these two files.
- ~/.config/termonad/termonad.hsexists,- ~/.cache/termonad/termonad-linux-x86_64exists- The timestamps of these two files are checked. If the - ~/.config/termonad/termonad.hsfile has been modified after the- ~/.cache/termonad/termonad-linux-x86_64binary, then Termonad will use GHC to recompile the- ~/.config/termonad/termonad.hsfile, producing a new binary at- ~/.cache/termonad/termonad-linux-x86_64. This new binary will be re-executed. The- TMConfigpassed to this- defaultMainwill be effectively thrown away.- If GHC fails to recompile the - ~/.config/termonad/termonad.hsfile, then Termonad will just execute- startwith the- TMConfigpassed in.- If the - ~/.cache/termonad/termonad-linux-x86_64binary has been modified after the- ~/.config/termonad/termonad.hsfile, then Termonad will re-exec the- ~/.cache/termonad/termonad-linux-x86_64binary. The- TMConfigpassed to this- defaultMainwill be effectively thrown away.
- ~/.config/termonad/termonad.hsexists,- ~/.cache/termonad/termonad-linux-x86_64does not exist- Termonad will use GHC to recompile the - ~/.config/termonad/termonad.hsfile, producing a new binary at- ~/.cache/termonad/termonad-linux-x86_64. This new binary will be re-executed. The- TMConfigpassed to this- defaultMainwill be effectively thrown away.- If GHC fails to recompile the - ~/.config/termonad/termonad.hsfile, then Termonad will just execute- startwith the- TMConfigpassed in.
- ~/.config/termonad/termonad.hsdoes not exist,- ~/.cache/termonad/termonad-linux-x86_64exists- Termonad will ignore the - ~/.cache/termonad/termonad-linux-x86_64binary and just run- startwith the- TMConfigpassed to this function.
- ~/.config/termonad/termonad.hsdoes not exist,- ~/.cache/termonad/termonad-linux-x86_64does not exist- Termonad will run - startwith the- TMConfigpassed to this function.
Other notes:
- That the locations of ~/.config/termonad/termonad.hsand~/.cache/termonad/termonad-linux-x86_64may differ depending on your system.
- In your own ~/.config/termonad/termonad.hsfile, you can use eitherdefaultMainorstart. As long as you always execute the system-widetermonadbinary (instead of the binary produced as~/.cache/termonad/termonad-linux-x86_64), the effect should be the same.