Ok, so now that you know what all of the default pictures are… Let’s take a look at the file that tells Media Center where and how to display them.
Main.xml
Here, I’ll just print the sections of the main.xml and try to explain them.
<BUTTONS>
<Position Rect="0.9,8.0,22.5,76" NoListRect="35,10,65,90" PlayingNowRect="0.9,8.0,22.5,50.0"
ButtonVerticalSpacing="8" Alignment="1" NoListAlignment="0" />
<Image Bitmap="Buttons\Button.png" Columns="26,?-Flex,26" Rows="15,?-Flex,19" InternalMargins="10,6,10,12" />
<Text TextColor="FFFFFF" SelectedTextColor="FFC32F" Capitalization="0" />
</BUTTONS>
Rectangles: these define where and how big the buttons are displayed in each of the screens. The coordinates are percentages of the screen. So for the Rect property the upper left corner is 0.9% of the screen width from the left and 8.0% of the screen height from the top. The lower left corner is 22.5% of the screen width from the left and 76% of the screen height from the top.
NoListRect is the button area on any screen that doesn’t display a list (pretty much the main screen)
PlayingNowRect is pretty self explanatory. Where and how are the buttons displayed on the Playing Now screen.
Rect is the button area on all the other screens.
ButtonVerticalSpacing: Well… there ya go. The space between the buttons.
Alignment: This is how the buttons are aligned in the rectangle (same is true for NoListAlignment). It is NOT how the text is aligned in the button (text is always centered. You can’t change that at this point).
Columns="26,?-Flex,26" – This means that the top and bottom 26 pixels of the button.png are kept as they are, and whatever is in between is stretched or shrunk to fit the rectangle. The Rows property is handled the same way.
InternalMargins: These are the margins for the text displayed in the buttons. So, if your text is too big or small within the buttons, this is where to go.
TextColor, SelectedTextColor: You don’t have any say over the font, but you do get to choose the color.
Capitalization: self explanatory…
<PIP Rect="1.2,76.5,22.2,97.5" PlayingNowRect="0.9,51.0,99.5,99.5" />
PIP (Picture in Picture) is the rectangle taken up by visualizations or video when not in full screen. You can see the difference in PlayingNowRect and Rect just by switching between the Audio screen and the Playing now screen. I don’t need a half-screen sized visualization in the Playing Now window, so I resize it to the same size as the other windows.
<LIST>
<Position Rect="23.4,8.0,99.5,99.5" PlayingNowRect="23.4,8.0,99.5,50.0" ItemsRect="0,0,100,100"
ImageRect="1,1,99,99" ImageWithTextRect="1,1,99,82" TextRect="1,84,99,98" />
<Text TextColor="FFFFFF" SelectedTextColor="FFC32F" Capitalization="0"/>
<ThumbBackground Bitmap="List\ThumbBackground.png" Columns="10,?-Flex,10" Rows="10,?-Flex,10" InternalMargins="6,6,6,6" />
<ListBackground Bitmap="List\ListBackground.png" Columns="10,?-Flex,10" Rows="10,?-Flex,10" InternalMargins="6,6,6,6" />
<NoThumb Bitmap="List\NoThumb.png" />
<BackThumb Bitmap="List\BackThumb.png" />
<FolderThumb Bitmap="List\FolderThumb.png" />
<Check Bitmap="List\Check.png" ThumbRect="2,59.3,34,81.6" ListRect="95.2,0,100,100" Rows="2,?-Flex,4" Colums="2,?-Flex,3" />
<PlayOverlay Bitmap="List\PlayOverlay.png" ThumbRect="0,60,35,95" ListRect="94,0,100,100" />
</LIST>
Ok, this one looks big, but it’s mostly just stuff we’ve gone over before
The List are the items on the right hand side of the (non main menu) screen. It’s the portion of the library that you’re looking at.
ItemsRect: How much of the space you’ve allotted to the list it actually takes up. Play with it to control the size of your thumbnails.
ItemsWithTextRect: This is the portion of ItemsRect taken up by the actual thumbnail without text.
TextRect: The portion of ItemsRect that’s taken up by text.
The rest is stuff we’ve covered… Really… Play with it!
<SOUNDS Select="..\Shared\Sounds\Select.wav" Enter="..\Shared\Sounds\Enter.wav" Invalid="..\Shared\Sounds\Invalid.wav" Back="..\Shared\Sounds\Back.wav" Forward="..\Shared\Sounds\Forward.wav" />
I’m sure you can figure this bit out. What sound is played for each event (Select, enter, invalid selection, back, forward).
<PICTURE>
<Item Bitmap="..\Shared\Pictures\Setup.png" Location="Setup\***" Rect="70.7,5.3,100,44.4" Alpha="20" Alignment="3" />
<Item Bitmap="..\Shared\Pictures\Playlist.png" Location="Playlists\***" Rect="70.7,5.3,100,44.4" Alpha="20" Alignment="3" />
<Item Bitmap="..\Shared\Pictures\TV.png" Location="TV\***" Rect="70.7,5.3,100,44.4" Alpha="20" Alignment="3" />
<Item Bitmap="..\Shared\Pictures\Audio.png" Location="Audio\***" Rect="70.7,5.3,100,44.4" Alpha="20" Alignment="3" />
<Item Bitmap="..\Shared\Pictures\Images.png" Location="Images\***" Rect="70.7,5.3,100,44.4" Alpha="20" Alignment="3" />
<Item Bitmap="..\Shared\Pictures\Video.png" Location="Video\***" Rect="70.7,5.3,100,44.4" Alpha="20" Alignment="3" />
<Item Bitmap="..\Shared\Pictures\CD & DVD.png" Location="CD & DVD\***" Rect="70.7,5.3,100,44.4" Alpha="20" Alignment="3" />
<Item Bitmap="..\Shared\Pictures\Playing Now.png" Location="Playing Now\***" Rect="70.7,5.3,100,44.4" Alpha="20" Alignment="3" />
<Item Bitmap="Pictures\LocationBackground.png" Location="***" Rect="0.0,0.0,100,7.2" Alpha="100" Alignment="-1" />
</PICTURE>
Pictures! Here’s where you get to display images on the skin. You can display them anywhere on any screen you want. We’ve discussed what Rect does (placement on the screen). The fun thing to play with here is Location. An asterisk ‘*’ in the path is a level in the tree. Eg:
Location="Audio\***"
This image will show up on the main screen when Audio is selected, and on each sub-level of the Audio button.
Location="Audio"
This image will show up ONLY on the main screen when the Audio button is selected and on NO subsequent level.
Location="Audio\*"
This image will show up in the audio screen, but NOT on the main screen even when the audio button is selected.
Location="Audio\HOME"
This image will show up ONLY in the Audio menu when the HOME button is selected.
Play with the Location property. It’s a great way to customize what images are shown in your skin.
<TEXT>
<Item Text="[Location]" Location="***" TextColor="FFFFFF" Rect="2.5,0.2,89.0,5.4" Capitalization="0" Alignment="0" />
<Item Text="[Time]" Location="***" TextColor="FFFFFF" Rect="90.0,0.2,99.0,5.4" Capitalization="0" Alignment="1" />
</TEXT>
These two items put the location in the navigation tree and the system time on the top of the screen. I don’t know if there are any other properties that you can put in [] braces. I’ve tried a few, but to no avail… Once again, the Rect, and Location properties can help customize your skin.
<MENU>
<Text TextColor="FFFFFF" SelectedTextColor="FFC32F" />
<Background Bitmap="Menu\MenuBackground.png" Columns="8,?-Flex,8" Rows="8,?-Flex,8" />
<Item Bitmap="Menu\MenuItem.png" Columns="36,?-Flex,36" Rows="10,?-Flex,10" />
</MENU>
Once again, MENU is the sub-menu on some screens. You can customize everything but RECT.
That’s pretty much the long and the short of creating a Theater View skin. A little experimentation will get you pretty familiar with the main.xml The hardest part of making a skin is creating the graphics. If you don’t have Photoshop, I’d recommend downloading the GIMP. It’s free and cross-platform. And with sites like
www.gimptalk.com and
www.wingimp.org, you won’t run short of tutorials.
If I’ve misled or you need clarification, please let me know.