Subject: FVWM: Problem when deiconifying/placing tcl/tk windows with fvwm-2.4.8

From: Gerhard Hintermayer <[email-masked]>
Date: Wed, 19 Jun 2002 19:16:51 +0200

Today I tried to upgrade fvwm 2.2.5 to the recent version of fvwm. I have a 
bunch of tcl/tk scripts (running 8.3.2), that used to work in 2.2.5, but don't 
in 2.4.8. The problem is when I try to either center windows or to make them 
popup under the cursor. The tcl interpreter seems to get no information when to 
repaint the window. I sometimes get windows which are not painted at all (no 
widgets). This happens basically when I try to popup a toplevel window under the 
cursor. If the  window is not resizable and not closeable and I press the 
iconify button of the windowmanager the content of the window gets painted, but 
before the window is empty.
The don't close/iconify stuff is:

proc noclose win {
     wm protocol $win WM_DELETE_WINDOW { }
     wm resizable $win 0 0
     bind $win <Unmap> "wm deiconify $win"
}

the popup function is basically update idletasks following the standard 
calculation like on the Tcl Wiki page "Centering a window" http://mini.net/tcl/1254.

I had no time yet to track that down, have to do that tomorrow, but has anyone 
else encountered that problem ?

-- 
Gerhard Hintermayer
http://www.inode.at/g.hintermayer

--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: Marcus Lundblad <[email-masked]>
Date: Wed, 19 Jun 2002 20:28:21 +0200 (CEST)

I also have experienced strange behaviour in TK applications.
Sometimes menus doesn't popup where you would expect. After moving the
window the menu appears where expected.

For example this tutorial program:

------------------------------------------------------------------

#  Create the main message window
message .m -text "Hello Tcl!" -background white
pack .m -expand true -fill both -ipadx 100 -ipady 40

#  Create the main menu bar with a Help-About entry
menu .menubar
menu .menubar.help -tearoff 1
.menubar add cascade -label "Help" -menu .menubar.help -underline 0
.menubar.help add command -label "About Hello ..." \
	-accelerator "F1" -underline 0 \
	-command showAbout

#  Define a procedure - an action for Help-About
proc showAbout {} {
    tk_messageBox -message "Tcl/Tk\nHello Windows\nVersion 1.0" \
	    -title "About Hello"
}

#  Configure the main window
wm title . "Hello Foundation Application"
. configure -menu .menubar -width 200 -height 150
bind . "<Key F1>" {showAbout}

------------------------------------------------------------------------

This is using 2.5.1
This doesn't happen using twm.

//Marcus

---

From: Gerhard Hintermayer <[email-masked]>
Date: Wed, 19 Jun 2002 21:49:06 +0200

Marcus Lundblad wrote:
> [...]

Marcus, do you have an idea, when this "strange behavior" was introduced. It was 
definitely not in 2.2.5, but that's a very old version and I had to upgrade, 
because I needed the StaysOnBottom feature. Versions after 2.4.8 up to the 
development version 2.5.1 you're using seem to have the bug. I'm going to do 
some testing tomorrow, i.e. compile+install some versions between 2.2.5 and 
2.4.8 to see when the bug was introduced :-(

Gerhard

PS: I send this to the list only, since sending to email and cc to list doubles 
the data transfer.
-- 
Gerhard Hintermayer
http://www.inode.at/g.hintermayer

---

From: Marcus Lundblad <[email-masked]>
Date: Wed, 19 Jun 2002 23:36:27 +0200 (CEST)

> definitely not in 2.2.5, but that's a very old version and I had to upgrade, 

I think I've only seen it using 2.5.x releases. If I remeber correctly I
went from 2.4.6 straight to 2.5.0.

//Marcus

---

From: Gerhard Hintermayer <[email-masked]>
Date: Wed, 19 Jun 2002 23:41:50 +0200

> went from 2.4.6 straight to 2.5.0.

Thanks, i'm going to try 2.4.6 tomorrow. Hope it'll work.