Browse Source

Remove the TokenizedTextBox component from the release 1.6.0.

import/raw
Nebuleux_cp 15 years ago
parent
commit
2a1a092dd7
  1. 8
      Release/v1.6.0/ExtendedWPFToolkitSolution/Src/Samples/Modules/Samples.Modules.Text/Views/HomeView.xaml
  2. 41
      Release/v1.6.0/ExtendedWPFToolkitSolution/Src/Samples/Modules/Samples.Modules.Text/Views/HomeView.xaml.cs
  3. 1
      Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/Themes/Generic.xaml
  4. BIN
      Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/TokenizedTextBox/Images/delete8.png
  5. 54
      Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/TokenizedTextBox/Implementation/Token.cs
  6. 44
      Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/TokenizedTextBox/Implementation/TokenItem.cs
  7. 392
      Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/TokenizedTextBox/Implementation/TokenizedTextBox.cs
  8. 35
      Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/TokenizedTextBox/Implementation/TokenizedTextBoxCommands.cs
  9. 78
      Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/TokenizedTextBox/Themes/Generic.xaml
  10. 11
      Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/WPFToolkit.Extended.csproj
  11. 1
      Release/v1.6.0/ExtendedWPFToolkitSolution_35/Src/WPFToolkit.Extended/Themes/Generic.xaml
  12. BIN
      Release/v1.6.0/ExtendedWPFToolkitSolution_35/Src/WPFToolkit.Extended/TokenizedTextBox/Images/delete8.png
  13. 78
      Release/v1.6.0/ExtendedWPFToolkitSolution_35/Src/WPFToolkit.Extended/TokenizedTextBox/Themes/Generic.xaml
  14. 19
      Release/v1.6.0/ExtendedWPFToolkitSolution_35/Src/WPFToolkit.Extended/WPFToolkit.Extended.csproj

8
Release/v1.6.0/ExtendedWPFToolkitSolution/Src/Samples/Modules/Samples.Modules.Text/Views/HomeView.xaml

@ -23,12 +23,6 @@
xmlns:extToolkit="http://schemas.microsoft.com/winfx/2006/xaml/presentation/toolkit/extended" xmlns:extToolkit="http://schemas.microsoft.com/winfx/2006/xaml/presentation/toolkit/extended"
Title="Text Controls"> Title="Text Controls">
<Grid> <Grid>
<extToolkit:TokenizedTextBox x:Name="_textBox" <TextBlock Text="Text View" />
DisplayMemberPath="FullName"
SearchMemberPath="FirstName"
ValueMemberPath="Id"
HorizontalAlignment="Center"
VerticalAlignment="Center"
Width="250" />
</Grid> </Grid>
</infControls:DemoView> </infControls:DemoView>

41
Release/v1.6.0/ExtendedWPFToolkitSolution/Src/Samples/Modules/Samples.Modules.Text/Views/HomeView.xaml.cs

@ -16,8 +16,6 @@
Visit http://xceed.com and follow @datagrid on Twitter. Visit http://xceed.com and follow @datagrid on Twitter.
**********************************************************************/ **********************************************************************/
using System;
using System.Collections.Generic;
using Microsoft.Practices.Prism.Regions; using Microsoft.Practices.Prism.Regions;
using Samples.Infrastructure.Controls; using Samples.Infrastructure.Controls;
@ -32,45 +30,6 @@ namespace Samples.Modules.Text.Views
public HomeView() public HomeView()
{ {
InitializeComponent(); InitializeComponent();
_textBox.Text = "1;2;"; //is of object ids
_textBox.ItemsSource = new List<Email>()
{
new Email() { Id = 1, FirstName = "John", LastName = "Doe", EmailAddress = "john@test.com" },
new Email() { Id = 2, FirstName = "Jane", LastName = "Doe", EmailAddress = "jane@test.com" },
};
}
public class Email
{
public int Id
{
get;
set;
}
public string FirstName
{
get;
set;
}
public string LastName
{
get;
set;
}
public string EmailAddress
{
get;
set;
}
public string FullName
{
get
{
return String.Format( "{0}, {1}", LastName, FirstName );
}
}
} }
} }
} }

