Shoutbox

Replacing Multi Images Doesn't Seem To Work - Printable Version

-Shoutbox (https://shoutbox.menthix.net)
+-- Forum: MsgHelp Archive (/forumdisplay.php?fid=58)
+--- Forum: Messenger Plus! for Live Messenger (/forumdisplay.php?fid=4)
+---- Forum: Skinning (/forumdisplay.php?fid=41)
+----- Thread: Replacing Multi Images Doesn't Seem To Work (/showthread.php?tid=79958)

Replacing Multi Images Doesn't Seem To Work by Keikonium on 12-12-2007 at 06:17 AM

I am on a windows XP machine, and I have those dullish, almost pastel like window buttons when I hide the titlebar. I see that vista users get the actual vista buttons (more shiney and rounded). So I put some code in my skininfo.xml document to replace the dull buttons, with the shiney buttons:

code:
                    <Graphics><Pictures>
                        <Picture Id="20069"><File>x1.png</File></Picture>
                        <Picture Id="20070"><File>x2.png</File></Picture>
                        <Picture Id="20071"><File>min.png</File></Picture>
                        <Picture Id="20072"><File>max.png</File></Picture>
                    </Pictures></Graphics>

Now when I go and test it in my skin, this is what I see:

[Image: buttonsskinmod.jpg]

The original images are a set of 4, and the new ones are also a set of 4. I think I am doing something wrong, but does anyone know what?
RE: Replacing Multi Images Doesn't Seem To Work by ipab on 12-12-2007 at 07:55 AM

Patch, I told you this should be included in the scripting doc :refuck:


code:
Element[id=atom(w00t)][ContentIndex=0]
{
Content:rcimg(1449);
}
Element[id=atom(w00t)][ContentIndex=1]
{
Content:rcimg(1450);
}
Element[id=atom(w00t)][ContentIndex=2]
{
Content:rcimg(1451);
}
Element[id=atom(w00t)][ContentIndex=3]
{
Content:rcimg(1452);
}




okay what the ContentIndex=# is doing is denoting a certain image to a certain state.

When rles are created, they can have several states in one rle file. This cannot be done with pngs. So what you are saying with ContentIndex=0 is that State 0 is the natural state for it and ContentIndex=1 is another state for it. That way you can have the same element and display different images for different states.
RE: Replacing Multi Images Doesn't Seem To Work by aNILEator on 12-12-2007 at 04:09 PM

skinning doc you mean ipab! (and you said you were going to write a tutorial for this, you should be more explanatory in future :))

