Click here to Skip to main content
15,893,588 members
Articles / Desktop Programming / WPF

SongBird - a Twitter Hybrid Smart Client

Rate me:
Please Sign up or sign in to vote.
4.97/5 (40 votes)
18 Jun 2009CPOL10 min read 108.6K   1.2K   84  
Using the WCF RESTful services to create a Twitter hybrid Smart Client.
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:Microsoft_Windows_Themes="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    mc:Ignorable="d">
    <!-- Resource dictionary entries should be defined here. -->
    <DataTemplate x:Key="postItem">
        <Grid Width="380">
            <Grid.RowDefinitions>
                <RowDefinition Height="25"/>
                <RowDefinition Height="50"/>
            </Grid.RowDefinitions>
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="50"/>
                <ColumnDefinition Width="*"/>
                <ColumnDefinition Width="150"/>
            </Grid.ColumnDefinitions>
            <Image
                Grid.Column="0"
                Grid.Row="0"
                Grid.RowSpan="2"
                VerticalAlignment="Top"
                Source="{Binding ProfileUrl}"/>
            <Label Grid.Column="1" Grid.Row="0" FontSize="10" Content="{Binding UserName}" VerticalAlignment="Top" />
            <Label
                Grid.Column="2"
                Grid.Row="0"
                HorizontalAlignment="Left"
                FontSize="10"
                VerticalAlignment="Top"
                Content="{Binding Created}"/>
            <TextBlock
                Grid.Column="1"
                Grid.ColumnSpan="2"
                Grid.Row="1"
                VerticalAlignment="Top"
                Padding="2"
                Text="{Binding Text}"
                TextWrapping="Wrap"/>
        </Grid>
    </DataTemplate>
    <Style x:Key="PostFont" TargetType="{x:Type TextElement}">
        <Setter Property="FontSize" Value="12"/>
        <Setter Property="Foreground" Value="#FF286DAC"/>
    </Style>
    <Style x:Key="LoginPageFont" TargetType="{x:Type Label}">
        <Setter Property="FontSize" Value="14"/>
        <Setter Property="Foreground" Value="White"/>
        <Setter Property="FontWeight" Value="Bold"/>
    </Style>
    <Style x:Key="LoginMessageFont" TargetType="{x:Type TextBlock}">
        <Setter Property="FontSize" Value="10"/>
        <Setter Property="Foreground" Value="White"/>
        <Setter Property="FontWeight" Value="Bold"/>
    </Style>
    <Style x:Key="ButtonFocusVisual">
        <Setter Property="Control.Template">
            <Setter.Value>
                <ControlTemplate>
                    <Rectangle
                        Margin="2"
                        SnapsToDevicePixels="true"
                        Stroke="Black"
                        StrokeDashArray="1 2"
                        StrokeThickness="1"/>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <LinearGradientBrush x:Key="ButtonNormalBackground" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Offset="0" Color="#F3F3F3"/>
        <GradientStop Offset="0.5" Color="#EBEBEB"/>
        <GradientStop Offset="0.5" Color="#DDDDDD"/>
        <GradientStop Offset="1" Color="#CDCDCD"/>
    </LinearGradientBrush>
</ResourceDictionary>

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
CEO
United Kingdom United Kingdom
A developer for over 30 years, I've been lucky enough to write articles and applications for Code Project as well as the Intel Ultimate Coder - Going Perceptual challenge. I live in the North East of England with 2 wonderful daughters and a wonderful wife.

I am not the Stig, but I do wish I had Lotus Tuned Suspension.

Comments and Discussions