packages feed

termonad 4.4.0.0 → 4.5.0.0

raw patch · 11 files changed

+55/−35 lines, 11 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

- Termonad.Pcre: inline_c_ffi_6989586621679104993 :: IO CUInt
+ Termonad.Config: [allowBold] :: ConfigOptions -> !Bool
+ Termonad.Lenses: lensAllowBold :: Lens' ConfigOptions Bool
+ Termonad.Pcre: inline_c_ffi_6989586621679107081 :: IO CUInt
+ Termonad.Prelude: liftIOOp :: MonadUnliftIO m => (IO a -> IO b) -> m a -> m b
+ Termonad.Prelude: stateTVar :: TVar s -> (s -> (a, s)) -> STM a
+ Termonad.Types: [allowBold] :: ConfigOptions -> !Bool
- Termonad.Config: ConfigOptions :: !FontConfig -> !ShowScrollbar -> !Integer -> !Bool -> !Text -> !Bool -> !ShowTabBar -> !CursorBlinkMode -> !Bool -> !Bool -> ConfigOptions
+ Termonad.Config: ConfigOptions :: !FontConfig -> !ShowScrollbar -> !Integer -> !Bool -> !Text -> !Bool -> !ShowTabBar -> !CursorBlinkMode -> !Bool -> !Bool -> !Bool -> ConfigOptions
- Termonad.Config.Colour: lensBackgroundColour :: forall c_a1jnB. Lens' (ColourConfig c_a1jnB) (Option c_a1jnB)
+ Termonad.Config.Colour: lensBackgroundColour :: forall c_a1m0Y. Lens' (ColourConfig c_a1m0Y) (Option c_a1m0Y)
- Termonad.Config.Colour: lensCursorBgColour :: forall c_a1jnB. Lens' (ColourConfig c_a1jnB) (Option c_a1jnB)
+ Termonad.Config.Colour: lensCursorBgColour :: forall c_a1m0Y. Lens' (ColourConfig c_a1m0Y) (Option c_a1m0Y)
- Termonad.Config.Colour: lensCursorFgColour :: forall c_a1jnB. Lens' (ColourConfig c_a1jnB) (Option c_a1jnB)
+ Termonad.Config.Colour: lensCursorFgColour :: forall c_a1m0Y. Lens' (ColourConfig c_a1m0Y) (Option c_a1m0Y)
- Termonad.Config.Colour: lensForegroundColour :: forall c_a1jnB. Lens' (ColourConfig c_a1jnB) (Option c_a1jnB)
+ Termonad.Config.Colour: lensForegroundColour :: forall c_a1m0Y. Lens' (ColourConfig c_a1m0Y) (Option c_a1m0Y)
- Termonad.Config.Colour: lensHighlightBgColour :: forall c_a1jnB. Lens' (ColourConfig c_a1jnB) (Option c_a1jnB)
+ Termonad.Config.Colour: lensHighlightBgColour :: forall c_a1m0Y. Lens' (ColourConfig c_a1m0Y) (Option c_a1m0Y)
- Termonad.Config.Colour: lensHighlightFgColour :: forall c_a1jnB. Lens' (ColourConfig c_a1jnB) (Option c_a1jnB)
+ Termonad.Config.Colour: lensHighlightFgColour :: forall c_a1m0Y. Lens' (ColourConfig c_a1m0Y) (Option c_a1m0Y)
- Termonad.Config.Colour: lensPalette :: forall c_a1jnB. Lens' (ColourConfig c_a1jnB) (Palette c_a1jnB)
+ Termonad.Config.Colour: lensPalette :: forall c_a1m0Y. Lens' (ColourConfig c_a1m0Y) (Palette c_a1m0Y)
- Termonad.Prelude: class Foldable (t :: Type -> Type)
+ Termonad.Prelude: class Foldable (t :: TYPE LiftedRep -> Type)
- Termonad.Prelude: class Hashable a
+ Termonad.Prelude: class Eq a => Hashable a
- Termonad.Prelude: data Conc (m :: Type -> Type) a
+ Termonad.Prelude: data Conc (m :: TYPE LiftedRep -> Type) a
- Termonad.Prelude: fromGregorian :: Integer -> Int -> Int -> Day
+ Termonad.Prelude: fromGregorian :: Year -> MonthOfYear -> DayOfMonth -> Day
- Termonad.Prelude: replicateConcurrently :: MonadUnliftIO m => Int -> m b -> m [b]
+ Termonad.Prelude: replicateConcurrently :: MonadUnliftIO f => Int -> f a -> f [a]
- Termonad.Prelude: toGregorian :: Day -> (Integer, Int, Int)
+ Termonad.Prelude: toGregorian :: Day -> (Year, MonthOfYear, DayOfMonth)
- Termonad.Types: ConfigOptions :: !FontConfig -> !ShowScrollbar -> !Integer -> !Bool -> !Text -> !Bool -> !ShowTabBar -> !CursorBlinkMode -> !Bool -> !Bool -> ConfigOptions
+ Termonad.Types: ConfigOptions :: !FontConfig -> !ShowScrollbar -> !Integer -> !Bool -> !Text -> !Bool -> !ShowTabBar -> !CursorBlinkMode -> !Bool -> !Bool -> !Bool -> ConfigOptions

