mIRC Homepage
Posted By: Voice_of_Power Picture window limitations - 02/07/04 01:23 PM
When creating a picwin script in the last couple of days I've run into two limitations.

The first one, which wouldn't be an unreasonable things to add (I think) is a limitation of /drawpic: it can't can the Nth picture/icon out of a dll/exe/icl file, only the first. Now, it just so happens to be that more and more scripters are learning the value of storing their icons in one file, and most DLLs can do it, so /drawpic is imho lacking a little.

So, for the request, could /drawpic please be updated, so it can handle indexes of dll/exe/icl/etc files? Thanks a bunch!


The second limitation I ran into is that I was unable to add a shadow to a window, if you don't know what kind of shadow I mean, try right-clicking somewhere on the screen, and see what's 'below' the popup that apears. wink

There's two ways to solve this problem, one would be to allow the various /draw* commands to draw with transparancy (either by adding a new switch, or by setting a transparency color for a window). The second way would be to add a new switch to the third set of switches in the /window command, so mIRC will draw the shadow itself. Ofcourse the first solution would be preferable, since it also opens up more possibilities for picture windows, though if it's impossible or would take too heavy system resources, don't bother. smile

Thank you for your time.
Posted By: tsoglanos Re: Picture window limitations - 02/07/04 05:10 PM
have you try $rgb(shadow) ? in cobination with -r

Code:
 
window -p @test 
//drawrect -rf @test $rgb(shadow) -1 -1 300 300 600 600
 
Posted By: tidy_trax Re: Picture window limitations - 02/07/04 05:24 PM
He's talking about the little shadow that appears beneath a popup, atm it's a bit complicated to do that, your method won't work.
Posted By: tsoglanos Re: Picture window limitations - 02/07/04 05:37 PM
i was think he is talking about $rgb(shadow).,.
Posted By: tsoglanos Re: Picture window limitations - 02/07/04 05:41 PM
and if you create a menu @winname {

your popups dont have this shadow?, i am on windows ME

i dont have any shadow,.
Posted By: tidy_trax Re: Picture window limitations - 02/07/04 05:50 PM
The shadow's there for me, windows XP, mIRC 6.15
Posted By: Voice_of_Power Re: Picture window limitations - 02/07/04 05:54 PM
Alright, examples:

With shadow (Internet Explorer popups)


Without shadow (picwin popups)
Posted By: Narusegawa_Naru Re: Picture window limitations - 03/07/04 05:25 AM
create 2 pic wins ofthe same size. the first is the shadow fill it with the shadow color. when you create this window create it 2 pixels to the right and down ofthe planned x,y. then create your second pic win the actual menu and place it at x,y on top of the shadow window.

the drawback is you have 2 windows open but a menu is designed to be short lived so i see no harm in it (dont forget to create the shadow window with switchbar button).
Posted By: Voice_of_Power Re: Picture window limitations - 03/07/04 11:24 AM
Hmm. Yeah, but what if someone is clever enough to click on the shadow... the shadow would be activated then.. I dunno but I don't think I like that solution a lot smile
Posted By: bamaboy1217 Re: Picture window limitations - 03/07/04 06:37 PM
ok... ive done shadows b4...

just make ur window 2 pixels to far to the right and 2 pixels 2 far down while not a perfect shadow cause it will be off a lil bit... and it wont have the 2 pixel offset from the top or left but then u jsut drawrect -f your whole window with grey then drawrect -f the same window -2 pixel width and height with white... and then u got a sort of a shadow

it gets the job done.... at least
Posted By: Narusegawa_Naru Re: Picture window limitations - 03/07/04 10:47 PM
even so. isnt there an on activate or some similar event? if the shadow window is activated simply reactivate the main popup window. also make sure your popup window is design as an on top window (so it doesnt fall below in the z order). For permanent windows i would agree with you but a popup is only active for seconds on most occasions so the likelyhood of a problem is slim.

Of course there will always be those who may pick it apart but then again nothing you can do is flawless for those people smile
Posted By: Voice_of_Power Re: Picture window limitations - 03/07/04 10:50 PM
Well ok I will try it out smirk

But I'd still like to see transparent drawing! laugh
Posted By: Narusegawa_Naru Re: Picture window limitations - 04/07/04 01:50 AM
couldnt you also make both windows desktop ones and use transparency on the dropshadow window? Just curious if it can be done.

I agree transparent drawing would be nice. what about winrgn.dll didnt it have a function to remove a particular color from the visible region? anyhow it might be worth a try smile
Posted By: Mpdreamz Re: Picture window limitations - 05/07/04 02:08 PM
or perhaps Demid.dll is able to as well.
but thinking about the fact Vops popups are dll-less
and for that reason liked by many. transparant work around with dlls would be a waste of time. and a 2 pix grey border just dont cut it :tongue:
Posted By: Online Re: Picture window limitations - 07/07/04 09:12 PM
v6.16 versions.txt:

32.Added /drawpic -o command, indicates that you have specified an [N] value before the filename which is the index of the icon in the file.
Posted By: Voice_of_Power Re: Picture window limitations - 07/07/04 09:55 PM
Yup, I've seen it. Nice! smile
© mIRC Discussion Forums