If you're replacing the min,max,close buttons search for this code in the corresponding window's Style file in msgres_4005_XXX.txt (where XXX is the window you're replacing the buttons in) these are the Styles Files, 923 is the contact list.

code:
Element[id=atom(minmaxclosebase)]
{
Padding:rcrect(20808);
}
button[id=Atom(FLWMinBtn)]
{
AccName:rcstr(20976);
AccDesc:rcstr(20976);
Content:rcimg(20779);
padding:rcrect(20807);
}
button[id=Atom(FLWMaxBtn)]
{
AccName:rcstr(20977);
AccDesc:rcstr(20977);
Content:rcimg(20780);
padding:rcrect(20807);
}
button[id=Atom(FLWCloseBtn)]
{
AccName:rcstr(20978);
AccDesc:rcstr(20978);
Content:rcimg(20778);
padding:rcrect(20807);
}

Replace it with this code (where 590XX is the new image's you've added)

code:
Element[id=atom(minmaxclosebase)]
{
    Padding:rcrect(20808);
}
button[id=Atom(FLWMinBtn)][ContentIndex=0]
{
    AccName:rcstr(20976);
    AccDesc:rcstr(20976);
    Content:rcimg(59003);
    padding:rcrect(20807);
}
button[id=Atom(FLWMinBtn)][ContentIndex=1]
{
    Content:rcimg(59004);
}
button[id=Atom(FLWMinBtn)][ContentIndex=2]
{
    Content:rcimg(59005);
}
button[id=Atom(FLWMinBtn)][ContentIndex=3]
{
    Content:rcimg(59006);
}
button[id=Atom(FLWMaxBtn)][ContentIndex=0]
{
    AccName:rcstr(20977);
    AccDesc:rcstr(20977);
    Content:rcimg(59007);
    padding:rcrect(20807);
}
button[id=Atom(FLWMaxBtn)][ContentIndex=1]
{
    Content:rcimg(59008);
}
button[id=Atom(FLWMaxBtn)][ContentIndex=2]
{
    Content:rcimg(59009);
}
button[id=Atom(FLWMaxBtn)][ContentIndex=3]
{
    Content:rcimg(59010);
}
button[id=Atom(FLWCloseBtn)][ContentIndex=0]
{
    AccName:rcstr(20978);
    AccDesc:rcstr(20978);
    Content:rcimg(59011);
    padding:rcrect(20807);
}
button[id=Atom(FLWCloseBtn)][ContentIndex=1]
{
    Content:rcimg(59012);
}
button[id=Atom(FLWCloseBtn)][ContentIndex=2]
{
    Content:rcimg(59013);
}
button[id=Atom(FLWCloseBtn)][ContentIndex=3]
{
    Content:rcimg(59014);
}

RE: Replacing Multi Images Doesn't Seem To Work by Keikonium on 12-12-2007 at 08:36 PM

Thanks for your help, but the strings you gave me don't match mine for some reason :\. I am using the newest 8.5 version of WLM.

Here are my strings:

code:
Element[id=atom(minmaxclosebase)]
{
Padding:rcrect(20085);
}
button[id=Atom(FLWTopBtn)]
{
AccName:rcstr(20076);
AccDesc:rcstr(20076);
Content:rcimg(20071);
padding:rcrect(20084);
}
button[id=Atom(FLWMaxBtn)]
{
AccName:rcstr(20077);
AccDesc:rcstr(20077);
Content:rcimg(20072);
padding:rcrect(20084);
}
button[id=Atom(FLWCloseBtn)]
{
AccName:rcstr(20069);
AccDesc:rcstr(20069);
Content:rcimg(20070);
padding:rcrect(20084);
}

It seems that any change I make to those strings will prevent WLM from opening. It signs in, I can get messages and stuff, but the logon window, and the contact list window (which is the portion I am editing) will not open.
RE: Replacing Multi Images Doesn't Seem To Work by aNILEator on 12-12-2007 at 08:39 PM

Ah I probably posted 9.0 strings again.

simply adjust the content:rcimg on each one as I have on mine

and I've done the work for you for creating 9.0 compatibility on minmaxclose buttons :P


Style files..? by Toneo on 12-12-2007 at 08:47 PM

I'm okay with programming but relatively new to Plus skinning. These style files are really confusing to me.

How do you use them? I know that you can use them to have different images for states for buttons in windows, but how?

Thanks.

P.S. All I understand is "ContentIndex" and the curly braces, i'm that confused.


RE: Replacing Multi Images Doesn't Seem To Work by Keikonium on 12-12-2007 at 08:52 PM

So can I use a single image with the 4 button states in it, or do I need a separate image for each state, and thats what the [ContentIndex=X] is for? I'm so noob at this lol :(

Basically I am trying to replace the current dull buttons (that are in the resources) with the shiney buttons that are also in the resources. I am not really making any new custom images, just exchanging one set of images for another set.


RE: Replacing Multi Images Doesn't Seem To Work by aNILEator on 12-12-2007 at 09:07 PM

separate images, only way you can use a single resource is if you had a PNG2RLE converter and only a few people have that.

Just use single images, it's fine :)

if you're just changing them over, then change the ID's that are being called into existence


RE: Style files..? by aNILEator on 12-12-2007 at 09:10 PM

maybe you should download a skin that changes those resources, like apple skin, and see how it works, I've posted help on this in http://shoutbox.menthix.net/showthread.php?tid=79958


RE: Style files..? by Toneo on 12-12-2007 at 09:14 PM

Yeah. I've already looked at Apple Skin and that other topic. The problem is, I can't gather what it actually means or what it does.

If I get a general idea of what each piece means or does, then it clicks and I know what to do.
Sorry if i'm being awkward...


RE: Style files..? by aNILEator on 12-12-2007 at 09:20 PM

Well why did you start a new thread instead of posting in the other one?

basically create each state resource as a separate image then the code calls each into existence when a certain state happens, eg inactive,active,hover and down


RE: Style files..? by Toneo on 12-12-2007 at 09:23 PM

I suppose that sort of makes sense. And sorry, i'll post in the other thread instead next time.

[Moderator edit: threads merged]