Jump to content
LaunchBox Community Forums

XAML Tips and Tricks


Recommended Posts

@shinra358 Ahahah.

Yes, They come from DarkUmbra forum. You need to creat a forum acount for download and go into topics. Unfortunately many platform are missing and the resolution is low (600x300px). Enough for my little 1024x768px. I had to do (or redo) a lot myself.
Maybe I will take the time to create an entire HD set myself, based on this style. I will share it then!

Well, now : the code tricks ! :P

Edited by viking
Link to comment
Share on other sites

Doh! But me not want no shadow :(

Okay, okay. Here ya go:

Find these values:

CameraZPosition="3.0" VisibleCount="14"

 

Decrease the value of CameraZPosition to make the platform images on the wheel bigger.

Located here: PlatformWheelImageDetailsThumbsFiltersView.xaml

 

VisibleCount only draws the specified number of platforms to show (I think).

You can do this the same way in the game wheel section.

 

bigplat.jpg

bigplat2.jpg

 

Link to comment
Share on other sites

You should make a Wiki for launchbox where we can post all this stuff, would be easier than using a forum to look up reference code.  You could have sections on how to set up different systems on it too (you already have the videos you can put as links on it).

Edited by spektor56
  • Like 3
Link to comment
Share on other sites

Here's the MinimalHD theme done 100% in XAML instead of using images if people want to see how to do it.

https://drive.google.com/open?id=0B6VxVfJp98SldDlwVjJ4RjA3SUU

It just uses plain background colours, 2 triangle polygons, and 2 drop shadows.  The scan line effect is done with a 1x5px tiled transparent png.  An important setting i found was SnapsToDevicePixels , without this setting there was a tiny gap between grid columns and rows.

Edited by spektor56
  • Like 3
Link to comment
Share on other sites

Thanks @shinra358 ! The Wheel Logo code works whell =)

Now remains to find out how to align  logos to the left !! (not centered) Any ideas everybody ?

And with the latest update, I could integrate the platform images from "DEVICE" folder. But not against, there is no more transition effect !!! If I a copy / paste  the old code, I get an error message. How to do that? (I wish a vertical sliding on these images from the DEVICE folder)

Link to comment
Share on other sites

  • 3 weeks later...

Hi code killers ! I'm totally noob and I need help for my theme. Here, I work on GameList page.

I make this :test_gameview.jpgThis is the goal (original EmulationStation theme):theming_list.png

  • How force TextBlock to show text in CAPITAL ?
  • How force TextBlock to fix a text size, aligned right, with a automatic return line ?
  • I do not have the stars in the "RATING". Still the good code from "documentation.pdf" ?
  • Where change color / font to the game list?
  • I do not know how to leave the platform logo of the list. And put it on the top left ?

Thx !!

  • Like 1
Link to comment
Share on other sites

Hi @viking, awesome progress here.

1. This might work: 


<TextBox CharacterCasing="Upper" Text="{StaticResource String1}" />

2. If you change the name of the TextBlock, it should no longer be automatically dynamically sized. TextBlock has these properties which should help: TextWrapping, TextTrimming, HorizontalAlignment, VerticalAlignment

3. I need to come up with a solution for the stars there; added that to my list.

4. In ThemedStyles, there's the ListBoxItemStyle.xaml and ListBoxStyle.xaml files. I think those would be the best place to set the font and color for the text lists.

5. The platform logo can be turned off in the options, or you can simply get rid of it from the TextListView.xaml file. You can add it somewhere else and refer to the Documentation.pdf for that.

I can elaborate more on any of these if needed. :)

  • Like 1
Link to comment
Share on other sites

With star rating, I've noticed none of game have a star rating and when trying to update the metadata it's still not updating the star rating, so all my games are at 0 stars. Only way I can get the star rating to show is if I go into LaunchBox and to the game and rate the game there myself with a star rating. It will then show in BigBox in the theme where I added the code. Is this normal?

Link to comment
Share on other sites

Thanks @Jason Carr !

#1. Capital text : Your code is not working. I have an error in Visual Studio and in BigBox. Maybe I badly integrated ?! 

#2. Text size : I found a way.

#3. Stars : I found a solution, in other theme code ! Thx to @Grila =)

#4. Text color : I found, thx !

#5. Platform logo : Yes, I could delete the options ! But impossible to place the top left (instead of GameClearLogo in my screen)

All I need is one thing: the platform logo at the top left. According Documentation.pdf :

This line call the GameClearLogo. I dont whant that here.


<Image Source="{Binding Path=SelectedGame.ClearLogoImagePath}" />

This line call the PlatformClearLogo. But this dont work in game page ! Blank aera.


<Image Source="{Binding Path=SelectedPlatform.ClearLogoImagePath}" />

How do I do that ???

 

I'm not going to pollute more this thread. More in the dedicated thread.

StationEmulation_WIP_003.jpg

Thx all xD

Edited by viking
  • Like 1
Link to comment
Share on other sites

Ah, gotcha. Per #1, I haven't ever tried that to be honest, I just did a web search and that's what came up. I hadn't thought about that for #5, so that might not be possible currently. I'll add both of those options to my list to take a look at soon. :)

That is looking really great though!!!

@Sithel, yes the star ratings do not currently come from the games database as of yet, but that is on the docket to add. :)

  • Like 1
Link to comment
Share on other sites

Hi guys, i didnt wanna start a whole new topic to ask this question. I have a modded 'MinimalHD' theme that i have been messing with for my own use... I had these little tags that popped up for a games respective playmode & age rating. During 6.9-beta these worked perfectly and heres an example of how it looked...




<Image Source="pack://siteoforigin:,,,/Themes/My Theme\Images\Tags\Multiplayer\2 Players.png" RenderOptions.BitmapScalingMode="HighQuality" DockPanel.Dock="right" Margin="0,0,5,0">



                        <Image.Style>



                            <Style TargetType="Image">



                                <Setter Property="Visibility" Value="Collapsed" />



                                <Style.Triggers>



                                    <DataTrigger Binding="{Binding SelectedGame.PlayMode}" Value="2 Players">



                                                                            <Setter Property="Visibility" Value="Visible" />



                                    </DataTrigger>

However in 6.10-beta-9 both of these tags have stopped showing i'm guessing because the xml files have been split into separate xmls, this might have something to do with it... But i did the same for games with favourites, portables & broken selected and they still work. Any help on how i can fix this for the current version of launchbox would be very helpful.

Edited by Liam
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...