Skip to content

Addition in a custom theme

Lacro59 edited this page Jan 19, 2022 · 28 revisions

You can see a example with https://github.com/Lacro59/playnite-defaultextend-theme.

Differents resources disponible with PluginSettings

The SourceName for the plugin is SuccessStory

Plugin settings

CustomOption Type Default Description
EnableIntegrationButton bool false Parameters to display or not the plugin button.
EnableIntegrationButtonDetails bool false Parameters to display or not more infos in the plugin button.
EnableIntegrationViewItem bool false Parameters to display or not a simple item games list.
EnableIntegrationProgressBar bool false Parameters to display or not the plugin progress bar.
EnableIntegrationCompact bool false Parameters to display or not the plugin list compact.
EnableIntegrationCompactLocked bool false Parameters to display or not the plugin list compact with unlocked.
EnableIntegrationCompactUnlocked bool false Parameters to display or not the plugin list compact with locked.
EnableIntegrationChart bool false Parameters to display or not the plugin chart with unlocked.
EnableIntegrationUserStats bool false Parameters to display or not the plugin list with user game stats.
EnableIntegrationList bool false Parameters to display or not the plugin list with all achievements.

Plugin data for game selected

CustomOption Type Default Description
HasData bool false Indicates if the game has data.
Is100Percent bool false Indicates if all achievements are unlocked.
Unlocked int 0 Count of unlocked achievements.
Locked int 0 Count of locked achievements.
Total int 0 Count total of achievements.
Percent int 0 Percent of unlocked.
EstimateTimeToUnlock string string.Empty Estimate time to full unlock.
ListAchievements List List.Empty details

Integration of plugin elements with ContentControl

Visibility

Visibility according to the presence of the plugin

<StackPanel Visibility="{PluginStatus Plugin=<PluginId>, Status=Installed}">
</StackPanel>

Visibility depending the element visibility parameter in plugin settings

If the item is not enabled in the plugin settings, it is collapsed.

Visibility according to the visibility of the element

<StackPanel Visibility="{Binding ElementName=<SourceName>_<ElementName>, Path=Visibility}">
</StackPanel>

Plugin elements

ViewItem (supporting the different options in the plugin settings)

<ContentControl x:Name="SuccessStory_PluginViewItem" />

Button (supporting the different options in the plugin settings)

<ContentControl x:Name="SuccessStory_PluginButton" />

Graphic datetime unlock achievements (supporting the different options in the plugin settings)

<ContentControl x:Name="SuccessStory_PluginChart" />

Height is managed in plugin settings but you can defined a MinHeight and MaxHeight.

List with all achievements (supporting the different options in the plugin settings)

<ContentControl x:Name="SuccessStory_PluginList" />

Height is managed in plugin settings but you can defined a MinHeight and MaxHeight.

List compact with all achievements (supporting the different options in the plugin settings)

<ContentControl x:Name="SuccessStory_PluginCompactList" />

Height is managed in plugin settings but you can defined a MinHeight and MaxHeight.

ProgressBar with your achievement progression (supporting the different options in the plugin settings)

<ContentControl x:Name="SuccessStory_PluginProgressBar" />

Compact list with achievements unlocked (supporting the different options in the plugin settings)

<ContentControl x:Name="SuccessStory_PluginCompactUnlocked" />

Height is managed in plugin settings but you can defined a MinHeight and MaxHeight.

Compact list with achievements locked (supporting the different options in the plugin settings)

<ContentControl x:Name="SuccessStory_PluginCompactLocked" />

Height is managed in plugin settings but you can defined a MinHeight and MaxHeight.

User game stats (supporting the different options in the plugin settings)

<ContentControl x:Name="SuccessStory_PluginUserStats" />

Height is managed in plugin settings but you can defined a MinHeight and MaxHeight.

Custom elements with plugin data

Button (example)

<Button Name="PART_CustomScButton">
    <ContentControl x:Name="SuccessStory_PluginViewItem" />
</Button>
Clone this wiki locally