Overview

Metadata Utilities contains controls for displaying various field types in the theme. These controls allow the user to separate the individual fields by prefix, exclude individual values from the display and add or remove values to the fields directly in the theme.

The controls currently use a fixed layout similar to the standard theme with a grid with two columns of equal width, the left one displaying an icon and the field name and the right one displaying the respective values one below the other. If the user has set up several prefixes for a field type as virtual fields, these are displayed one below the other like individual fields. This can be influenced to a certain extent with styles.

The controls can thus replace the standard controls for displaying these values.

The controls and how to integrate them

Fields

FeldControl
Age RatingsMetadataUtilities_​AgeRatingPrefixItemControl
CategoriesMetadataUtilities_​CategoryPrefixItemControl
DeveloperMetadataUtilities_​DeveloperPrefixItemControl
FeaturesMetadataUtilities_​FeaturePrefixItemControl
GenresMetadataUtilities_​GenrePrefixItemControl
PlatformsMetadataUtilities_​PlatformPrefixItemControl
PublisherMetadataUtilities_​PublisherPrefixItemControl
RegionsMetadataUtilities_​RegionPrefixItemControl
SeriesMetadataUtilities_​SeriesPrefixItemControl
TagsMetadataUtilities_​TagPrefixItemControl
List of available Controls

Code

The controls can be inserted with the following code:

<ContentControl x:Name="MetadataUtilities_TagPrefixItemControl"
                Tag="&#xEC85;" 
                Visibility="{Binding TagVisibility}" />
  • x:Name: Represents the name of the desired control from the table above.
  • Tag: Specifies the icon that should appear to the left of the field name. Must be specified as the character code for the IcoFont.
  • Visibility: Controls the visibility and, as in the example here, can be based on the visibility of the actual control for the field type in order to be able to deactivate it via the Playnite settings.

Styles

Additional attributes such as margin etc. can of course be specified as an option. The controls also use the following styles to design parts of the control:

  • MdStyleOuterPanel: Style for the outer DockPanel in which the content of the control is located.
  • MdStyleGrid: A separate grid is added for each individual virtual field specified by prefixes, which can be influenced via this style. If there are no prefixes, the control only contains this grid once.
  • MdStyleIcon: Style for the icon of type TextBlock. If the icon is not displayed as a real icon in the theme, this style should be used, for example, to set the font to IcoFont:
<Style x:Key="MdStyleIcon" TargetType="TextBlock" BasedOn="{StaticResource BaseTextBlockStyle}">
    <Setter Property="Width" Value="24"/>
    <Setter Property="FontFamily" Value="{StaticResource FontIcoFont}" />
    <Setter Property="Foreground" Value="{DynamicResource GlyphBrush}" />
</Style>
  • MdStyleTitle: Style of the name of the field of type TextBlock.
  • MdStyleItemOuter: Style of the ItemControl in which the list of field values is located.
  • MdStyleItemPanel: Style of the StackPanel in which the individual values are located.
  • MdStyleItemButton: Style of the button in which a value is displayed.