Hi
After upgrade to version - WPF_Q3_2012_SP1 ,I got 2 regression that i can't fix , Any help appreciate:
1) The size of the slider becomes very big , when i use MaxWidth , the slider cut some of the text i used (i see only 2 value instead of 4 ),
When i define width on each text content the text still big because the slider spaces between each text stay on same size , only the text got the limit .
Any idea how to fix this issue ?
2) The combination of telerik:RadSlider.TickTemplate + label with test + Value="{Binding Path=ScopeSlider, Mode=TwoWay}"
Stop working when i try to initialize the slider with different value .
It's start always from begining
works on win 7 + vs2010
<
telerik:RadSlider
x:Uid
=
"Scope"
x:Name
=
"Scope"
<br> Value="{Binding Path=ScopeSlider, Mode=TwoWay}" Grid.Column="1" Maximum="{Binding Path=MaxScopeZeroIndex}" TickFrequency="1" IsMoveToPointEnabled="true" IsSnapToTickEnabled="True" TickPlacement="BottomRight" Margin="10,0,35,0"><
br
> <
telerik:RadSlider.TickTemplate
><
br
> <
DataTemplate
x:Uid
=
"DataTemplate_1"
><
br
> <
StackPanel
x:Uid
=
"StackPanel_1"
><
br
> <
Ellipse
x:Uid
=
"Ellipse_1"
Width
=
"1"
Height
=
"4"
Fill
=
"Black"
/><
br
> <
Label
x:Uid
=
"Label_2"
Content
=
"{Binding Converter={StaticResource ScopeNameConverter}}"
HorizontalAlignment
=
"Center"
/><
br
> </
StackPanel
><
br
> </
DataTemplate
><
br
> </
telerik:RadSlider.TickTemplate
><
br
> </
telerik:RadSlider
>
I found the next xaml code for windows gridView (template selector):
<DataGridTemplateColumn>What object can I use for DataGridTemplateColumn ?
public
class
WfBehavior : ListBoxDragDropBehavior
{
public
override
void
Drop(DragDropState state)
{
foreach
(
object
o
in
state.DraggedItems)
{
if
(Dropped !=
null
)
{
Dropped(o
as
Element, state.InsertIndex);
}
}
base
.Drop(state);
}
protected
override
bool
IsMovingItems(DragDropState state)
{
return
state.IsSameControl;
}
public
static
event
DroppedEventHandler Dropped;
}
public
delegate
void
DroppedEventHandler(Element element,
int
index);
using
System;
using
System.Collections.Generic;
using
System.Collections.ObjectModel;
using
System.Linq;
using
System.Text;
namespace
ProjectMaster.Core.Business
{
public
class
Project
{
#region Fields
private
string
_name;
private
double
_budget;
private
DateTime _startDate;
private
DateTime _finishDate;
private
int
_duration;
private
ObservableCollection<Phase> _phases;
#endregion
#region Properties
public
string
Name
{
get
{
return
_name; }
set
{ _name = value; }
}
public
double
Budget
{
get
{
return
_budget; }
set
{ _budget = value; }
}
public
DateTime StartDate
{
get
{
return
_startDate; }
set
{ _startDate = value; }
}
public
DateTime FinishDate
{
get
{
return
_finishDate; }
set
{ _finishDate = value; }
}
public
int
Duration
{
get
{
_duration = (_finishDate - _startDate).Days;
return
_duration;
}
set
{ _duration = value; }
}
public
ObservableCollection<Phase> Phases
{
get
{
return
_phases; }
set
{ _phases = value; }
}
#endregion
public
Project(
string
name,
int
budget, DateTime startDate, DateTime finishDate)
{
this
._name = name;
this
._budget = budget;
this
._startDate = startDate;
this
._finishDate = finishDate;
_phases =
new
ObservableCollection<Phase>();
}
}
}
using
System;
using
System.Collections.Generic;
using
System.Collections.ObjectModel;
using
System.Linq;
using
System.Text;
namespace
ProjectMaster.Core.Business
{
public
class
Phase
{
#region Fields
private
string
_name {
get
;
set
; }
private
double
_budget {
get
;
set
; }
private
DateTime _startDate {
get
;
set
; }
private
DateTime _finishDate {
get
;
set
; }
private
int
_duration {
get
;
set
; }
private
ObservableCollection<Task> _tasks {
get
;
set
; }
#endregion
#region Properties
public
string
Name
{
get
{
return
_name; }
set
{ _name = value; }
}
public
double
Budget
{
get
{
return
_budget; }
set
{ _budget = value; }
}
public
DateTime StartDate
{
get
{
return
_startDate; }
set
{ _startDate = value; }
}
public
DateTime FinishDate
{
get
{
return
_finishDate; }
set
{ _finishDate = value; }
}
public
int
Duration
{
get
{
_duration = (_finishDate - _startDate).Days;
return
_duration;
}
set
{ _duration = value; }
}
public
ObservableCollection<Task> Tasks
{
get
{
return
_tasks; }
set
{ _tasks = value; }
}
public
Phase(
string
name,
int
budget, DateTime startDate, DateTime finishDate)
{
this
._name = name;
this
._budget = budget;
this
._startDate = startDate;
this
._finishDate = finishDate;
_tasks =
new
ObservableCollection<Task>();
}
#endregion
}
}
<
telerik:RadTreeListView
Grid.Row
=
"2"
VerticalAlignment
=
"Top"
HorizontalAlignment
=
"Left"
Margin
=
"6,0,0,0"
AutoGenerateColumns
=
"True"
ItemsSource
=
"{Binding Project, Mode=TwoWay}"
SelectedItem
=
"{Binding Item}"
>
<
telerik:RadTreeListView.ChildTableDefinitions
>
<
telerik:TreeListViewTableDefinition
ItemsSource
=
"{Binding Phases}"
/>
<
telerik:TreeListViewTableDefinition
ItemsSource
=
"{Binding Tasks}"
/>
</
telerik:RadTreeListView.ChildTableDefinitions
>
<
telerik:RadTreeListView.Columns
>
<
telerik:GridViewDataColumn
DataMemberBinding
=
"{Binding Name}"
Header
=
"Name"
/>
<
telerik:GridViewDataColumn
Header
=
"Start Date"
DataType
=
"{x:Type System:DateTime}"
>
<
telerik:GridViewDataColumn.CellTemplate
>
<
DataTemplate
>
<
telerik:RadDatePicker
SelectedValue
=
"{Binding StartDate, Mode=TwoWay}"
/>
</
DataTemplate
>
</
telerik:GridViewDataColumn.CellTemplate
>
</
telerik:GridViewDataColumn
>
<
telerik:GridViewDataColumn
Header
=
"Finish Date"
DataType
=
"{x:Type System:DateTime}"
>
<
telerik:GridViewDataColumn.CellTemplate
>
<
DataTemplate
>
<
telerik:RadDatePicker
SelectedValue
=
"{Binding FinishDate, Mode=TwoWay}"
/>
</
DataTemplate
>
</
telerik:GridViewDataColumn.CellTemplate
>
</
telerik:GridViewDataColumn
>
<
telerik:GridViewDataColumn
Header
=
"Duration"
DataMemberBinding
=
"{Binding Duration}"
DataType
=
"{x:Type System:Int32}"
/>
<
telerik:GridViewDataColumn
Header
=
"Budget (Hrs)"
DataMemberBinding
=
"{Binding Budget}"
DataType
=
"{x:Type System:Double}"
/>
</
telerik:RadTreeListView.Columns
>
</
telerik:RadTreeListView
>