1
Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/Themes/Generic.xaml

@ -47,7 +47,6 @@
<ResourceDictionary Source="/WPFToolkit.Extended;component/SplitButton/Themes/Generic.xaml" /> <ResourceDictionary Source="/WPFToolkit.Extended;component/SplitButton/Themes/Generic.xaml" />
<ResourceDictionary Source="/WPFToolkit.Extended;component/PropertyGrid/Themes/Generic.xaml" /> <ResourceDictionary Source="/WPFToolkit.Extended;component/PropertyGrid/Themes/Generic.xaml" />
<ResourceDictionary Source="/WPFToolkit.Extended;component/TimePicker/Themes/Generic.xaml" /> <ResourceDictionary Source="/WPFToolkit.Extended;component/TimePicker/Themes/Generic.xaml" />
<ResourceDictionary Source="/WPFToolkit.Extended;component/TokenizedTextBox/Themes/Generic.xaml" />
<ResourceDictionary Source="/WPFToolkit.Extended;component/WatermarkTextBox/Themes/Generic.xaml" /> <ResourceDictionary Source="/WPFToolkit.Extended;component/WatermarkTextBox/Themes/Generic.xaml" />
<ResourceDictionary Source="/WPFToolkit.Extended;component/Wizard/Themes/Generic.xaml" /> <ResourceDictionary Source="/WPFToolkit.Extended;component/Wizard/Themes/Generic.xaml" />
</ResourceDictionary.MergedDictionaries> </ResourceDictionary.MergedDictionaries>

BIN
Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/TokenizedTextBox/Images/delete8.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 312 B

54
Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/TokenizedTextBox/Implementation/Token.cs

@ -1,54 +0,0 @@
/************************************************************************
Extended WPF Toolkit
Copyright (C) 2010-2012 Xceed Software Inc.
This program is provided to you under the terms of the Microsoft Reciprocal
License (Ms-RL) as published at http://wpftoolkit.codeplex.com/license
This program can be provided to you by Xceed Software Inc. under a
proprietary commercial license agreement for use in non-Open Source
projects. The commercial version of Extended WPF Toolkit also includes
priority technical support, commercial updates, and many additional
useful WPF controls if you license Xceed Business Suite for WPF.
Visit http://xceed.com and follow @datagrid on Twitter.
**********************************************************************/
using System;
namespace Microsoft.Windows.Controls
{
internal class Token
{
public string Delimiter
{
get;
private set;
}
public object Item
{
get;
set;
}
private string _tokenKey;
public string TokenKey
{
get
{
return _tokenKey;
}
set
{
_tokenKey = String.Format( "{0}{1}", value, Delimiter );
}
}
public Token( string delimiter )
{
Delimiter = delimiter;
}
}
}

44
Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/TokenizedTextBox/Implementation/TokenItem.cs

@ -1,44 +0,0 @@
/************************************************************************
Extended WPF Toolkit
Copyright (C) 2010-2012 Xceed Software Inc.
This program is provided to you under the terms of the Microsoft Reciprocal
License (Ms-RL) as published at http://wpftoolkit.codeplex.com/license
This program can be provided to you by Xceed Software Inc. under a
proprietary commercial license agreement for use in non-Open Source
projects. The commercial version of Extended WPF Toolkit also includes
priority technical support, commercial updates, and many additional
useful WPF controls if you license Xceed Business Suite for WPF.
Visit http://xceed.com and follow @datagrid on Twitter.
**********************************************************************/
using System.Windows;
using System.Windows.Controls;
namespace Microsoft.Windows.Controls
{
public class TokenItem : ContentControl
{
static TokenItem()
{
DefaultStyleKeyProperty.OverrideMetadata( typeof( TokenItem ), new FrameworkPropertyMetadata( typeof( TokenItem ) ) );
}
public static readonly DependencyProperty TokenKeyProperty = DependencyProperty.Register( "TokenKey", typeof( string ), typeof( TokenItem ), new UIPropertyMetadata( null ) );
public string TokenKey
{
get
{
return ( string )GetValue( TokenKeyProperty );
}
set
{
SetValue( TokenKeyProperty, value );
}
}
}
}

