private void LeftPanelMouseEnter(object sender, MouseEventArgs e) { if (resizeFlag == false && pinFlag == false && LeftPanel.Width==24 ) { this.RegisterName(LeftPanel.Name, LeftPanel); DoubleAnimation dbani = new DoubleAnimation(); dbani.From = 24; dbani.To = LeftPanelMaxWidth; dbani.Duration = new Duration(TimeSpan.FromSeconds(.7)); Storyboard.SetTargetName(dbani, LeftPanel.Name); Storyboard.SetTargetProperty(dbani, new PropertyPath(Border.WidthProperty)); Storyboard myWidthAnimatedButtonStoryboard = new Storyboard(); myWidthAnimatedButtonStoryboard.Children.Add(dbani); myWidthAnimatedButtonStoryboard.Begin(LeftPanel); mySidebarControl.Visibility = Visibility.Visible; borderSelectedButton.Visibility = Visibility.Visible; scrolviewerRelatedButtons.Visibility = Visibility.Visible; gridMainButtons.Visibility = Visibility.Visible; logoPanel.Visibility = Visibility.Visible; resizeFlag = true; pinButton.ToolTip = Properties.Resources.TOOL_TIP_PINUP_BUTTON_UNCHECKED; scrolviewerRelatedButtons.Margin = new Thickness(24, 0, 0, 0); pinDockPanel.Margin = new Thickness(24, 0, 0, 0); selectedButton.Margin = new Thickness(24, 0, 0, 0); diagnosisButton.Margin = new Thickness(24, 0, 0, 0); firmwareButton.Margin = new Thickness(24, 0, 0, 0); readerSettingButton.Margin = new Thickness(24, 0, 0, 0); logoPanel.Margin = new Thickness(24, 0, 0, 0); mySidebarControl.myNavigationPaneButton.Background = (Brush)FindResource("MySelectedButtonOrangeGradientBrush"); mySidebarControl.myNavigationPaneButton.Foreground = System.Windows.Media.Brushes.Black; mySidebarControl.applicationborder.BorderBrush = (Brush)FindResource("MySelectedButtonOrangeGradientBrush"); } flag1 = false; }
<button content="two words" />
<button> <textblock text="two words" textwrapping="Wrap" /> </Button></button>
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)