Author Topic: XML skin - title bar color  (Read 7404 times)

hiccup

  • Sr. Member
  • ****
  • Posts: 7864
I noticed that the skin I'm working off of uses the same image for all 8 sections...
But yeah, it's just a solid color.

And you probably have set "WindowBorderWidth" to 0 or perhaps 1?
Then it will probably not display the errors that might result from using these incorrect sizes.

Clarence

  • Full Member
  • ***
  • Posts: 145
So in my opinion you are spreading incorrect and confusing information here.

I'm not 'spreading' anything here. Where in my original statement do I say that this is the correct way of doing it? This is the only way of doing it?  Or, indeed, the way you must do it?

For what it's worth, I use a 5x28 pixel image for FormBorderTop and a 5x5 pixel image for all other borders. Worked for me when I used base64 for the image and the same images as .png files in a compiled .xmlc file still work.


The fact that it's prefaced with 'For what it's worth..' shows  that this is just a statement of what I do. Nothing more.

I have no intention of nit-picking this to death. You clearly have your opinions and choose to express them. I have my own opinions and shall choose to keep my own counsel on those.

hiccup

  • Sr. Member
  • ****
  • Posts: 7864
I have no intention of nit-picking this to death. You clearly have your opinions and choose to express them. I have my own opinions and shall choose to keep my own counsel on those.

That's fine.

But over the years there has gone some serious work and effort by many members in getting skinning features and details as right as possible and sharing that information with others.

If somebody then publishes information that goes against what has been established to be correct, it would be good for him to also explain under what circumstances you might get away with doing it like that, and under what circumstances it will cause problems.

Just saying "but this works for me" without understanding or explaining why is not very helpful to others.
 
 

Spidrax

  • Newbie
  • *
  • Posts: 19

edit:
An example what can happen when you use incorrect image sizes such as 5x5:
(and this is a configuration panel, not the main panel border that you may or may not care about)



I've seen this on the top-left corner of the main panel!

And you probably have set "WindowBorderWidth" to 0 or perhaps 1?
Then it will probably not display the errors that might result from using these incorrect sizes.

That setting wasn't in the XML file I'm modding, but adding it and setting it to zero fixes the above issue.
Last Edit: April 28, 2020, 11:51:55 AM by Spidrax

hiccup

  • Sr. Member
  • ****
  • Posts: 7864
I've seen this on the top-left corner of the main panel! Now I know how to fix it :)

Great!

For what it's worth, I've done some testing on the 4x4s because I wasn't sure myself what the exact mechanics these days are.
I do know now...

When using a solid colour, you can (obviously) use the same 4x4 image five times, for border left/right, bottom and bottom corners.

But if you are using details (such as a line) in the borders, MusicBee will run some algorithm on the 4x4s that will slightly change the
colours and brightness.

So if you want pixel/colour perfect borders, you will need to use dedicated 4x1, 4x4 and 1x4 images.

Steven

  • Administrator
  • Sr. Member
  • *****
  • Posts: 34348
The expected dimensions will be buried somewhere on one of the old skin topics.
Most of the corner borders bitmaps are 4x4, mid vertical 4x1, mid horizontal 1x4, and the header bar: L=5x28, Middle=1x28, R=5x28
there is one extra pixel to allow a transition from the border to the header bar
Last Edit: April 28, 2020, 01:06:21 PM by Steven

hiccup

  • Sr. Member
  • ****
  • Posts: 7864
Most of the corner borders bitmaps are 4x4, mid vertical 4x1, mid horizontal 1x4, and the header bar: L=5x28, Middle=1x28, R=5x28
there is one extra pixel to allow a transition from the border to the header bar

Adding to that, you can make FormBorderTop wider than 1 pixel to create image or repetitive pattern effects.
 

And for reference, just to show what happens when you use 4x4 instead of 1x4 for e.g. the bottom border:
(I wasn't aware of this before)

Using 1x4:



Using 4x4:



(colours and brightness were altered)
 
Last Edit: April 28, 2020, 01:58:57 PM by hiccup