392
Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/TokenizedTextBox/Implementation/TokenizedTextBox.cs

@ -1,392 +0,0 @@
/************************************************************************
Extended WPF Toolkit
Copyright (C) 2010-2012 Xceed Software Inc.
This program is provided to you under the terms of the Microsoft Reciprocal
License (Ms-RL) as published at http://wpftoolkit.codeplex.com/license
This program can be provided to you by Xceed Software Inc. under a
proprietary commercial license agreement for use in non-Open Source
projects. The commercial version of Extended WPF Toolkit also includes
priority technical support, commercial updates, and many additional
useful WPF controls if you license Xceed Business Suite for WPF.
Visit http://xceed.com and follow @datagrid on Twitter.
**********************************************************************/
//Based of the code written by Pavan Podila
//http://blog.pixelingene.com/2010/10/tokenizing-control-convert-text-to-tokens/
using System;
using System.Linq;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
namespace Microsoft.Windows.Controls
{
public class TokenizedTextBox : ItemsControl
{
#region Members
private System.Windows.Controls.RichTextBox _rtb = null;
private bool _surpressTextChanged = false;
private bool _surpressTextChangedEvent = false;
#endregion //Members
#region Properties
public static readonly DependencyProperty SearchMemberPathProperty = DependencyProperty.Register( "SearchMemberPath", typeof( string ), typeof( TokenizedTextBox ), new UIPropertyMetadata( String.Empty ) );
public string SearchMemberPath
{
get
{
return ( string )GetValue( SearchMemberPathProperty );
}
set
{
SetValue( SearchMemberPathProperty, value );
}
}
public static readonly DependencyProperty TokenDelimiterProperty = DependencyProperty.Register( "TokenDelimiter", typeof( string ), typeof( TokenizedTextBox ), new UIPropertyMetadata( ";" ) );
public string TokenDelimiter
{
get
{
return ( string )GetValue( TokenDelimiterProperty );
}
set
{
SetValue( TokenDelimiterProperty, value );
}
}
public static readonly DependencyProperty TokenTemplateProperty = DependencyProperty.Register( "TokenTemplate", typeof( DataTemplate ), typeof( TokenizedTextBox ), new UIPropertyMetadata( null ) );
public DataTemplate TokenTemplate
{
get
{
return ( DataTemplate )GetValue( TokenTemplateProperty );
}
set
{
SetValue( TokenTemplateProperty, value );
}
}
#region Text
public static readonly DependencyProperty TextProperty = DependencyProperty.Register( "Text", typeof( string ), typeof( TokenizedTextBox ), new UIPropertyMetadata( null, OnTextChanged ) );
public string Text
{
get
{
return ( string )GetValue( TextProperty );
}
set
{
SetValue( TextProperty, value );
}
}
private static void OnTextChanged( DependencyObject o, DependencyPropertyChangedEventArgs e )
{
TokenizedTextBox tokenizedTextBox = o as TokenizedTextBox;
if( tokenizedTextBox != null )
tokenizedTextBox.OnTextChanged( ( string )e.OldValue, ( string )e.NewValue );
}
protected virtual void OnTextChanged( string oldValue, string newValue )
{
if( _rtb == null || _surpressTextChanged )
return;
//TODO: when text changes update tokens
}
#endregion //Text
public static readonly DependencyProperty ValueMemberPathProperty = DependencyProperty.Register( "ValueMemberPath", typeof( string ), typeof( TokenizedTextBox ), new UIPropertyMetadata( String.Empty ) );
public string ValueMemberPath
{
get
{
return ( string )GetValue( ValueMemberPathProperty );
}
set
{
SetValue( ValueMemberPathProperty, value );
}
}
#endregion //Properties
#region Constructors
static TokenizedTextBox()
{
DefaultStyleKeyProperty.OverrideMetadata( typeof( TokenizedTextBox ), new FrameworkPropertyMetadata( typeof( TokenizedTextBox ) ) );
}
public TokenizedTextBox()
{
CommandBindings.Add( new CommandBinding( TokenizedTextBoxCommands.Delete, DeleteToken ) );
}
#endregion //Constructors
#region Base Class Overrides
public override void OnApplyTemplate()
{
base.OnApplyTemplate();
if( _rtb != null )
{
_rtb.TextChanged -= RichTextBox_TextChanged;
_rtb.PreviewKeyDown -= RichTextBox_PreviewKeyDown;
}
_rtb = GetTemplateChild( "PART_ContentHost" ) as System.Windows.Controls.RichTextBox;
if( _rtb != null )
{
_rtb.TextChanged += RichTextBox_TextChanged;
_rtb.PreviewKeyDown += RichTextBox_PreviewKeyDown;
}
InitializeTokensFromText();
}
#endregion //Base Class Overrides
#region Event Handlers
private void RichTextBox_TextChanged( object sender, TextChangedEventArgs e )
{
if( _surpressTextChangedEvent )
return;
var text = _rtb.CaretPosition.GetTextInRun( LogicalDirection.Backward );
var token = ResolveToken( text );
if( token != null )
{
ReplaceTextWithToken( text.Trim(), token );
}
}
void RichTextBox_PreviewKeyDown( object sender, KeyEventArgs e )
{
InlineUIContainer container = null;
if( e.Key == Key.Back )
{
container = _rtb.CaretPosition.GetAdjacentElement( LogicalDirection.Backward ) as InlineUIContainer;
}
else if( e.Key == Key.Delete )
{
//if the selected text is a blank space, I will assume that a token item is selected.
//if a token item is selected, we need to move the caret position to the left of the element so we can grab the InlineUIContainer
if( _rtb.Selection.Text == " " )
{
TextPointer moveTo = _rtb.CaretPosition.GetNextInsertionPosition( LogicalDirection.Backward );
_rtb.CaretPosition = moveTo;
}
//the cursor is to the left of a token item
container = _rtb.CaretPosition.GetAdjacentElement( LogicalDirection.Forward ) as InlineUIContainer;
}
//if the container is not null that means we have something to delete
if( container != null )
{
var token = ( container as InlineUIContainer ).Child as TokenItem;
if( token != null )
{
SetTextInternal( Text.Replace( token.TokenKey, "" ) );
}
}
}
#endregion //Event Handlers
#region Methods
private void InitializeTokensFromText()
{
if( !String.IsNullOrEmpty( Text ) )
{
string[] tokenKeys = Text.Split( new string[] { TokenDelimiter }, StringSplitOptions.RemoveEmptyEntries );
foreach( string tokenKey in tokenKeys )
{
var para = _rtb.CaretPosition.Paragraph;
var token = new Token( TokenDelimiter )
{
TokenKey = tokenKey,
Item = ResolveItemByTokenKey( tokenKey )
};
para.Inlines.Add( CreateTokenContainer( token ) );
}
}
}
private Token ResolveToken( string text )
{
if( text.EndsWith( TokenDelimiter ) )
return ResolveTokenBySearchMemberPath( text.Substring( 0, text.Length - 1 ).Trim() );
return null;
}
private Token ResolveTokenBySearchMemberPath( string searchText )
{
//create a new token and default the settings to the search text
var token = new Token( TokenDelimiter )
{
TokenKey = searchText,
Item = searchText
};
if( ItemsSource != null )
{
foreach( object item in ItemsSource )
{
var searchProperty = item.GetType().GetProperty( SearchMemberPath );
if( searchProperty != null )
{
var searchValue = searchProperty.GetValue( item, null );
if( searchText.Equals( searchValue.ToString(), StringComparison.InvariantCultureIgnoreCase ) )
{
var valueProperty = item.GetType().GetProperty( ValueMemberPath );
if( valueProperty != null )
token.TokenKey = valueProperty.GetValue( item, null ).ToString();
token.Item = item;
break;
}
}
}
}
return token;
}
private object ResolveItemByTokenKey( string tokenKey )
{
if( ItemsSource != null )
{
foreach( object item in ItemsSource )
{
var property = item.GetType().GetProperty( ValueMemberPath );
if( property != null )
{
var value = property.GetValue( item, null );
if( tokenKey.Equals( value.ToString(), StringComparison.InvariantCultureIgnoreCase ) )
return item;
}
}
}
return tokenKey;
}
private void ReplaceTextWithToken( string inputText, Token token )
{
_surpressTextChangedEvent = true;
var para = _rtb.CaretPosition.Paragraph;
var matchedRun = para.Inlines.FirstOrDefault( inline =>
{
var run = inline as Run;
return ( run != null && run.Text.EndsWith( inputText ) );
} ) as Run;
if( matchedRun != null ) // Found a Run that matched the inputText
{
var tokenContainer = CreateTokenContainer( token );
para.Inlines.InsertBefore( matchedRun, tokenContainer );
// Remove only if the Text in the Run is the same as inputText, else split up
if( matchedRun.Text == inputText )
{
para.Inlines.Remove( matchedRun );
}
else // Split up
{
var index = matchedRun.Text.IndexOf( inputText ) + inputText.Length;
var tailEnd = new Run( matchedRun.Text.Substring( index ) );
para.Inlines.InsertAfter( matchedRun, tailEnd );
para.Inlines.Remove( matchedRun );
}
//now append the Text with the token key
SetTextInternal( Text + token.TokenKey );
}
_surpressTextChangedEvent = false;
}
private InlineUIContainer CreateTokenContainer( Token token )
{
return new InlineUIContainer( CreateTokenItem( token ) )
{
BaselineAlignment = BaselineAlignment.Center
};
}
private TokenItem CreateTokenItem( Token token )
{
object item = token.Item;
var tokenItem = new TokenItem()
{
TokenKey = token.TokenKey,
Content = item,
ContentTemplate = TokenTemplate
};
if( TokenTemplate == null )
{
//if no template was supplied let's try to get a value from the object using the DisplayMemberPath
if( !String.IsNullOrEmpty( DisplayMemberPath ) )
{
var property = item.GetType().GetProperty( DisplayMemberPath );
if( property != null )
{
var value = property.GetValue( item, null );
if( value != null )
tokenItem.Content = value;
}
}
}
return tokenItem;
}
private void DeleteToken( object sender, ExecutedRoutedEventArgs e )
{
var para = _rtb.CaretPosition.Paragraph;
Inline inlineToRemove = para.Inlines.Where( inline => inline is InlineUIContainer && ( ( inline as InlineUIContainer ).Child as TokenItem ).TokenKey.Equals( e.Parameter ) ).FirstOrDefault();
if( inlineToRemove != null )
para.Inlines.Remove( inlineToRemove );
//update Text to remove delimited value
SetTextInternal( Text.Replace( e.Parameter.ToString(), "" ) );
}
private void SetTextInternal( string text )
{
_surpressTextChanged = true;
Text = text;
_surpressTextChanged = false;
}
#endregion //Methods
}
}

