This commit is contained in:
pekdon 2002-03-23 02:02:01 +00:00
parent 1022df4212
commit e133cf83a3
6 changed files with 40 additions and 14 deletions

View file

@ -22,6 +22,14 @@ changes for 0.1.8:
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:

View file

@ -241,6 +241,23 @@ AC_ARG_ENABLE(
)
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

View file

@ -22,7 +22,7 @@
// 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 @@ ScreenInfo::~ScreenInfo(void) {
// 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 @@ unsigned int ScreenInfo::getCurrHead(void) const {
//----------- 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) {

View file

@ -22,7 +22,7 @@
// 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 @@ public:
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:

View file

@ -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)\" \

View file

@ -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