Skinning contest: One month to go (2 Viewers)

Albert

MP2 Developer
  • Premium Supporter
  • February 18, 2008
    1,297
    1,130
    46
    Freiburg im Breisgau, Germany
    Home Country
    Germany Germany
    AW: Skinning contest: One month to go

    Ok, a team member (Inker) just tested it for me. He also says that VS Express reports a conflict between the Media solution folder and the Media project.
    Anyway, the name "Media" for the solution folder isn't correct any more, so I just renamed it to "Extensions". So in the future, the name conflict should be gone.
     

    narsor

    Portal Member
    August 28, 2010
    42
    11
    Home Country
    Netherlands Netherlands
    Uh, just curious here, can you see the xaml file in Visual Studio in visual designer (not as an xml but in rendering mode)? I am a bit lazy to get the code to try to find out on my own :(
     

    Albert

    MP2 Developer
  • Premium Supporter
  • February 18, 2008
    1,297
    1,130
    46
    Freiburg im Breisgau, Germany
    Home Country
    Germany Germany
    AW: Re: Skinning contest: One month to go

    Uh, just curious here, can you see the xaml file in Visual Studio in visual designer (not as an xml but in rendering mode)? I am a bit lazy to get the code to try to find out on my own :(

    No, you can't let VisualStudio render MPF code. We use another namespace declaration and our controls are slightly different.
    When testing XAML code, you can mostly use code fragments from WPF, but never a complete screen.
     

    FreakyJ

    Retired Team Member
  • Premium Supporter
  • July 25, 2010
    4,024
    1,420
    Home Country
    Germany Germany
    AW: Skinning contest: One month to go

    FluidKit

    This looks pretty interesting. It is a lib for WPF but maybe it will help or inspire somebody ;) You can download it under the tab source.
    There is also an example app (FkuidKit.Showcase [in the source]). (As far as I understood we can use WPF pieces in MPF right?) I didn't dig deeper into the WPF/MPF stuff yet, but maybe I will^^
     

    Albert

    MP2 Developer
  • Premium Supporter
  • February 18, 2008
    1,297
    1,130
    46
    Freiburg im Breisgau, Germany
    Home Country
    Germany Germany
    AW: Skinning contest: One month to go

    FluidKit

    This looks pretty interesting. It is a lib for WPF but maybe it will help or inspire somebody ;) You can download it under the tab source.
    There is also an example app (FkuidKit.Showcase [in the source]). (As far as I understood we can use WPF pieces in MPF right?) I didn't dig deeper into the WPF/MPF stuff yet, but maybe I will^^

    Yes, some of them look nice. We cannot use the code in our SkinEngine directly off course, but at the end, I also want to have some of the effects/controls they provide.
     

    narsor

    Portal Member
    August 28, 2010
    42
    11
    Home Country
    Netherlands Netherlands
    Having a generic capability such as allowing any kind of WPF control renderable on Mediaportal will be harmful in terms of consistency in my opinion, so I hope you don't follow that path. On the other hand, it would be great to have documentation on user controls available (did not check the documentation for MP2, but for MP1.x, it is not good enough, in fact, it is insufficient I'll dare to say :()
     

    DieBagger

    Retired Team Member
  • Premium Supporter
  • September 11, 2007
    2,516
    1,276
    40
    Austria
    Home Country
    Austria Austria
    Having a generic capability such as allowing any kind of WPF control renderable on Mediaportal will be harmful in terms of consistency in my opinion, so I hope you don't follow that path. On the other hand, it would be great to have documentation on user controls available (did not check the documentation for MP2, but for MP1.x, it is not good enough, in fact, it is insufficient I'll dare to say :()
    Of course you can say so because you're absolutely right... ;) We're working on it at the new wiki.
     

    FreakyJ

    Retired Team Member
  • Premium Supporter
  • July 25, 2010
    4,024
    1,420
    Home Country
    Germany Germany
    AW: Skinning contest: One month to go

    So I'm absolutely new to WPF/MPF and it seems really hard to skin in MP2.
    I think I understood your little examplePlugin (HelloWorld), but how to add images?! I was trying hardly to dig into the weatherPlugin, but no way...

    Code:
    <DockPanel
        xmlns="www.team-mediaportal.com/2008/mpf/directx"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Context="{Model Id=5726DA5A-70D5-458f-AF67-611293D97912}" LastChildFill="False">
      <Label Content="This is the sample screen of the HelloWorld plugin" FontSize="40" DockPanel.Dock="Top" HorizontalAlignment="Center"/>
      <StackPanel DockPanel.Dock="Center" Orientation="Horizontal" HorizontalAlignment="Center" VerticalAlignment="Center">
        <Button Content="Press me" Style="{ThemeResource ButtonWideStyle}" Margin="10"
            HorizontalAlignment="Right" VerticalAlignment="Center"
            Command="{Command ChangeHelloWorldString}"/>
        <Label Content="{Binding HelloString}" Margin="10"
            HorizontalAlignment="Left" VerticalAlignment="Center"/>
    
        </StackPanel>
    
        <!-- My own Test -->
    
        <Grid Width="200">
            <Grid.Background>
                <ImageBrush ImageSource="media\01.jpg"/>
            </Grid.Background>
    
            <Grid.ColumnDefinitions>
                <ColumnDefinition />
            </Grid.ColumnDefinitions>
            <Grid.RowDefinitions>
                <RowDefinition Height="200"/>
                <RowDefinition Height="Auto"/>
            </Grid.RowDefinitions>
    
            <!-- The Imagebox -->
    
            <Image Grid.Column="0" Grid.Row="0" Width="200" 
    Source="M:\Programmieren\C#\MediaPortal 2\trunk - Kopie\MediaPortal\Bin\MP2-Client\bin\x86\Debug\Plugins\HelloWorld\Skin\default\media\01.jpg"/>
    
            <!-- Label -->
            <Label Grid.Column="0" Grid.Row="1" Content="Select an Image" />
    
    
        </Grid>
    
    
    </DockPanel>

    I can see the text "Select an Image", but no image >_> Maybe somebody can give me a hint. Do I have to register the media folder in the plugin.xml?! I didn't found anything in the weatherPlugin nor in the documentation.
    Only this:
    Media files

    Media files are all files which provide image or sound to the skin. They are referenced from the screen files. Media files are located in the skin's or theme's media subdirectory (preferred location: skin or theme).

    I also tried
    Code:
    <Image Grid.Column="0" Grid.Row="0" Width="200" 
    Source="01.jpg"/>
    but this also doesn't work.
     

    Albert

    MP2 Developer
  • Premium Supporter
  • February 18, 2008
    1,297
    1,130
    46
    Freiburg im Breisgau, Germany
    Home Country
    Germany Germany
    AW: Skinning contest: One month to go

    Well FreakyJ, as far as I can see, the code should work. The only problem is that currently, JPEG images don't work. You should always have a look at the log output, there you should see a warning about that.
     

    FreakyJ

    Retired Team Member
  • Premium Supporter
  • July 25, 2010
    4,024
    1,420
    Home Country
    Germany Germany
    AW: Skinning contest: One month to go

    Oh sorry, I thought jpg is standard, so I didn't even thought that there could be an error in the log, but yes, there was one^^
    Which formats are supported? As far as I saw there is nothing in the documentation yet.
    And is the a way to use a relative path instead the fullpath? Just 01.png didn't worked for me.

    And at least thanks for your quick replay =)
     

    Users who are viewing this thread

    Top Bottom