35
Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/TokenizedTextBox/Implementation/TokenizedTextBoxCommands.cs

@ -1,35 +0,0 @@
/************************************************************************
Extended WPF Toolkit
Copyright (C) 2010-2012 Xceed Software Inc.
This program is provided to you under the terms of the Microsoft Reciprocal
License (Ms-RL) as published at http://wpftoolkit.codeplex.com/license
This program can be provided to you by Xceed Software Inc. under a
proprietary commercial license agreement for use in non-Open Source
projects. The commercial version of Extended WPF Toolkit also includes
priority technical support, commercial updates, and many additional
useful WPF controls if you license Xceed Business Suite for WPF.
Visit http://xceed.com and follow @datagrid on Twitter.
**********************************************************************/
using System.Windows.Input;
namespace Microsoft.Windows.Controls
{
public static class TokenizedTextBoxCommands
{
private static RoutedCommand _deleteCommand = new RoutedCommand();
public static RoutedCommand Delete
{
get
{
return _deleteCommand;
}
}
}
}

78
Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/TokenizedTextBox/Themes/Generic.xaml

@ -1,78 +0,0 @@
<!--*********************************************************************
Extended WPF Toolkit
Copyright (C) 2010-2012 Xceed Software Inc.
This program is provided to you under the terms of the Microsoft Reciprocal
License (Ms-RL) as published at http://wpftoolkit.codeplex.com/license
This program can be provided to you by Xceed Software Inc. under a
proprietary commercial license agreement for use in non-Open Source
projects. The commercial version of Extended WPF Toolkit also includes
priority technical support, commercial updates, and many additional
useful WPF controls if you license Xceed Business Suite for WPF.
Visit http://xceed.com and follow @datagrid on Twitter.
********************************************************************-->
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Microsoft.Windows.Controls">
<Style TargetType="{x:Type local:TokenItem}">
<Setter Property="Background" Value="#F3F7FD" />
<Setter Property="BorderBrush" Value="#BBD8FB" />
<Setter Property="BorderThickness" Value="1" />
<Setter Property="Cursor" Value="Arrow" />
<Setter Property="Padding" Value="5,1,5,1" />
<Setter Property="Margin" Value="1,0" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:TokenItem}">
<Border Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}"
Padding="{TemplateBinding Padding}"
Margin="{TemplateBinding Margin}">
<StackPanel Orientation="Horizontal" Margin="1">
<ContentPresenter ContentTemplate="{TemplateBinding ContentTemplate}" />
<Button Margin="3,0,0,0" Cursor="Hand" Command="local:TokenizedTextBoxCommands.Delete" CommandParameter="{TemplateBinding TokenKey}">
<Button.Template>
<ControlTemplate TargetType="Button">
<ContentPresenter />
</ControlTemplate>
</Button.Template>
<Image Source="/WPFToolkit.Extended;component/TokenizedTextBox/Images/delete8.png" Width="8" Height="8" />
</Button>
</StackPanel>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type local:TokenizedTextBox}">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:TokenizedTextBox}">
<Border x:Name="Bd"
Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}">
<Grid>
<RichTextBox x:Name="PART_ContentHost" AcceptsReturn="False" IsDocumentEnabled="True" Padding="-3,0,0,0" />
<!--<Popup>
<Grid Background="White">
<ItemsPresenter />
</Grid>
</Popup>-->
</Grid>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>

