all repos — fluxbox @ e133cf83a332a72ca42be5e223834d4e6aa0a2e8

custom fork of the fluxbox windowmanager

Xinerama
pekdon pekdon
commit

e133cf83a332a72ca42be5e223834d4e6aa0a2e8

parent

1022df421227aea29259204ce69b93df16c0f7db

6 files changed, 40 insertions(+), 14 deletions(-)

jump to
M ChangeLogChangeLog

@@ -22,6 +22,14 @@ 4 = Skip: shaded windows

5 = Skip: lower tabs/shaded windows 6 = Skip: stuck windows/shaded windows 7 = Skip: lower tabs/stuck windows/shaded windows +*02/03/15: + * Xinerama support, maximizes windows to the current heads size, places + windows on the current head, makes it possible to place toolbar on + the different heads, also possible with the slit. Menus will be placed + on the current head too. (Claes Nästen) +*02/03/13: + * Fixed window placement, now tabs are taking in account. Also, + no spaced are put inbetween windows to save space. (Claes Nästen) *02/03/11: * Fixed some KDE stuff in Slit.cc (Thanks Tommi Komulainen) *02/03/08:
M configure.inconfigure.in

@@ -241,6 +241,23 @@ AC_MSG_RESULT([no])

) AC_SUBST(GNOME) +dnl Check for Xinerama support +XINERAMA="" +AC_MSG_CHECKING([whether to build support for the Xinerama extension]) +AC_ARG_ENABLE(xinerama, +[ --enable-xinerama enable xinerama extension [default=no]], , [enable_xinerama=no]) + +if test "x$enable_xinerama" = "xyes"; then + AC_MSG_RESULT([yes]) + AC_CHECK_LIB(Xinerama, XineramaQueryScreens, + XINERAMA="-DXINERAMA"; Xinerama_libs="-lXinerama", ) +else + AC_MSG_RESULT([no]) +fi +AC_SUBST(XINERAMA) + +LIBS="$LIBS $Xinerama_libs" + dnl Determine the return type of signal handlers AC_TYPE_SIGNAL
M src/BaseDisplay.ccsrc/BaseDisplay.cc

@@ -22,7 +22,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING

// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: BaseDisplay.cc,v 1.10 2002/03/19 21:19:55 fluxgen Exp $ +// $Id: BaseDisplay.cc,v 1.11 2002/03/23 02:02:00 pekdon Exp $ // use GNU extensions #ifndef _GNU_SOURCE

@@ -454,28 +454,29 @@ // Searches for the head at the coordinates

// x,y. If it fails or Xinerama isn't // activated it'll return head nr 0 //----------------------------------------- -unsigned int ScreenInfo::getHead(int x, int y) { +unsigned int ScreenInfo::getHead(int x, int y) const { // is Xinerama extensions enabled? if (hasXinerama()) { // check if last head is still active - if ((xineramaInfos[xineramaLastHead].x_org <= x) && +/* if ((xineramaInfos[xineramaLastHead].x_org <= x) && ((xineramaInfos[xineramaLastHead].x_org + xineramaInfos[xineramaLastHead].width) > x) && (xineramaInfos[xineramaLastHead].y_org <= y) && ((xineramaInfos[xineramaLastHead].y_org + xineramaInfos[xineramaLastHead].height) > y)) { return xineramaLastHead; - } else { + } else { */ // go trough all the heads, and search for (int i = 0; (signed) i < xineramaNumHeads; i++) { if (xineramaInfos[i].x_org <= x && - xineramaInfos[i].x_org + xineramaInfos[i].width) > x && + (xineramaInfos[i].x_org + xineramaInfos[i].width) > x && xineramaInfos[i].y_org <= y && - xineramaInfos[i].y_org + xineramaInfos[i].height) > y) - return (xineramaLastHead = i); + (xineramaInfos[i].y_org + xineramaInfos[i].height) > y) + // return (xineramaLastHead = i); + return i; } - } + // } } return 0;

@@ -506,7 +507,7 @@

//----------- getHeadWidth ------------ // Returns the width of head //------------------------------------- -unsigned int ScreenInfo::getHeadWidth(unsigned int head) { +unsigned int ScreenInfo::getHeadWidth(unsigned int head) const { if (hasXinerama()) { if ((signed) head >= xineramaNumHeads) {
M src/BaseDisplay.hhsrc/BaseDisplay.hh

@@ -22,7 +22,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING

// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: BaseDisplay.hh,v 1.17 2002/03/19 21:19:55 fluxgen Exp $ +// $Id: BaseDisplay.hh,v 1.18 2002/03/23 02:02:01 pekdon Exp $ #ifndef BASEDISPLAY_HH #define BASEDISPLAY_HH

@@ -172,8 +172,8 @@ unsigned int getHead(int x, int y) const;

unsigned int getCurrHead(void) const; unsigned int getHeadWidth(unsigned int head) const; unsigned int getHeadHeight(unsigned int head) const; - int getHeadX(unsigned int head); - int getHeadY(unsigned int head); + int getHeadX(unsigned int head) const; + int getHeadY(unsigned int head) const; #endif // XINERAMA private:
M src/Makefile.amsrc/Makefile.am

@@ -30,7 +30,7 @@ DEFAULT_KEYSFILE=$(pkgdatadir)/keys

DEFAULT_INITFILE= CPPFLAGS= -Wall @CPPFLAGS@ @SHAPE@ @SLIT@ @INTERLACE@ @ORDEREDPSEUDO@ \ -@DEBUG@ @NEWWMSPEC@ @NLS@ @TIMEDCACHE@ @KDE@ @GNOME@ \ +@DEBUG@ @NEWWMSPEC@ @NLS@ @TIMEDCACHE@ @KDE@ @GNOME@ @XINERAMA@ \ -DLOCALEPATH=\"$(pkgdatadir)/nls\" \ -DDEFAULTMENU=\"$(DEFAULT_MENU)\" \ -DDEFAULTSTYLE=\"$(DEFAULT_STYLE)\" \
M util/Makefile.amutil/Makefile.am

@@ -1,7 +1,7 @@

# util/Makefile.am for Blackbox 0.61.x - an X11 Window manager CPPFLAGS= @CPPFLAGS@ @DEBUG@ @NLS@ @TIMEDCACHE@ @NEWWMSPEC@ @INTERLACE@ \ -@ORDEREDPSEUDO@ @KDE@ @GNOME@ +@ORDEREDPSEUDO@ @KDE@ @GNOME@ @XINERAMA@ bin_SCRIPTS = bsetbg bin_PROGRAMS = bsetroot