diff --git a/icewm/configure b/icewm/configure
index 42e5c37..1fa2e8b 100755
--- a/icewm/configure
+++ b/icewm/configure
@@ -7038,8 +7038,8 @@ fi
 
       if test "${PKG_CONFIG}" != ""; then
 	GNOME_VER=2
-	GNOME2_CFLAGS=`pkg-config --cflags gnome-desktop-2.0 libgnomeui-2.0`
-	GNOME2_LIBS=`pkg-config --libs gnome-desktop-2.0 libgnomeui-2.0`
+	GNOME2_CFLAGS=`pkg-config --cflags gnome-desktop-2.0 gnome-vfs-2.0 libgnomeui-2.0 fontconfig`
+	GNOME2_LIBS=`pkg-config --libs gnome-desktop-2.0 gnome-vfs-2.0 libgnomeui-2.0 fontconfig`
 
 
 $as_echo "#define CONFIG_GNOME_MENUS 1" >>confdefs.h
diff --git a/icewm/configure.in b/icewm/configure.in
index 4bd5aef..920b56e 100644
--- a/icewm/configure.in
+++ b/icewm/configure.in
@@ -836,8 +836,8 @@ AC_ARG_ENABLE(menus-gnome2,
     
       if test "${PKG_CONFIG}" != ""; then
 	GNOME_VER=2
-	GNOME2_CFLAGS=`pkg-config --cflags gnome-desktop-2.0 libgnomeui-2.0`
-	GNOME2_LIBS=`pkg-config --libs gnome-desktop-2.0 libgnomeui-2.0`
+	GNOME2_CFLAGS=`pkg-config --cflags gnome-desktop-2.0 gnome-vfs-2.0 libgnomeui-2.0 fontconfig`
+	GNOME2_LIBS=`pkg-config --libs gnome-desktop-2.0 gnome-vfs-2.0 libgnomeui-2.0 fontconfig`
 
 	AC_DEFINE(CONFIG_GNOME_MENUS, 1, [Define to make IceWM more GNOME-friendly])
 
diff --git a/icewm/src/Makefile.in b/icewm/src/Makefile.in
index f5eb325..932a3b6 100644
--- a/icewm/src/Makefile.in
+++ b/icewm/src/Makefile.in
@@ -37,7 +37,7 @@ DEFS =          @DEFS@ \
 CXXFLAGS =      @CXXFLAGS@ $(DEBUG) $(DEFS) `pkg-config gdk-pixbuf-xlib-2.0 --cflags` \
 	        @CORE_CFLAGS@ @IMAGE_CFLAGS@ @AUDIO_CFLAGS@ # `fc-config --cflags`
 LFLAGS =	@LDFLAGS@ 
-LIBS =          @LIBS@ `pkg-config gdk-pixbuf-xlib-2.0 --libs` 
+LIBS =          @LIBS@ `pkg-config gdk-pixbuf-xlib-2.0 --libs` -lfontconfig
 
 CORE_LIBS =     @CORE_LIBS@ # `fc-config --libs`
 IMAGE_LIBS =    @IMAGE_LIBS@
diff --git a/icewm/src/WinMgr.h b/icewm/src/WinMgr.h
index 5a9663e..15a36d2 100644
--- a/icewm/src/WinMgr.h
+++ b/icewm/src/WinMgr.h
@@ -128,7 +128,7 @@
  * this where WIN_WORKSPACE_COUNT comes into play.
  */
 
-#define WinWorkspaceInvalid    (-1L)
+#define WinWorkspaceInvalid    ((unsigned long)-1)
 
 /* workspaces */
 #define XA_WIN_WORKSPACES "_WIN_WORKSPACES"
diff --git a/icewm/src/wmcontainer.cc b/icewm/src/wmcontainer.cc
index d0bc9e4..46d8f52 100644
--- a/icewm/src/wmcontainer.cc
+++ b/icewm/src/wmcontainer.cc
@@ -199,11 +199,13 @@ void YClientContainer::handleConfigureRequest(const XConfigureRequestEvent &conf
 
 void YClientContainer::handleMapRequest(const XMapRequestEvent &mapRequest) {
     if (mapRequest.window == getFrame()->client()->handle()) {
+        manager->lockFocus();
         getFrame()->setState(WinStateMinimized |
                              WinStateHidden |
                              WinStateRollup,
                              0);
-        bool doActivate = true;
+        manager->unlockFocus();
+	bool doActivate = true;
         getFrame()->updateFocusOnMap(doActivate);
         if (doActivate) {
             getFrame()->activateWindow(true);
diff --git a/icewm/src/yapp.cc b/icewm/src/yapp.cc
index e2b269e..f97a74b 100644
--- a/icewm/src/yapp.cc
+++ b/icewm/src/yapp.cc
@@ -269,7 +269,7 @@ int YApplication::mainLoop() {
         }
 #endif
 
-        {
+        if(measure_latency) {
             struct timeval difftime;
             struct timeval curtime;
             gettimeofday(&curtime, 0);
diff --git a/icewm/src/yfont.cc b/icewm/src/yfont.cc
index 81f93bc..543fe2a 100644
--- a/icewm/src/yfont.cc
+++ b/icewm/src/yfont.cc
@@ -12,8 +12,8 @@ static int haveXft = -1;
 
 extern ref<YFont> getXftFont(ustring name, bool antialias);
 extern ref<YFont> getXftFontXlfd(ustring name, bool antialias);
-extern ref<YFont> getCoreFont(ustring name);
-
+extern ref<YFont> getCoreFont(const char*);
+ 
 #ifdef CONFIG_XFREETYPE
 ref<YFont> YFont::getFont(ustring name, ustring xftFont, bool antialias) {
 #else
@@ -46,7 +46,9 @@ ref<YFont> YFont::getFont(ustring name, ustring xftFont, bool) {
 #endif
 
 #ifdef CONFIG_COREFONTS
-    return getCoreFont(name);
+    char tmp[4096]; // XXX: such things should go into getCoreFont directly
+    name.copy(tmp, sizeof(tmp));
+    return getCoreFont(tmp);
 #else
     return null;
 #endif
