using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using Telerik.Windows.Controls;

namespace WpfApplication50
{
    /// <summary>
    /// Interaction logic for Window1.xaml
    /// </summary>
    public partial class Window1 : Window
    {
        public Window1()
        {
            InitializeComponent();
            this.gridview.ItemsSource = GetMessages();
            this.gridview.ColumnsWidthMode = ColumnsWidthMode.Fill;
        }

        private IList<Message> GetMessages()
        {
            return new Message[] {
               new Message { Sender = "tom@hanna-barbera.com", Subject = "Cats are cool"},
                    new Message { Sender = "jerry@hanna-barbera.com", Subject = "Mice are cool" },
                    new Message { Sender = "jerry@hanna-barbera.com", Subject = "Mice are cool" },
                    new Message { Sender = "spike@hanna-barbera.com", Subject = "Dogs are cool" },
                    new Message { Sender = "tom@hanna-barbera.com", Subject = "Cats are cool"   },
                    new Message { Sender = "jerry@hanna-barbera.com", Subject = "Mice are cool" },
                    new Message { Sender = "spike@hanna-barbera.com", Subject = "Dogs are cool" },
                    new Message { Sender = "tom@hanna-barbera.com", Subject = "Cats are cool"   },
                    new Message { Sender = "jerry@hanna-barbera.com", Subject = "Mice are cool" },
                    new Message { Sender = "spike@hanna-barbera.com", Subject = "Dogs are cool"} ,
                    new Message { Sender = "tom@hanna-barbera.com", Subject = "Cats are cool"   },
                    new Message { Sender = "jerry@hanna-barbera.com", Subject = "Mice are cool" },
                    new Message { Sender = "spike@hanna-barbera.com", Subject = "Dogs are cool" }, 
                    new Message { Sender = "jerry@hanna-barbera.com", Subject = "Mice are cool" },
                    new Message { Sender = "jerry@hanna-barbera.com", Subject = "Mice are cool" },
                    new Message { Sender = "spike@hanna-barbera.com", Subject = "Dogs are cool" },
                    new Message { Sender = "tom@hanna-barbera.com", Subject = "Cats are cool"   },
                    new Message { Sender = "jerry@hanna-barbera.com", Subject = "Mice are cool" },
                    new Message { Sender = "spike@hanna-barbera.com", Subject = "Dogs are cool" },
                    new Message { Sender = "tom@hanna-barbera.com", Subject = "Cats are cool"   },
                    new Message { Sender = "jerry@hanna-barbera.com", Subject = "Mice are cool" },
                    new Message { Sender = "spike@hanna-barbera.com", Subject = "Dogs are cool" },
                    new Message { Sender = "tom@hanna-barbera.com", Subject = "Cats are cool"   },
                    new Message { Sender = "jerry@hanna-barbera.com", Subject = "Mice are cool" },
                    new Message { Sender = "spike@hanna-barbera.com", Subject = "Dogs are cool" } 
            };
        }
    }
}