11
Release/v1.6.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/WPFToolkit.Extended.csproj

@ -187,10 +187,6 @@
<SubType>Designer</SubType> <SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
</Page> </Page>
<Page Include="TokenizedTextBox\Themes\Generic.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="WatermarkTextBox\Themes\Generic.xaml"> <Page Include="WatermarkTextBox\Themes\Generic.xaml">
<SubType>Designer</SubType> <SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
@ -327,10 +323,6 @@
<Compile Include="TimePicker\Implementation\TimeFormat.cs" /> <Compile Include="TimePicker\Implementation\TimeFormat.cs" />
<Compile Include="TimePicker\Implementation\TimeItem.cs" /> <Compile Include="TimePicker\Implementation\TimeItem.cs" />
<Compile Include="TimePicker\Implementation\TimePicker.cs" /> <Compile Include="TimePicker\Implementation\TimePicker.cs" />
<Compile Include="TokenizedTextBox\Implementation\Token.cs" />
<Compile Include="TokenizedTextBox\Implementation\TokenItem.cs" />
<Compile Include="TokenizedTextBox\Implementation\TokenizedTextBox.cs" />
<Compile Include="TokenizedTextBox\Implementation\TokenizedTextBoxCommands.cs" />
<Compile Include="VisualStates.cs" /> <Compile Include="VisualStates.cs" />
<Compile Include="MessageBox\Implementation\VisualStates.MessageBox.cs" /> <Compile Include="MessageBox\Implementation\VisualStates.MessageBox.cs" />
<Compile Include="WatermarkTextBox\Implementation\WatermarkTextBox.cs" /> <Compile Include="WatermarkTextBox\Implementation\WatermarkTextBox.cs" />
@ -416,9 +408,6 @@
<ItemGroup> <ItemGroup>
<Resource Include="MultiLineTextEditor\Images\Notes16.png" /> <Resource Include="MultiLineTextEditor\Images\Notes16.png" />
</ItemGroup> </ItemGroup>
<ItemGroup>
<Resource Include="TokenizedTextBox\Images\delete8.png" />
</ItemGroup>
<ItemGroup /> <ItemGroup />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it. <!-- To modify your build process, add your task inside one of the targets below and uncomment it.

