aboutsummaryrefslogtreecommitdiff
path: root/plug
diff options
context:
space:
mode:
authorJosh Rahm <joshuarahm@gmail.com>2026-01-01 20:29:02 -0700
committerJosh Rahm <joshuarahm@gmail.com>2026-01-01 20:29:02 -0700
commitcb657fa9fc8124bdab42eb148e9b4a8ac69fc05e (patch)
tree299ab9c10e0c6c40fe30f38f3c75286a282c6283 /plug
parent88b5144ba82393e9efbffc8ba7ecc225d99dc9ed (diff)
downloadmontis-cb657fa9fc8124bdab42eb148e9b4a8ac69fc05e.tar.gz
montis-cb657fa9fc8124bdab42eb148e9b4a8ac69fc05e.tar.bz2
montis-cb657fa9fc8124bdab42eb148e9b4a8ac69fc05e.zip
[refactor] Wetterhorn -> Montis
Diffstat (limited to 'plug')
-rw-r--r--plug/src/Config.hs16
-rw-r--r--plug/src/Montis/Constraints.hs (renamed from plug/src/Wetterhorn/Constraints.hs)2
-rw-r--r--plug/src/Montis/Core.hs (renamed from plug/src/Wetterhorn/Core.hs)18
-rw-r--r--plug/src/Montis/Core/ButtonEvent.hs (renamed from plug/src/Wetterhorn/Core/ButtonEvent.hs)4
-rw-r--r--plug/src/Montis/Core/KeyEvent.hs (renamed from plug/src/Wetterhorn/Core/KeyEvent.hs)4
-rw-r--r--plug/src/Montis/Core/Keys.hs (renamed from plug/src/Wetterhorn/Core/Keys.hs)14
-rw-r--r--plug/src/Montis/Core/SurfaceEvent.hs (renamed from plug/src/Wetterhorn/Core/SurfaceEvent.hs)4
-rw-r--r--plug/src/Montis/Core/W.hs (renamed from plug/src/Wetterhorn/Core/W.hs)22
-rw-r--r--plug/src/Montis/Dsl/Bind.hs (renamed from plug/src/Wetterhorn/Dsl/Bind.hs)16
-rw-r--r--plug/src/Montis/Dsl/Buttons.hsc (renamed from plug/src/Wetterhorn/Dsl/Buttons.hsc)2
-rw-r--r--plug/src/Montis/Dsl/Input.hs (renamed from plug/src/Wetterhorn/Dsl/Input.hs)12
-rw-r--r--plug/src/Montis/Foreign.hs (renamed from plug/src/Wetterhorn/Foreign.hs)2
-rw-r--r--plug/src/Montis/Foreign/Export.hs (renamed from plug/src/Wetterhorn/Foreign/Export.hs)58
-rw-r--r--plug/src/Montis/Foreign/ForeignInterface.hs (renamed from plug/src/Wetterhorn/Foreign/ForeignInterface.hs)4
-rw-r--r--plug/src/Montis/Foreign/WlRoots.hs (renamed from plug/src/Wetterhorn/Foreign/WlRoots.hs)2
-rw-r--r--plug/src/Montis/Keys/Macros.hs (renamed from plug/src/Wetterhorn/Keys/Macros.hs)10
-rw-r--r--plug/src/Montis/Keys/MagicModifierKey.hs (renamed from plug/src/Wetterhorn/Keys/MagicModifierKey.hs)10
-rw-r--r--plug/src/Montis/Layout/Combine.hs (renamed from plug/src/Wetterhorn/Layout/Combine.hs)6
-rw-r--r--plug/src/Montis/Layout/Full.hs (renamed from plug/src/Wetterhorn/Layout/Full.hs)8
-rw-r--r--plug/src/Montis/StackSet.hs (renamed from plug/src/Wetterhorn/StackSet.hs)6
-rw-r--r--plug/src/harness_adapter.c6
21 files changed, 113 insertions, 113 deletions
diff --git a/plug/src/Config.hs b/plug/src/Config.hs
index e76e6ea..0c067c4 100644
--- a/plug/src/Config.hs
+++ b/plug/src/Config.hs
@@ -3,14 +3,14 @@ module Config (config) where
import Control.Monad (unless)
import Data.Bits
import Data.Data (Proxy (Proxy))
-import Wetterhorn.Core.ButtonEvent as ButtonEvent
-import Wetterhorn.Core.KeyEvent as KeyEvent
-import Wetterhorn.Core.W
-import Wetterhorn.Dsl.Bind
-import Wetterhorn.Dsl.Input
-import Wetterhorn.Keys.Macros
-import Wetterhorn.Keys.MagicModifierKey
-import Wetterhorn.Layout.Full
+import Montis.Core.ButtonEvent as ButtonEvent
+import Montis.Core.KeyEvent as KeyEvent
+import Montis.Core.W
+import Montis.Dsl.Bind
+import Montis.Dsl.Input
+import Montis.Keys.Macros
+import Montis.Keys.MagicModifierKey
+import Montis.Layout.Full
config :: Config WindowLayout
config =
diff --git a/plug/src/Wetterhorn/Constraints.hs b/plug/src/Montis/Constraints.hs
index 129fd6c..f1f15ff 100644
--- a/plug/src/Wetterhorn/Constraints.hs
+++ b/plug/src/Montis/Constraints.hs
@@ -1,6 +1,6 @@
-- | Contains useful constraints and constraint combinators for type-level
-- metaprogramming.
-module Wetterhorn.Constraints where
+module Montis.Constraints where
-- | A null constraint. All types implement this.
class Unconstrained a
diff --git a/plug/src/Wetterhorn/Core.hs b/plug/src/Montis/Core.hs
index d853191..df024e2 100644
--- a/plug/src/Wetterhorn/Core.hs
+++ b/plug/src/Montis/Core.hs
@@ -1,6 +1,6 @@
{-# HLINT ignore "Use camelCase" #-}
-module Wetterhorn.Core
+module Montis.Core
-- ( WState (..),
-- WConfig (..),
-- SurfaceState (..),
@@ -8,8 +8,8 @@ module Wetterhorn.Core
-- getWConfig,
-- getWState,
-- runW,
--- Wetterhorn,
--- initWetterhorn,
+-- Montis,
+-- initMontis,
-- wio,
-- incrementState,
-- readWState,
@@ -28,11 +28,11 @@ where
-- import Data.Map (Map)
-- import Foreign (Ptr, StablePtr, Word32, newStablePtr)
-- import Text.Printf
--- import Wetterhorn.Foreign.ForeignInterface (ForeignInterface)
--- import Wetterhorn.Foreign.WlRoots
+-- import Montis.Foreign.ForeignInterface (ForeignInterface)
+-- import Montis.Foreign.WlRoots
-- import qualified Data.ByteString.Char8 as CH
-- import qualified Data.Map as Map
--- import qualified Wetterhorn.Foreign.ForeignInterface as ForeignInterface
+-- import qualified Montis.Foreign.ForeignInterface as ForeignInterface
--
-- data WContext = WContext
-- { ctxForeignInterface :: ForeignInterface,
@@ -40,7 +40,7 @@ where
-- }
--
-- -- This is the OpaqueState passed to the harness.
--- type Wetterhorn = StablePtr (WContext, WState)
+-- type Montis = StablePtr (WContext, WState)
--
-- requestHotReload :: W ()
-- requestHotReload = do
@@ -57,8 +57,8 @@ where
-- fi <- ctxForeignInterface <$> getWContext
-- wio $ ForeignInterface.requestExit fi ec
--
--- initWetterhorn :: WConfig -> IO Wetterhorn
--- initWetterhorn conf = do
+-- initMontis :: WConfig -> IO Montis
+-- initMontis conf = do
-- foreignInterface <- ForeignInterface.getForeignInterface
-- newStablePtr (WContext foreignInterface conf, WState "this is a string" 0)
--
diff --git a/plug/src/Wetterhorn/Core/ButtonEvent.hs b/plug/src/Montis/Core/ButtonEvent.hs
index cc3d905..f9c5c48 100644
--- a/plug/src/Wetterhorn/Core/ButtonEvent.hs
+++ b/plug/src/Montis/Core/ButtonEvent.hs
@@ -1,6 +1,6 @@
-module Wetterhorn.Core.ButtonEvent where
+module Montis.Core.ButtonEvent where
-import Wetterhorn.Foreign.WlRoots
+import Montis.Foreign.WlRoots
import Data.Word (Word32)
import Foreign (Ptr)
diff --git a/plug/src/Wetterhorn/Core/KeyEvent.hs b/plug/src/Montis/Core/KeyEvent.hs
index 77d273f..cbdda4f 100644
--- a/plug/src/Wetterhorn/Core/KeyEvent.hs
+++ b/plug/src/Montis/Core/KeyEvent.hs
@@ -1,4 +1,4 @@
-module Wetterhorn.Core.KeyEvent
+module Montis.Core.KeyEvent
( KeyEvent (..),
KeyState (..),
)
@@ -6,7 +6,7 @@ where
import Data.Word (Word32)
import Foreign (Ptr)
-import Wetterhorn.Foreign.WlRoots
+import Montis.Foreign.WlRoots
data KeyState = KeyPressed | KeyReleased deriving (Show, Read, Eq, Enum, Ord)
diff --git a/plug/src/Wetterhorn/Core/Keys.hs b/plug/src/Montis/Core/Keys.hs
index 54d7125..4ee9e6e 100644
--- a/plug/src/Wetterhorn/Core/Keys.hs
+++ b/plug/src/Montis/Core/Keys.hs
@@ -1,4 +1,4 @@
-module Wetterhorn.Core.Keys where
+module Montis.Core.Keys where
import Control.Monad (forever, void, when)
import Control.Monad.Cont.Class
@@ -7,12 +7,12 @@ import Control.Monad.State (MonadState (get, put), MonadTrans (lift), StateT, ev
import Control.Monad.Trans.Cont
import Data.Bits
import Data.Word
-import Wetterhorn.Core.ButtonEvent (ButtonEvent)
-import Wetterhorn.Core.KeyEvent
-import qualified Wetterhorn.Core.KeyEvent as KeyEvent
-import qualified Wetterhorn.Core.ButtonEvent as ButtonEvent
-import Wetterhorn.Core.W
-import Wetterhorn.Foreign.WlRoots (wlrSeatKeyboardNotifyKey, wlrSeatSetKeyboard)
+import Montis.Core.ButtonEvent (ButtonEvent)
+import Montis.Core.KeyEvent
+import qualified Montis.Core.KeyEvent as KeyEvent
+import qualified Montis.Core.ButtonEvent as ButtonEvent
+import Montis.Core.W
+import Montis.Foreign.WlRoots (wlrSeatKeyboardNotifyKey, wlrSeatSetKeyboard)
-- | Forwards the given key event to the focused window.
forwardKey :: KeyEvent -> W ()
diff --git a/plug/src/Wetterhorn/Core/SurfaceEvent.hs b/plug/src/Montis/Core/SurfaceEvent.hs
index 3e7eaf3..93bcdae 100644
--- a/plug/src/Wetterhorn/Core/SurfaceEvent.hs
+++ b/plug/src/Montis/Core/SurfaceEvent.hs
@@ -1,10 +1,10 @@
-module Wetterhorn.Core.SurfaceEvent
+module Montis.Core.SurfaceEvent
( SurfaceEvent (..),
SurfaceState (..),
)
where
-import Wetterhorn.Foreign.WlRoots
+import Montis.Foreign.WlRoots
data SurfaceState = Map | Unmap | Destroy
deriving (Eq, Ord, Show, Read, Enum)
diff --git a/plug/src/Wetterhorn/Core/W.hs b/plug/src/Montis/Core/W.hs
index 862f9fa..cf21a04 100644
--- a/plug/src/Wetterhorn/Core/W.hs
+++ b/plug/src/Montis/Core/W.hs
@@ -1,6 +1,6 @@
{-# LANGUAGE DuplicateRecordFields #-}
-module Wetterhorn.Core.W where
+module Montis.Core.W where
import Control.Arrow (Arrow (first))
import Control.Monad ((<=<))
@@ -22,14 +22,14 @@ import Foreign (Ptr, StablePtr, intPtrToPtr, ptrToIntPtr)
import Text.Printf (printf)
import Text.Read hiding (lift)
import Type.Reflection (someTypeRep, someTypeRepTyCon)
-import Wetterhorn.Core.ButtonEvent (ButtonEvent)
-import Wetterhorn.Core.KeyEvent
-import Wetterhorn.Core.SurfaceEvent
-import Wetterhorn.Foreign.ForeignInterface (ForeignInterface)
-import qualified Wetterhorn.Foreign.ForeignInterface as ForeignInterface
-import Wetterhorn.Foreign.WlRoots (Surface, WlrSeat)
-import Wetterhorn.StackSet hiding (layout)
-import qualified Wetterhorn.StackSet as StackSet
+import Montis.Core.ButtonEvent (ButtonEvent)
+import Montis.Core.KeyEvent
+import Montis.Core.SurfaceEvent
+import Montis.Foreign.ForeignInterface (ForeignInterface)
+import qualified Montis.Foreign.ForeignInterface as ForeignInterface
+import Montis.Foreign.WlRoots (Surface, WlrSeat)
+import Montis.StackSet hiding (layout)
+import qualified Montis.StackSet as StackSet
data RationalRect = RationalRect Rational Rational Rational Rational
@@ -128,7 +128,7 @@ instance Read (ReadPtr a) where
instance Show (ReadPtr a) where
show (ReadPtr ptr) = show (ptrToIntPtr ptr)
-type Wetterhorn = StablePtr (Context, State)
+type Montis = StablePtr (Context, State)
data Context = Context
{ ctxForeignInterface :: ForeignInterface,
@@ -308,7 +308,7 @@ demarshalState Config {hooks = hooks, layout = layout} str =
(fmap Left . M.fromList -> xs)
) = read str
--- | This is _the_ main monad used for Wetterhorn operations. Contains
+-- | This is _the_ main monad used for Montis operations. Contains
-- everything required to operate. Contains the state, configuration and
-- interface to foreign code.
newtype W a = W (ReaderT Context (StateT State IO) a)
diff --git a/plug/src/Wetterhorn/Dsl/Bind.hs b/plug/src/Montis/Dsl/Bind.hs
index 0b6adaf..c7dbc43 100644
--- a/plug/src/Wetterhorn/Dsl/Bind.hs
+++ b/plug/src/Montis/Dsl/Bind.hs
@@ -1,6 +1,6 @@
-- | eDSL for the 'bind' function. The 'bind' function provides an easy way to
-- bind certain actions to other actions.
-module Wetterhorn.Dsl.Bind
+module Montis.Dsl.Bind
( bind,
(.+),
MatchEvent (..),
@@ -17,13 +17,13 @@ import Control.Monad
import Control.Monad.Trans
import Data.Bits
import Data.Word
-import Wetterhorn.Core.ButtonEvent (ButtonEvent(..))
-import qualified Wetterhorn.Core.ButtonEvent as ButtonEvent
-import Wetterhorn.Core.KeyEvent (KeyEvent(..))
-import qualified Wetterhorn.Core.KeyEvent as KeyEvent
-import Wetterhorn.Core.W
-import Wetterhorn.Dsl.Buttons as X
-import Wetterhorn.Dsl.Input
+import Montis.Core.ButtonEvent (ButtonEvent(..))
+import qualified Montis.Core.ButtonEvent as ButtonEvent
+import Montis.Core.KeyEvent (KeyEvent(..))
+import qualified Montis.Core.KeyEvent as KeyEvent
+import Montis.Core.W
+import Montis.Dsl.Buttons as X
+import Montis.Dsl.Input
class MatchEvent m where
matches :: m -> InputEvent -> W Bool
diff --git a/plug/src/Wetterhorn/Dsl/Buttons.hsc b/plug/src/Montis/Dsl/Buttons.hsc
index c3e049c..963d5ce 100644
--- a/plug/src/Wetterhorn/Dsl/Buttons.hsc
+++ b/plug/src/Montis/Dsl/Buttons.hsc
@@ -1,4 +1,4 @@
-module Wetterhorn.Dsl.Buttons where
+module Montis.Dsl.Buttons where
import Data.Word
diff --git a/plug/src/Wetterhorn/Dsl/Input.hs b/plug/src/Montis/Dsl/Input.hs
index 1a0c294..4855951 100644
--- a/plug/src/Wetterhorn/Dsl/Input.hs
+++ b/plug/src/Montis/Dsl/Input.hs
@@ -1,6 +1,6 @@
{-# LANGUAGE DataKinds #-}
-module Wetterhorn.Dsl.Input
+module Montis.Dsl.Input
( InputM,
InputEvent (..),
InputProxy (..),
@@ -43,11 +43,11 @@ import Control.Monad.Trans.Maybe (MaybeT (runMaybeT))
import Data.IORef (newIORef, readIORef, writeIORef)
import Data.Proxy
import Data.Word (Word32)
-import qualified Wetterhorn.Core.ButtonEvent as ButtonEvent
-import qualified Wetterhorn.Core.KeyEvent as KeyEvent
-import Wetterhorn.Core.W (W (..))
-import qualified Wetterhorn.Core.W as W
-import Wetterhorn.Foreign.WlRoots (guardNull, wlrKeyboardGetModifiers, wlrSeatGetKeyboard, wlrSeatKeyboardNotifyKey, wlrSeatSetKeyboard)
+import qualified Montis.Core.ButtonEvent as ButtonEvent
+import qualified Montis.Core.KeyEvent as KeyEvent
+import Montis.Core.W (W (..))
+import qualified Montis.Core.W as W
+import Montis.Foreign.WlRoots (guardNull, wlrKeyboardGetModifiers, wlrSeatGetKeyboard, wlrSeatKeyboardNotifyKey, wlrSeatSetKeyboard)
class InputProxy (spy :: k) where
onKeyEvent :: Proxy spy -> InputEvent -> MaybeT W InputEvent
diff --git a/plug/src/Wetterhorn/Foreign.hs b/plug/src/Montis/Foreign.hs
index 2d0a42c..fbbfb08 100644
--- a/plug/src/Wetterhorn/Foreign.hs
+++ b/plug/src/Montis/Foreign.hs
@@ -1,4 +1,4 @@
-module Wetterhorn.Foreign
+module Montis.Foreign
( TypedIntPtr (..),
toPtr,
fromPtr,
diff --git a/plug/src/Wetterhorn/Foreign/Export.hs b/plug/src/Montis/Foreign/Export.hs
index 51bd72b..f14fb40 100644
--- a/plug/src/Wetterhorn/Foreign/Export.hs
+++ b/plug/src/Montis/Foreign/Export.hs
@@ -1,6 +1,6 @@
-- | This module does not export anything. It exists simply to provide C-symbols
-- for the plugin.
-module Wetterhorn.Foreign.Export () where
+module Montis.Foreign.Export () where
import Config
import Control.Arrow (Arrow (first))
@@ -18,20 +18,20 @@ import Foreign
newStablePtr,
)
import Foreign.C (CChar, CInt (..))
-import Wetterhorn.Core.ButtonEvent (ButtonEvent (ButtonEvent), ButtonState (ButtonPressed, ButtonReleased))
-import Wetterhorn.Core.KeyEvent (KeyEvent (..), KeyState (..))
-import Wetterhorn.Core.SurfaceEvent (SurfaceEvent (SurfaceEvent))
-import Wetterhorn.Core.W (W, Wetterhorn)
-import qualified Wetterhorn.Core.W as W
-import Wetterhorn.Foreign.ForeignInterface
-import Wetterhorn.Foreign.WlRoots
+import Montis.Core.ButtonEvent (ButtonEvent (ButtonEvent), ButtonState (ButtonPressed, ButtonReleased))
+import Montis.Core.KeyEvent (KeyEvent (..), KeyState (..))
+import Montis.Core.SurfaceEvent (SurfaceEvent (SurfaceEvent))
+import Montis.Core.W (W, Montis)
+import qualified Montis.Core.W as W
+import Montis.Foreign.ForeignInterface
+import Montis.Foreign.WlRoots
type Wetter = (W.Config W.WindowLayout, W.State)
toWetter :: (W.Context, W.State) -> (W.Config W.WindowLayout, W.State)
toWetter = first W.ctxConfig
-runForeign :: (Wetter -> W ()) -> Wetterhorn -> IO Wetterhorn
+runForeign :: (Wetter -> W ()) -> Montis -> IO Montis
runForeign fn stblptr = do
w@(ctx, st) <- deRefStablePtr stblptr
freeStablePtr stblptr
@@ -39,7 +39,7 @@ runForeign fn stblptr = do
newStablePtr (ctx, state')
runForeignWithReturn ::
- (Storable a) => (Wetter -> W a) -> Ptr a -> Wetterhorn -> IO Wetterhorn
+ (Storable a) => (Wetter -> W a) -> Ptr a -> Montis -> IO Montis
runForeignWithReturn fn ptr stableptr = do
w@(ctx, st) <- deRefStablePtr stableptr
freeStablePtr stableptr
@@ -52,8 +52,8 @@ runForeignWithReturn2 ::
(Wetter -> W (a, b)) ->
Ptr a ->
Ptr b ->
- Wetterhorn ->
- IO Wetterhorn
+ Montis ->
+ IO Montis
runForeignWithReturn2 fn ptrA ptrB stableptr = do
w@(ctx, st) <- deRefStablePtr stableptr
freeStablePtr stableptr
@@ -64,12 +64,12 @@ runForeignWithReturn2 fn ptrA ptrB stableptr = do
-- | This function is the implementation of the "hotstart" mechanism. It gives a
-- pointer to the previously marshalled state and the length of that array and
--- this function returns a Wetterhorn instance.
+-- this function returns a Montis instance.
foreign export ccall "plugin_hot_start"
pluginHotStart ::
- Ptr CChar -> Word32 -> IO Wetterhorn
+ Ptr CChar -> Word32 -> IO Montis
-pluginHotStart :: Ptr CChar -> Word32 -> IO Wetterhorn
+pluginHotStart :: Ptr CChar -> Word32 -> IO Montis
pluginHotStart chars len = do
bs <- BS.packCStringLen (chars, fromIntegral len)
foreignInterface <- getForeignInterface
@@ -84,9 +84,9 @@ pluginHotStart chars len = do
-- calles the function "wetterhorn". This function should be defined in the main
-- code as it's sort-of the equivalent of XMonad's "main" function.
foreign export ccall "plugin_cold_start"
- pluginColdStart :: IO Wetterhorn
+ pluginColdStart :: IO Montis
-pluginColdStart :: IO Wetterhorn
+pluginColdStart :: IO Montis
pluginColdStart = do
foreignInterface <- getForeignInterface
state <- W.initColdState config
@@ -95,9 +95,9 @@ pluginColdStart = do
-- | Marshals the opaque state to a C-style byte array and size pointer.
foreign export ccall "plugin_marshal_state"
- pluginMarshalState :: Wetterhorn -> Ptr Word32 -> IO (Ptr Word8)
+ pluginMarshalState :: Montis -> Ptr Word32 -> IO (Ptr Word8)
-pluginMarshalState :: Wetterhorn -> Ptr Word32 -> IO (Ptr Word8)
+pluginMarshalState :: Montis -> Ptr Word32 -> IO (Ptr Word8)
pluginMarshalState stblptr outlen = do
(_, st) <- deRefStablePtr stblptr
let bs = CH.pack (W.marshalState st)
@@ -108,9 +108,9 @@ pluginMarshalState stblptr outlen = do
return ret
foreign export ccall "plugin_handle_button"
- pluginHandleButton :: Ptr WlrPointerButtonEvent -> Word32 -> Wetterhorn -> IO Wetterhorn
+ pluginHandleButton :: Ptr WlrPointerButtonEvent -> Word32 -> Montis -> IO Montis
-pluginHandleButton :: Ptr WlrPointerButtonEvent -> Word32 -> Wetterhorn -> IO Wetterhorn
+pluginHandleButton :: Ptr WlrPointerButtonEvent -> Word32 -> Montis -> IO Montis
pluginHandleButton eventPtr modifiers = do
runForeign $
\( _,
@@ -141,8 +141,8 @@ foreign export ccall "plugin_handle_keybinding"
Word32 ->
Word32 ->
Ptr CInt ->
- Wetterhorn ->
- IO Wetterhorn
+ Montis ->
+ IO Montis
pluginHandleKeybinding ::
Ptr WlrInputDevice ->
@@ -151,8 +151,8 @@ pluginHandleKeybinding ::
Word32 ->
Word32 ->
Ptr CInt ->
- Wetterhorn ->
- IO Wetterhorn
+ Montis ->
+ IO Montis
pluginHandleKeybinding inputDevicePtr eventPtr mods sym cp =
runForeignWithReturn $
\( _,
@@ -180,9 +180,9 @@ pluginHandleKeybinding inputDevicePtr eventPtr mods sym cp =
-- of an XDG surface.
foreign export ccall "plugin_handle_surface"
pluginHandleSurface ::
- Ptr WlrXdgSurface -> CInt -> Wetterhorn -> IO Wetterhorn
+ Ptr WlrXdgSurface -> CInt -> Montis -> IO Montis
-pluginHandleSurface :: Ptr WlrXdgSurface -> CInt -> Wetterhorn -> IO Wetterhorn
+pluginHandleSurface :: Ptr WlrXdgSurface -> CInt -> Montis -> IO Montis
pluginHandleSurface p t =
runForeign
( \(_, W.State {currentHooks = W.Hooks {surfaceHook = surfaceHook}}) ->
@@ -194,10 +194,10 @@ pluginHandleSurface p t =
-- of an XWayland surface.
foreign export ccall "plugin_handle_xwayland_surface"
pluginHandleXWaylandSurface ::
- Ptr WlrXWaylandSurface -> CInt -> Wetterhorn -> IO Wetterhorn
+ Ptr WlrXWaylandSurface -> CInt -> Montis -> IO Montis
pluginHandleXWaylandSurface ::
- Ptr WlrXWaylandSurface -> CInt -> Wetterhorn -> IO Wetterhorn
+ Ptr WlrXWaylandSurface -> CInt -> Montis -> IO Montis
pluginHandleXWaylandSurface p t =
runForeign
( \( _,
diff --git a/plug/src/Wetterhorn/Foreign/ForeignInterface.hs b/plug/src/Montis/Foreign/ForeignInterface.hs
index 471e3a9..c01e6b8 100644
--- a/plug/src/Wetterhorn/Foreign/ForeignInterface.hs
+++ b/plug/src/Montis/Foreign/ForeignInterface.hs
@@ -1,4 +1,4 @@
-module Wetterhorn.Foreign.ForeignInterface
+module Montis.Foreign.ForeignInterface
( getForeignInterface,
ForeignInterface (..),
ForeignDemarshal (..),
@@ -14,7 +14,7 @@ import Foreign (Ptr, Storable (peek, sizeOf), castPtr, plusPtr)
import Foreign.C (CChar, CInt (..))
import Foreign.C.String
import GHC.Exts (FunPtr)
-import Wetterhorn.Foreign.WlRoots
+import Montis.Foreign.WlRoots
newtype ForeignDemarshal a = ForeignDemarshal (StateT (Ptr ()) IO a)
deriving (Functor, Monad, Applicative, MonadState (Ptr ()))
diff --git a/plug/src/Wetterhorn/Foreign/WlRoots.hs b/plug/src/Montis/Foreign/WlRoots.hs
index 0581b77..4b0685f 100644
--- a/plug/src/Wetterhorn/Foreign/WlRoots.hs
+++ b/plug/src/Montis/Foreign/WlRoots.hs
@@ -1,4 +1,4 @@
-module Wetterhorn.Foreign.WlRoots where
+module Montis.Foreign.WlRoots where
import Foreign (IntPtr, Ptr, Word32, intPtrToPtr, ptrToIntPtr, nullPtr)
import Text.Read
diff --git a/plug/src/Wetterhorn/Keys/Macros.hs b/plug/src/Montis/Keys/Macros.hs
index a794193..37f4db4 100644
--- a/plug/src/Wetterhorn/Keys/Macros.hs
+++ b/plug/src/Montis/Keys/Macros.hs
@@ -1,7 +1,7 @@
-- There are constraints used for better type-level enforced safety rules.
{-# OPTIONS_GHC -fno-warn-redundant-constraints #-}
-module Wetterhorn.Keys.Macros
+module Montis.Keys.Macros
( MacroSupport,
macroStartStopKeybind,
macroReplayKeybind,
@@ -20,10 +20,10 @@ import Data.Type.Equality
import Data.Word
import Foreign (Ptr)
import GHC.TypeError
-import Wetterhorn.Core.KeyEvent
-import Wetterhorn.Core.W
-import Wetterhorn.Dsl.Input
-import Wetterhorn.Foreign.WlRoots (WlrInputDevice)
+import Montis.Core.KeyEvent
+import Montis.Core.W
+import Montis.Dsl.Input
+import Montis.Foreign.WlRoots (WlrInputDevice)
data RecordedKey = RecordedKey Word32 Word32 KeyState Word32 Word32 Char
deriving (Read, Show)
diff --git a/plug/src/Wetterhorn/Keys/MagicModifierKey.hs b/plug/src/Montis/Keys/MagicModifierKey.hs
index 6bc8bb3..0cf1eb3 100644
--- a/plug/src/Wetterhorn/Keys/MagicModifierKey.hs
+++ b/plug/src/Montis/Keys/MagicModifierKey.hs
@@ -1,12 +1,12 @@
-module Wetterhorn.Keys.MagicModifierKey where
+module Montis.Keys.MagicModifierKey where
import Data.Data
import Data.Default.Class
import GHC.TypeNats
-import Wetterhorn.Core.KeyEvent
-import Wetterhorn.Core.W
-import Wetterhorn.Dsl.Bind
-import Wetterhorn.Dsl.Input
+import Montis.Core.KeyEvent
+import Montis.Core.W
+import Montis.Dsl.Bind
+import Montis.Dsl.Input
import Control.Monad.RWS (MonadTrans(lift))
import Control.Monad.Trans.Maybe (MaybeT(..))
diff --git a/plug/src/Wetterhorn/Layout/Combine.hs b/plug/src/Montis/Layout/Combine.hs
index 10a0208..7563876 100644
--- a/plug/src/Wetterhorn/Layout/Combine.hs
+++ b/plug/src/Montis/Layout/Combine.hs
@@ -1,10 +1,10 @@
{-# LANGUAGE ViewPatterns #-}
-module Wetterhorn.Layout.Combine where
+module Montis.Layout.Combine where
import Data.Typeable
-import Wetterhorn.Constraints
-import Wetterhorn.Core.W
+import Montis.Constraints
+import Montis.Core.W
data (|||) a b = Comb LR a b
deriving (Typeable, Read, Show)
diff --git a/plug/src/Wetterhorn/Layout/Full.hs b/plug/src/Montis/Layout/Full.hs
index b7e4d91..b2efb91 100644
--- a/plug/src/Wetterhorn/Layout/Full.hs
+++ b/plug/src/Montis/Layout/Full.hs
@@ -1,10 +1,10 @@
-module Wetterhorn.Layout.Full where
+module Montis.Layout.Full where
import Data.Data (Typeable)
import Data.Default.Class
-import Wetterhorn.Constraints
-import Wetterhorn.Core.W
-import Wetterhorn.StackSet
+import Montis.Constraints
+import Montis.Core.W
+import Montis.StackSet
data Full = Full
deriving (Read, Show, Typeable)
diff --git a/plug/src/Wetterhorn/StackSet.hs b/plug/src/Montis/StackSet.hs
index 86d1b8e..9f24514 100644
--- a/plug/src/Wetterhorn/StackSet.hs
+++ b/plug/src/Montis/StackSet.hs
@@ -1,4 +1,4 @@
-module Wetterhorn.StackSet where
+module Montis.StackSet where
import Control.Monad (void)
import Data.Monoid (First(..))
@@ -204,7 +204,7 @@ catMaybes (StackSet cur hidden visible) =
filter :: (a -> Bool) -> StackSet s sd t l a -> StackSet s sd t l a
filter ffn =
- Wetterhorn.StackSet.catMaybes . fmap (\a -> if ffn a then Just a else Nothing)
+ Montis.StackSet.catMaybes . fmap (\a -> if ffn a then Just a else Nothing)
delete :: (Eq a) => a -> StackSet s sd t l a -> StackSet s sd t l a
-delete win = Wetterhorn.StackSet.filter (/=win)
+delete win = Montis.StackSet.filter (/=win)
diff --git a/plug/src/harness_adapter.c b/plug/src/harness_adapter.c
index 24b813c..0c27c91 100644
--- a/plug/src/harness_adapter.c
+++ b/plug/src/harness_adapter.c
@@ -9,7 +9,7 @@
#include <stdlib.h>
#include <unistd.h>
-const char *plugin_name = "Wetterhorn";
+const char *plugin_name = "Montis";
void* foreign_interface;
@@ -42,9 +42,9 @@ void shell_exec(const char* cmd) {
}
static const char msg[] =
- "Wetterhorn Plugin v 0.01\n\n"
+ "Montis Plugin v 0.01\n\n"
"Welcome, and thank you for your interest.\n\n"
- "This is merely a plugin to the Wetterhorn Compositor and not meant to be\n"
+ "This is merely a plugin to the Montis Compositor and not meant to be\n"
"executed as a standalone binary. This plugin requires a harness to run\n"
"To use this file, please use './wtr_harness [full-path-to-wtr.so]'\n"
"That will allow you to see how this compositor works in all its glory!\n";