Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell98 |
Functions to provide mediated access to the SC3 help system.
- get_env_default :: String -> String -> IO String
- lookup_env_default :: String -> String -> IO String
- sc3HelpDirectory :: IO String
- sc3HelpClassFile :: FilePath -> String -> IO (Maybe FilePath)
- sc3HelpOperatorEntry :: FilePath -> String -> FilePath
- sc3HelpMethod :: FilePath -> Char -> (String, String) -> FilePath
- sc3HelpClassMethod :: FilePath -> (String, String) -> FilePath
- sc3HelpInstanceMethod :: FilePath -> (String, String) -> FilePath
- ugenSC3HelpFile :: String -> IO FilePath
- viewSC3Help :: String -> IO ()
Documentation
get_env_default :: String -> String -> IO String Source
Guarded variant of getEnv
with default value.
lookup_env_default :: String -> String -> IO String Source
lookupEnv
with default value.
lookup_env_default "PATH" "/usr/bin"
sc3HelpDirectory :: IO String Source
Read the environment variable SC3_HELP
, the default value is
~/.local/share/SuperCollider/Help
.
sc3HelpClassFile :: FilePath -> String -> IO (Maybe FilePath) Source
Locate path to indicated SC3 class help file.
import System.FilePath d <- sc3HelpDirectory h <- sc3HelpClassFile d "SinOsc" h == Just (d </> "Classes/SinOsc.html")
sc3HelpOperatorEntry :: FilePath -> String -> FilePath Source
Generate path to indicated SC3 operator help file.
sc3HelpOperatorEntry "." "+" == "./Overviews/Operators.html#.+"
sc3HelpMethod :: FilePath -> Char -> (String, String) -> FilePath Source
Generate path to indicated SC3 method help.
sc3HelpMethod "." '*' ("C","m") == "./Classes/C.html#*m"
sc3HelpClassMethod :: FilePath -> (String, String) -> FilePath Source
Generate path to indicated SC3 class method help.
sc3HelpClassMethod "." ("C","m") == "./Classes/C.html#*m"
sc3HelpInstanceMethod :: FilePath -> (String, String) -> FilePath Source
Generate path to indicated SC3 instance method help.
sc3HelpInstanceMethod "." ("C","m") == "./Classes/C.html#-m"
ugenSC3HelpFile :: String -> IO FilePath Source
The name of the local SC3 Help file documenting u
. Deletes
@
to allow use on haddock quoted comments.
import Sound.SC3.UGen.Name ugenSC3HelpFile "Collection.*fill" ugenSC3HelpFile "Collection.inject" ugenSC3HelpFile (toSC3Name "sinOsc")
viewSC3Help :: String -> IO () Source
Use BROWSER
or x-www-browser
to view SC3 help file for u
.
get_env_default "BROWSER" "x-www-browser"
import Sound.SC3.UGen.Name viewSC3Help (toSC3Name "Collection.*fill") viewSC3Help (toSC3Name "Collection.inject") viewSC3Help (toSC3Name "sinOsc")