1
Release/v1.6.0/ExtendedWPFToolkitSolution_35/Src/WPFToolkit.Extended/Themes/Generic.xaml

@ -47,7 +47,6 @@
<ResourceDictionary Source="/WPFToolkit.Extended;component/SplitButton/Themes/Generic.xaml" /> <ResourceDictionary Source="/WPFToolkit.Extended;component/SplitButton/Themes/Generic.xaml" />
<ResourceDictionary Source="/WPFToolkit.Extended;component/PropertyGrid/Themes/Generic.xaml" /> <ResourceDictionary Source="/WPFToolkit.Extended;component/PropertyGrid/Themes/Generic.xaml" />
<ResourceDictionary Source="/WPFToolkit.Extended;component/TimePicker/Themes/Generic.xaml" /> <ResourceDictionary Source="/WPFToolkit.Extended;component/TimePicker/Themes/Generic.xaml" />
<ResourceDictionary Source="/WPFToolkit.Extended;component/TokenizedTextBox/Themes/Generic.xaml" />
<ResourceDictionary Source="/WPFToolkit.Extended;component/WatermarkTextBox/Themes/Generic.xaml" /> <ResourceDictionary Source="/WPFToolkit.Extended;component/WatermarkTextBox/Themes/Generic.xaml" />
<ResourceDictionary Source="/WPFToolkit.Extended;component/Wizard/Themes/Generic.xaml" /> <ResourceDictionary Source="/WPFToolkit.Extended;component/Wizard/Themes/Generic.xaml" />
</ResourceDictionary.MergedDictionaries> </ResourceDictionary.MergedDictionaries>

