You are not logged in.
Okay ... I have been working on this all night, and for the life of me can't fingure this out. I am trying to get these other layouts installed, but I can't figure it out. I have been looking at far too many config files and figured it's time to just ask. Here is the relevant part of my xmonad.hs
-- layouts
import XMonad.Layout
import XMonad.Layout.ResizableTile
import XMonad.Layout.StackTile
import XMonad.Layout.IM
import XMonad.Layout.ToggleLayouts
import XMonad.Layout.Reflect
import XMonad.Layout.Combo
-- layout stuff
myLayoutHook = avoidStruts (tiled ||| Mirror tiled ||| IM ||| Stacked Tile ||| Full)
Now from looking at someone else's config it looks like I need to define tiled:
where
tiled = ResizableTall 1 (2/100) (1/2) []
So: 1) Is that what I need to add to get the above layouts working (i could care less about the IM one right now)?
2) If that is the case could someone point me to, or explain, what exactly the numbers mean after the Resizeable tall?
As much as I like answers, I also like to understand it for later.
Last edited by lifeafter2am (2009-06-19 19:49:24)
#binarii @ irc.binarii.net
Matrix Server: https://matrix.binarii.net
-------------
Allan -> ArchBang is not supported because it is stupid.
Offline
If you could care less about IM, take it out for now. You can tackle that later. As far as ResizableTall goes, the numbers are as follows (from the code):
Using: 'ResizableTall 1 (2/100) (1/2) []' as an example:
1 is the number of master windows, it should be an Integer.
(2/100) is the amount of change when resizing by 'Shrink', 'Expand', etc..., It should be a Rational
(1/2) is the width of the master window, also a Rational
[], fraction to multiply the window height that would be given when divided equally,
a list of Rationals
unspecified values are replaced by 1
Offline
Ok, so now I have this in my xmonad.hs
-- layouts
import XMonad.Layout
import XMonad.Layout.ResizableTile
import XMonad.Layout.StackTile
import XMonad.Layout.ToggleLayouts
import XMonad.Layout.Reflect
import XMonad.Layout.Combo
-- layout stuff
customLayout = avoidStruts $ tiled ||| ResizableTile ||| StackTile ||| Full
where
tiled = ResizableTall 1 (2/100) (1/2) []
But when I try to compile it (or check the compiling I should say) I get this:
[ishikawa@section9 ~]$ ghci .xmonad/xmonad.hs
GHCi, version 6.10.3: http://www.haskell.org/ghc/ :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer ... linking ... done.
Loading package base ... linking ... done.
[1 of 1] Compiling Main ( .xmonad/xmonad.hs, interpreted )
.xmonad/xmonad.hs:22:39:
Not in scope: data constructor `ResizableTile'
Failed, modules loaded: none.
Prelude> :q
Leaving GHCi.
[ishikawa@section9 ~]$
I don't get why it doesn't complain about StackTile, but doesn't like RezizableTile (which is really the one that I want the most anyway).
#binarii @ irc.binarii.net
Matrix Server: https://matrix.binarii.net
-------------
Allan -> ArchBang is not supported because it is stupid.
Offline
Are you certain that you have xmonad-contrib installed?
Offline
Are you certain that you have xmonad-contrib installed?
[ishikawa@section9 ~]$ pacman -Q xmonad-contrib
xmonad-contrib 0.8.1-1.2
#binarii @ irc.binarii.net
Matrix Server: https://matrix.binarii.net
-------------
Allan -> ArchBang is not supported because it is stupid.
Offline
.xmonad/xmonad.hs:22:39: Not in scope: data constructor `ResizableTile'
Well that just means what it says, ResizableTile isn't a data constructor. Just take ResizableTile out of the layout list. It's a little confusing since the module name is ResizableTile, but the layout constructor is called ResizableTall.
Offline
lifeafter2am wrote:.xmonad/xmonad.hs:22:39: Not in scope: data constructor `ResizableTile'
Well that just means what it says, ResizableTile isn't a data constructor. Just take ResizableTile out of the layout list. It's a little confusing since the module name is ResizableTile, but the layout constructor is called ResizableTall.
But isn't ResizableTile another seperate layout, as defined by the XMonad.Layout.ResizableTile?
#binarii @ irc.binarii.net
Matrix Server: https://matrix.binarii.net
-------------
Allan -> ArchBang is not supported because it is stupid.
Offline
Nope.
As you can see from the code:
module XMonad.Layout.ResizableTile (
-- * Usage
-- $usage
ResizableTall(..), MirrorResize(..)
) where
ResizableTile only exports two layout constructors, ResizableTall and MirrorResize. The module name is a little misleading.
Offline
Ok, so now here is what I have:
-- layouts
import XMonad.Layout
import XMonad.Layout.ResizableTile
import XMonad.Layout.StackTile
import XMonad.Layout.IM
import XMonad.Layout.ToggleLayouts
import XMonad.Layout.Reflect
import XMonad.Layout.Combo
-- layout stuff
customLayout = avoidStruts $ tiled ||| StackTile ||| Full
where
tiled = ResizableTall 1 (2/100) (1/2) []
And now I get this:
[[ishikawa@section9 ~]$ ghci .xmonad/xmonad.hs
GHCi, version 6.10.3: http://www.haskell.org/ghc/ :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer ... linking ... done.
Loading package base ... linking ... done.
[1 of 1] Compiling Main ( .xmonad/xmonad.hs, interpreted )
.xmonad/xmonad.hs:22:29:
No instance for (LayoutClass
((->) Int) (Rational -> Rational -> StackTile a))
arising from a use of `|||' at .xmonad/xmonad.hs:22:29-56
Possible fix:
add an instance declaration for
(LayoutClass ((->) Int) (Rational -> Rational -> StackTile a))
In the second argument of `($)', namely
`tiled ||| StackTile ||| Full'
In the expression: avoidStruts $ tiled ||| StackTile ||| Full
In the definition of `customLayout':
customLayout = avoidStruts $ tiled ||| StackTile ||| Full
where
tiled = ResizableTall 1 (2 / 100) (1 / 2) []
Failed, modules loaded: none.
Prelude> :q
Leaving GHCi.
#binarii @ irc.binarii.net
Matrix Server: https://matrix.binarii.net
-------------
Allan -> ArchBang is not supported because it is stupid.
Offline
I haven't used StackTile myself but the arguments are similar to ResizableTall, it takes an Int and two Rational so it would be:
customLayout = avoidStruts $ tiled ||| StackTile 1 (3/100) (1/2) ||| Full
where
tiled = ResizableTall 1 (2/100) (1/2) []
First argument is an Int, second two are Rational.
Your setup with my personal favorite ratio:
customLayout = avoidStruts $ tiled ||| goldenStack || Full
where
tiled = ResizableTall nmaster delta ratio []
goldenStack = StackTile nmaster delta golden
golden = toRational (2/(1 + sqrt 5 :: Double))
nmaster = 1
delta = 0.03
Offline
NM, figured it all out! Thanks for the help!
Last edited by lifeafter2am (2009-06-19 19:49:04)
#binarii @ irc.binarii.net
Matrix Server: https://matrix.binarii.net
-------------
Allan -> ArchBang is not supported because it is stupid.
Offline