on master help sign in
Migrate mkVty docs on table loading to Config
commitb54772ac1de30ed5d2411f92e9a0bf792c667033 authorJonathan Daugherty <cygnus@foobox.com> dateThu 5 Mar 2020, 14:20 (7 years ago) parente8e3fa3
2 files changed+10−12
src/Graphics/Vty.hs−9 src/Graphics/Vty/Config.hs+10−3
src/Graphics/Vty.hs−9
@@ -112,15 +112,6 @@ data Vty =
112112-- precedence. See "Graphics.Vty.Config".
113113--
114114-- For most applications @mkVty defaultConfig@ is sufficient.
115−--
116−-- If the configuration's 'allowCustomUnicodeWidthTables' is set
117−-- to 'Nothing' or 'Just True', this will use the current value of
118−-- 'TERM' and the configuation's width table settings to attempt to
119−-- load a custom unicode character width table if one has not already
120−-- been loaded in this process. If the load is attempted and fails,
121−-- information about the failure will be logged to the debug log if the
122−-- configuration specifies one. If no custom table is loaded (or if a
123−-- load fails), the built-in character width table will be used.
124115mkVty :: Config -> IO Vty
125116mkVty appConfig = do
126117 config <- (<> appConfig) <$> userConfig
src/Graphics/Vty/Config.hs+10−3
@@ -178,9 +178,16 @@ data Config =
178178 , termWidthMaps :: [(String, FilePath)]
179179 -- ^ Terminal width map files.
180180 , allowCustomUnicodeWidthTables :: Maybe Bool
181− -- ^ Whether to permit custom Unicode width table loading.
182− -- 'Just False' indicates that table loading should not be
183− -- performed. Other values permit table loading.
181+ -- ^ Whether to permit custom Unicode width table loading by
182+ -- 'Graphics.Vty.mkVty'. @'Just' 'False'@ indicates that
183+ -- table loading should not be performed. Other values permit
184+ -- table loading.
185+ --
186+ -- If a table load is attempted and fails, information
187+ -- about the failure will be logged to the debug log if the
188+ -- configuration specifies one. If no custom table is loaded
189+ -- (or if a load fails), the built-in character width table
190+ -- will be used.
184191 }
185192 deriving (Show, Eq)
186193