BIN
Release/v1.6.0/ExtendedWPFToolkitSolution_35/Src/WPFToolkit.Extended/TokenizedTextBox/Images/delete8.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 312 B

78
Release/v1.6.0/ExtendedWPFToolkitSolution_35/Src/WPFToolkit.Extended/TokenizedTextBox/Themes/Generic.xaml

@ -1,78 +0,0 @@
<!--*********************************************************************
Extended WPF Toolkit
Copyright (C) 2010-2012 Xceed Software Inc.
This program is provided to you under the terms of the Microsoft Reciprocal
License (Ms-RL) as published at http://wpftoolkit.codeplex.com/license
This program can be provided to you by Xceed Software Inc. under a
proprietary commercial license agreement for use in non-Open Source
projects. The commercial version of Extended WPF Toolkit also includes
priority technical support, commercial updates, and many additional
useful WPF controls if you license Xceed Business Suite for WPF.
Visit http://xceed.com and follow @datagrid on Twitter.
********************************************************************-->
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Microsoft.Windows.Controls">
<Style TargetType="{x:Type local:TokenItem}">
<Setter Property="Background" Value="#F3F7FD" />
<Setter Property="BorderBrush" Value="#BBD8FB" />
<Setter Property="BorderThickness" Value="1" />
<Setter Property="Cursor" Value="Arrow" />
<Setter Property="Padding" Value="5,1,5,1" />
<Setter Property="Margin" Value="1,0" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:TokenItem}">
<Border Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}"
Padding="{TemplateBinding Padding}"
Margin="{TemplateBinding Margin}">
<StackPanel Orientation="Horizontal" Margin="1">
<ContentPresenter ContentTemplate="{TemplateBinding ContentTemplate}" />
<Button Margin="3,0,0,0" Cursor="Hand" Command="local:TokenizedTextBoxCommands.Delete" CommandParameter="{TemplateBinding TokenKey}">
<Button.Template>
<ControlTemplate TargetType="Button">
<ContentPresenter />
</ControlTemplate>
</Button.Template>
<Image Source="/WPFToolkit.Extended;component/TokenizedTextBox/Images/delete8.png" Width="8" Height="8" />
</Button>
</StackPanel>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type local:TokenizedTextBox}">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:TokenizedTextBox}">
<Border x:Name="Bd"
Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}">
<Grid>
<RichTextBox x:Name="PART_ContentHost" AcceptsReturn="False" IsDocumentEnabled="True" Padding="-3,0,0,0" />
<!--<Popup>
<Grid Background="White">
<ItemsPresenter />
</Grid>
</Popup>-->
</Grid>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>

