![]() The easiest way would be to replace the DropDownEditBox with a Toggle button with IsChecked binding to IsDropDownOpen. Search for DropDownColorPicker in one of the files that ends with. You can do this by creating a custom DropDownColorPicker style by copying and modifying one of the default themes that can be found in the Themes folder of the installation directory. Do you want the popup section of the color picker to appear underneath the button? If so, you'll probably want the button to actually be a DropDownColorPicker. PathDataContext.You are right, building the ColorPicker in the model is not the way to go. PointCollection polygonPoints = new PointCollection() Point3 = new Point(prolongPoint.X - 10, prolongPoint.Y) Point3 = new Point(prolongPoint.X + 10, prolongPoint.Y) TextAnimatedTranslateTransform.BeginAnimation(TranslateTransform.YProperty, daY) TextAnimatedTranslateTransform.BeginAnimation(TranslateTransform.XProperty, daX) LineAnimatedTranslateTransform.BeginAnimation(TranslateTransform.YProperty, daY) LineAnimatedTranslateTransform.BeginAnimation(TranslateTransform.XProperty, daX) Storyboard.SetTargetProperty(daY, new PropertyPath(TranslateTransform.YProperty)) ĭaY.Duration = new Duration(TimeSpan.FromSeconds(0.2)) Ĭolor = (Color)ColorConverter.ConvertFromString("#2E2E2E"),ĪnimatedTranslateTransform.BeginAnimation(TranslateTransform.XProperty, daX) ĪnimatedTranslateTransform.BeginAnimation(TranslateTransform.YProperty, daY) Storyboard.SetTargetName(daY, nameof(animatedTranslateTransform)) Storyboard.SetTargetProperty(daX, new PropertyPath(TranslateTransform.XProperty)) ĭaX.Duration = new Duration(TimeSpan.FromSeconds(0.2)) ĭoubleAnimation daY = new DoubleAnimation() TextPath.RenderTransform = animatedTranslateTransform ĭoubleAnimation daX = new DoubleAnimation() This.RegisterName("TextAnimatedTranslateTransform", animatedTranslateTransform) TranslateTransform TextAnimatedTranslateTransform = Path.RenderTransform = animatedTranslateTransform This.RegisterName("AnimatedTranslateTransform", animatedTranslateTransform) TranslateTransform animatedTranslateTransform = Line3.RenderTransform = LineAnimatedTranslateTransform This.RegisterName("LineAnimatedTranslateTransform", LineAnimatedTranslateTransform) TranslateTransform LineAnimatedTranslateTransform = OffsetY = 10 * Math.Sin(vAngle * Math.PI / 180) OffsetX = 10 * Math.Cos(vAngle * Math.PI / 180) ![]() VAngle = Math.Round(Vector.AngleBetween(v2, v1)) ![]() VAngle = Math.Round(Vector.AngleBetween(v2, -v1)) Var v1 = minPoint - new Point(centenrX, centenrY) MinPoint = new Point(Math.Round( + ) / 2, Math.Round( + ) / 2) Var pathDataContext = path.DataContext as PieBase NameScope.SetNameScope(this, new NameScope()) _popup.VerticalOffset = mousePosition.Y + 20 _popup.HorizontalOffset = mousePosition.X + 20 Var mousePosition = e.GetPosition((UIElement)_canvas.Parent) ![]() Void ShowMousePopup(Path path, MouseEventArgs e) Private void Path_MouseMove1(object sender, MouseEventArgs e) TranslateTransform ttf = new TranslateTransform() ĭt.Line.RenderTransform = new TranslateTransform()ĭt.TextPath.RenderTransform = new TranslateTransform()Ĭolor = (Color)ColorConverter.ConvertFromString("#FF949494"), Private void Path_MouseLeave(object sender, MouseEventArgs e) If (ItemsSource.Count() = 1 & angle = 360) Private double centenrX, centenrY, radius, offsetX, offsetY Using Ĭonst string CanvasTemplateName = "PART_Canvas" Ĭonst string PopupTemplateName = "PART_Popup" ![]()
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |