Page 1 of 1
Iconic for shaped windows
Posted: Thu Jan 29, 2009 7:26 pm
by keyless
This is not a bug in version 2.8.1, but I think it is in versions 2.9 and 3.0
If you make or have a shaped stack window and put a button on it with script to set Iconic to true, the window doesn't minimize to the taskbar like it did just fine in 2.8.1, rather it just moves the window to just below the taskbar with just part of it sticking up above the taskbar.
Is there a solid workaround to get this working? otherwise it is a real dealbreaker to upgrading.
Posted: Thu Jan 29, 2009 8:15 pm
by Mark
Hi keyless,
Have you reported the bug?
Best,
Mark
Posted: Thu Jan 29, 2009 9:42 pm
by TonyL
I can confirm this. I am having the same problem.

Posted: Thu Jan 29, 2009 10:15 pm
by TonyL
Posted: Thu Jan 29, 2009 11:32 pm
by SparkOut
Posted: Fri Jan 30, 2009 4:14 am
by TonyL
there was a bug report
The bug report you refer to has version 2.81 listed as having this problem. I thought only 2.9 and 3.0 were experiencing this problem.
Posted: Fri Jan 30, 2009 4:54 am
by keyless
Mark wrote:Hi keyless,
Have you reported the bug?
Best,
Mark
I was going to report it but I don't actually own 2.9 or 3.0. Someone who does just reported to me that one of my stacks did that in his IDE.
...Yes the earlier report was for 2.8.1 and I don't have that issue 2.8.1 and that is probably why it went inconfirmed for so long.
This was discussed before but it never came to light if it was a clear reproducable bug in 2.9 and 3.0. It looks now that it is.
Can someone who has 3.0 or 2.9 try some work arounds, i suspect locking screen and changing to a regular stack just before setting iconic might work.
Posted: Fri Jan 30, 2009 11:43 am
by Mark
Hi,
I have tested this and can confirm the bug. I have also added a few comments to the QCC (see the links posted above).
As to a workaround, I tried to set an icon in the task bar with a little menu, but this doesn't work correctly because of this bug
http://quality.runrev.com/qacenter/show_bug.cgi?id=7672 . So, I think we're kind of stuck.
Best,
Mark
Posted: Fri Jan 30, 2009 2:43 pm
by malte
The only way I found is to set the windowshape to 0 on suspendstack and set it to the shape again on resumestack. However that looks rather cheesy.

Me thinks I found...
Posted: Sat Jan 31, 2009 12:36 am
by TonyL
A work around.
Please let me know if this work around works. It seems to in 3.0 Gm3
on preOpenStack
set the decorations of this stack to "title"
end preOpenStack
I tried this and it did indeed iconify the stack to the taskbar on startup with a custom window shape. Also, if you hit the windows: "Show Desktop Icon" your stack will iconify to the windows taskbar.
To test, compile a standalone with a custom shape window with the above code in your preOpenStack handler. That's it!
PS if this works for you please donate $1,000000000 to my paypal account.
Let me know if this works, it does for me in XP and Vista
Tony
Posted: Sat Jan 31, 2009 12:47 am
by Mark
Hi Tony,
You did a great job. This works fine for me on Win XP, Rev 3.x.
Best,
Mark
Posted: Sat Jan 31, 2009 12:57 am
by TonyL
You did a great job. This works fine for me on Win XP, Rev 3.x.
Thank you Mark. The only problem I have noticed is if you click on the icon in the taskbar, it does not maximize or minimize like your program would if it was not a custom shape window.
Anyhow, at least the program icon is now visible in the taskbar. That's a good start.
Got it!
Posted: Sat Jan 31, 2009 6:47 am
by TonyL
Finally nailed this ****er.
Works like it's suppose to. Here's what you need to do to make this work:
#1. Your custom shape must be a 1 bit transparency. Gif will work, png-8 will work. png -24 will not work. Haven't tried any other format yet.
# 2. Code:
in your mainstack:
on preOpenStack
set the decorations of this stack to "title","minimize"
end preOpenStack
on unIconifyStack
set the windowshape of this stack to 1519 -- or whatever your custom shape ID is.
set the decorations of this stack to "title","minimize"
set the visible of this stack to true
end unIconifyStack
in your minimize window button:
on mouseUp
set the visible of this stack to false
set the windowshape of this stack to 0
set the iconic of this stack to true
end mouseUp
#3. Now save and compile to standalone. Note after compiling, the title-bar will be visible in your app.
#4. Close rev. Go to your saved standalone folder and delete it.
#5. open rev again. Set your decorations to empty. Set your custom window shape to whatever image id you want to.
#6. Save and compile again.
Now quit rev and run your standalone. If everything is working right, clicking on the icon in the Windows Taskbar will minimize and maxamize your app. Clicking on the "Show Desktop" icon in the Windows Taskbar will also minimize your app to the taskbar. Your minimize button should work too.
Tested in XP and Vista.
The only think I noticed in Vista was a little flicker when maximizing and minimizing.
Test this and let me know how it works on your system. If it holds up that's fantastic. If not, I have to scrap my custom window shape app and go with the standard rect with a titlebar.
Please let me know if you come up with any improvements.
Thanks a lot,
Tony
Correction
Posted: Sat Jan 31, 2009 6:04 pm
by TonyL
on mouseUp
set the visible of this stack to false
set the windowshape of this stack to 0
set the iconic of this stack to true
end mouseUp
It is not necessary to set the widowShape to 0
my bad!
Correction
Posted: Sat Jan 31, 2009 11:41 pm
by TonyL
on unIconifyStack
set the windowshape of this stack to 1519 -- or whatever your custom shape ID is.
set the decorations of this stack to "title","minimize"
set the visible of this stack to true
end unIconifyStack
correction:
on unIconifyStack
set the visible of this stack to true -- no need to set the windowShape or decorations
end unIconifyStack
my bad again...