19
Release/v1.6.0/ExtendedWPFToolkitSolution_35/Src/WPFToolkit.Extended/WPFToolkit.Extended.csproj

@ -209,10 +209,6 @@
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="TokenizedTextBox\Themes\Generic.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="WatermarkTextBox\Themes\Generic.xaml"> <Page Include="WatermarkTextBox\Themes\Generic.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
@ -550,18 +546,6 @@
<Compile Include="..\..\..\ExtendedWPFToolkitSolution\Src\WPFToolkit.Extended\TimePicker\Implementation\TimePicker.cs"> <Compile Include="..\..\..\ExtendedWPFToolkitSolution\Src\WPFToolkit.Extended\TimePicker\Implementation\TimePicker.cs">
<Link>TimePicker\Implementation\TimePicker.cs</Link> <Link>TimePicker\Implementation\TimePicker.cs</Link>
</Compile> </Compile>
<Compile Include="..\..\..\ExtendedWPFToolkitSolution\Src\WPFToolkit.Extended\TokenizedTextBox\Implementation\Token.cs">
<Link>TokenizedTextBox\Implementation\Token.cs</Link>
</Compile>
<Compile Include="..\..\..\ExtendedWPFToolkitSolution\Src\WPFToolkit.Extended\TokenizedTextBox\Implementation\TokenItem.cs">
<Link>TokenizedTextBox\Implementation\TokenItem.cs</Link>
</Compile>
<Compile Include="..\..\..\ExtendedWPFToolkitSolution\Src\WPFToolkit.Extended\TokenizedTextBox\Implementation\TokenizedTextBox.cs">
<Link>TokenizedTextBox\Implementation\TokenizedTextBox.cs</Link>
</Compile>
<Compile Include="..\..\..\ExtendedWPFToolkitSolution\Src\WPFToolkit.Extended\TokenizedTextBox\Implementation\TokenizedTextBoxCommands.cs">
<Link>TokenizedTextBox\Implementation\TokenizedTextBoxCommands.cs</Link>
</Compile>
<Compile Include="..\..\..\ExtendedWPFToolkitSolution\Src\WPFToolkit.Extended\VisualStates.cs"> <Compile Include="..\..\..\ExtendedWPFToolkitSolution\Src\WPFToolkit.Extended\VisualStates.cs">
<Link>VisualStates.cs</Link> <Link>VisualStates.cs</Link>
</Compile> </Compile>
@ -664,9 +648,6 @@
<Resource Include="CollectionEditors\Images\Delete16.png" /> <Resource Include="CollectionEditors\Images\Delete16.png" />
<Resource Include="MultiLineTextEditor\Images\Notes16.png" /> <Resource Include="MultiLineTextEditor\Images\Notes16.png" />
</ItemGroup> </ItemGroup>
<ItemGroup>
<Resource Include="TokenizedTextBox\Images\delete8.png" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it. <!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets. Other similar extension points exist, see Microsoft.Common.targets.

Loading…
Cancel
Save