Module SourceProgGUI

A simple GUI for highlighting functions in the source text of a Curry module. This GUI is used in the REPL of the Curry system KiCS2 and PAKCS to implement the command source.

In order to use this GUI, start it with the shell command

> curry-showsource <module name>

Select highlighting of operations in the specified module by writing the following commands on stdin:

+fun          -> highlight function "fun"
-fun          -> remove highlighting for function "fun"
<empty line>  -> terminate GUI
q             -> terminate GUI

Version: June 2021

Summary of exported operations:

findFunDeclInProgText :: String -> String -> Int  Deterministic 
findFirstDeclLine :: String -> [String] -> Int -> Int  Deterministic 
sourceProgGUI :: String -> [(String,(Int,Int))] -> (Widget,[Handle -> GuiPort -> IO [ReconfigureItem]])  Non-deterministic 
startGUI :: String -> IO ()  Non-deterministic 
main :: IO ()  Non-deterministic 
splitProgDefs :: String -> [(String,(Int,Int))]  Deterministic 
groupFuns :: [(String,Int)] -> [(String,(Int,Int))]  Deterministic 
deleteAdjacentFuns :: [(String,Int)] -> [(String,Int)]  Deterministic 
keywords :: [String]  Deterministic 
funDefOfLine :: String -> Maybe String  Deterministic 
isCommentLine :: String -> Bool  Deterministic 

Exported operations:

findFunDeclInProgText :: String -> String -> Int  Deterministic 

findFirstDeclLine :: String -> [String] -> Int -> Int  Deterministic 

sourceProgGUI :: String -> [(String,(Int,Int))] -> (Widget,[Handle -> GuiPort -> IO [ReconfigureItem]])  Non-deterministic 

startGUI :: String -> IO ()  Non-deterministic 

main :: IO ()  Non-deterministic 

splitProgDefs :: String -> [(String,(Int,Int))]  Deterministic 

groupFuns :: [(String,Int)] -> [(String,(Int,Int))]  Deterministic 

deleteAdjacentFuns :: [(String,Int)] -> [(String,Int)]  Deterministic 

keywords :: [String]  Deterministic 

Further infos:
  • solution complete, i.e., able to compute all solutions

funDefOfLine :: String -> Maybe String  Deterministic 

isCommentLine :: String -> Bool  Deterministic