Files

.nix-helpers/overlays.nix view
@@ -78,7 +78,7 @@     #     # Either this, or termonadKnownWorkingHaskellPkgSet can be changed in an overlay     # if you want to use a different GHC to build Termonad.-    termonadCompilerVersion = "ghc902";+    termonadCompilerVersion = "ghc92";      # A Haskell package set where we know the GHC version works to compile     # Termonad.  This is basically just a shortcut so that other Nix files
.nix-helpers/stack-shell.nix view
@@ -8,7 +8,7 @@   buildInputs = [     cairo     git-    gobjectIntrospection+    gobject-introspection     gtk3     vte     zlib
CHANGELOG.md view
@@ -1,3 +1,10 @@+## 4.5.0.0++*   Add an `allowBold` option (which defaults to `True`).  This can be used if+    you want disable use of bold text.+    Thanks [@zanculmarktum](https://github.com/zanculmarktum)!+    [#225](https://github.com/cdepillabout/termonad/pull/225)+ ## 4.4.0.0  *   Add support for opening URLs in a browser by right-clicking on them.
flake.lock view
@@ -2,11 +2,11 @@   "nodes": {     "nixpkgs": {       "locked": {-        "lastModified": 1665732960,-        "narHash": "sha256-WBZ+uSHKFyjvd0w4inbm0cNExYTn8lpYFcHEes8tmec=",+        "lastModified": 1680213900,+        "narHash": "sha256-cIDr5WZIj3EkKyCgj/6j3HBH4Jj1W296z7HTcWj1aMA=",         "owner": "NixOS",         "repo": "nixpkgs",-        "rev": "4428e23312933a196724da2df7ab78eb5e67a88e",+        "rev": "e3652e0735fbec227f342712f180f4f21f0594f2",         "type": "github"       },       "original": {
flake.nix view
@@ -63,31 +63,5 @@           program = "${self.packages.${system}.termonad}/bin/termonad";         };       });--      # Tests run by 'nix flake check' and by Hydra.-      # checks = forAllSystems-      #   (system:-      #     with nixpkgsFor.${system};-      #     {-      #       inherit (self.packages.${system}) hello;--      #       # Additional tests, if applicable.-      #       test = stdenv.mkDerivation {-      #         name = "hello-test-${version}";--      #         buildInputs = [ hello ];--      #         unpackPhase = "true";--      #         buildPhase = ''-      #           echo 'running some integration tests'-      #           [[ $(hello) = 'Hello Nixers!' ]]-      #         '';--      #         installPhase = "mkdir -p $out";-      #       };-      #     }-      #   );-     }; }
glade/preferences.glade view
@@ -281,6 +281,21 @@               </packing>             </child>             <child>+              <object class="GtkCheckButton" id="allowBold">+                <property name="label" translatable="yes">Allow bold</property>+                <property name="visible">True</property>+                <property name="can-focus">True</property>+                <property name="receives-default">True</property>+                <property name="tooltip-text" translatable="yes">Allow terminal to use bold text.</property>+                <property name="halign">start</property>+                <property name="draw-indicator">True</property>+              </object>+              <packing>+                <property name="left-attach">1</property>+                <property name="top-attach">11</property>+              </packing>+            </child>+            <child>               <placeholder/>             </child>             <child>
src/Termonad/App.hs view
@@ -120,6 +120,7 @@   , terminalSetFont   , terminalSetScrollbackLines   , terminalSetWordCharExceptions+  , terminalSetAllowBold   ) import System.Environment (getExecutablePath) import System.FilePath (takeFileName)@@ -130,6 +131,7 @@ import Termonad.Lenses   ( lensBoldIsBright   , lensEnableSixel+  , lensAllowBold   , lensConfirmExit   , lensCursorBlinkMode   , lensFontConfig@@ -729,6 +731,7 @@   terminalSetScrollbackLines term (fromIntegral (scrollbackLen options))   terminalSetBoldIsBright term (boldIsBright options)   terminalSetEnableSixelIfExists term (enableSixel options)+  terminalSetAllowBold term (allowBold options)    let vScrollbarPolicy = showScrollbarToPolicy (options ^. lensShowScrollbar)   scrolledWindowSetPolicy scrolledWin PolicyTypeAutomatic vScrollbarPolicy@@ -756,6 +759,8 @@     objFromBuildUnsafe preferencesBuilder "boldIsBright" CheckButton   enableSixelCheckButton <-     objFromBuildUnsafe preferencesBuilder "enableSixel" CheckButton+  allowBoldCheckButton <-+    objFromBuildUnsafe preferencesBuilder "allowBold" CheckButton   wordCharExceptionsEntryBuffer <-     objFromBuildUnsafe preferencesBuilder "wordCharExceptions" Entry >>=       getEntryBuffer@@ -811,6 +816,7 @@   toggleButtonSetActive showMenuCheckButton $ showMenu options   toggleButtonSetActive boldIsBrightCheckButton $ boldIsBright options   toggleButtonSetActive enableSixelCheckButton $ enableSixel options+  toggleButtonSetActive allowBoldCheckButton $ allowBold options   entryBufferSetText wordCharExceptionsEntryBuffer (wordCharExceptions options) (-1)    -- Run dialog then close@@ -833,6 +839,7 @@     showMenuVal <- toggleButtonGetActive showMenuCheckButton     boldIsBrightVal <- toggleButtonGetActive boldIsBrightCheckButton     enableSixelVal <- toggleButtonGetActive enableSixelCheckButton+    allowBoldVal <- toggleButtonGetActive allowBoldCheckButton     wordCharExceptionsVal <- entryBufferGetText wordCharExceptionsEntryBuffer      -- Apply the changes to mvarTMState@@ -843,6 +850,7 @@         . set lensShowMenu showMenuVal         . set lensBoldIsBright boldIsBrightVal         . set lensEnableSixel enableSixelVal+        . set lensAllowBold allowBoldVal         . set lensWordCharExceptions wordCharExceptionsVal         . over lensFontConfig (`fromMaybe` maybeFontConfig)         . set lensScrollbackLen scrollbackLenVal
src/Termonad/Lenses.hs view
@@ -59,6 +59,7 @@     , ("showTabBar", "lensShowTabBar")     , ("cursorBlinkMode", "lensCursorBlinkMode")     , ("boldIsBright", "lensBoldIsBright")+    , ("allowBold", "lensAllowBold")     , ("enableSixel", "lensEnableSixel")     ]     ''ConfigOptions
src/Termonad/Term.hs view
@@ -105,6 +105,7 @@   , terminalSetScrollbackLines   , terminalSetWordCharExceptions   , terminalSpawnSync+  , terminalSetAllowBold   ) import System.Directory (getSymbolicLinkTarget) import System.Environment (lookupEnv)@@ -126,7 +127,7 @@   ) import Termonad.Types   ( ConfigHooks(createTermHook)-  , ConfigOptions(scrollbackLen, wordCharExceptions, cursorBlinkMode, boldIsBright, enableSixel)+  , ConfigOptions(scrollbackLen, wordCharExceptions, cursorBlinkMode, boldIsBright, enableSixel, allowBold)   , ShowScrollbar(..)   , ShowTabBar(..)   , TMConfig(hooks, options)@@ -376,6 +377,7 @@   terminalSetCursorBlinkMode vteTerm (cursorBlinkMode curOpts)   terminalSetBoldIsBright vteTerm (boldIsBright curOpts)   terminalSetEnableSixelIfExists vteTerm (enableSixel curOpts)+  terminalSetAllowBold vteTerm (allowBold curOpts)   widgetShow vteTerm   pure vteTerm 
src/Termonad/Types.hs view
@@ -417,6 +417,11 @@     -- Note that even if you do the above, there may still be some problems     -- with SIXEL support in VTE. Follow     -- <https://gitlab.gnome.org/GNOME/vte/-/issues/253> for more information.+  , allowBold :: !Bool+    -- ^ Allow terminal to use bold text.+    --+    -- You may want to disable this, for instance, if you use a font that+    -- doesn't look good when bold.   } deriving (Eq, Generic, FromJSON, Show, ToJSON)  instance FromJSON CursorBlinkMode where@@ -449,6 +454,7 @@ --           , cursorBlinkMode = CursorBlinkModeOn --           , boldIsBright = False --           , enableSixel = False+--           , allowBold = True --           } --   in defaultConfigOptions == defConfOpt -- :}@@ -466,6 +472,7 @@     , cursorBlinkMode = CursorBlinkModeOn     , boldIsBright = False     , enableSixel = False+    , allowBold = True     }  -- | The Termonad 'ConfigOptions' along with the 'ConfigHooks'.
termonad.cabal view
@@ -1,5 +1,5 @@ name:                termonad-version:             4.4.0.0+version:             4.5.0.0 synopsis:            Terminal emulator configurable in Haskell description:   Termonad is a terminal emulator configurable in Haskell.  It is extremely@@ -36,8 +36,14 @@                    , shell.nix data-files:          img/termonad-lambda.png custom-setup-  setup-depends:     base-                   , Cabal+                   -- Hackage apparently gives an error if you don't specify an+                   -- upper bound on your setup-depends. But I don't want to+                   -- have to remember to bump the upper bound of each of these+                   -- setup depends every time I want to make a release of Termonad,+                   -- especially send I already have upper bounds on important things+                   -- like base below.+  setup-depends:     base <999+                   , Cabal <999                    , cabal-doctest >=1.0.2 && <1.1  -- This flag builds the example code in the example-config/ directory, as well