Browse Source

优化工具栏

tags/录制修改前
zhangxueyang 4 years ago
parent
commit
6bccf4ac21
1 changed files with 17 additions and 22 deletions
  1. 17
    22
      XHWK.WKTool/PracticeWindow.xaml.cs

+ 17
- 22
XHWK.WKTool/PracticeWindow.xaml.cs View File

30
         /// 0 画笔 1 矩形 2 圆形 
30
         /// 0 画笔 1 矩形 2 圆形 
31
         /// </summary>
31
         /// </summary>
32
         private int flg = 0;
32
         private int flg = 0;
33
+        /// <summary>
34
+        /// 
35
+        /// </summary>
36
+        Color Colour=Colors.Black;
33
         public PracticeWindow()
37
         public PracticeWindow()
34
         {
38
         {
35
             InitializeComponent();
39
             InitializeComponent();
46
             }
50
             }
47
 
51
 
48
 
52
 
49
-            drawingAttributes = new DrawingAttributes
50
-            {
51
-                Color = Colors.Red,
52
-                Width = 2,
53
-                Height = 2,
54
-                StylusTip = StylusTip.Rectangle,
55
-                //FitToCurve = true,
56
-                IsHighlighter = false,
57
-                IgnorePressure = true,
58
-
59
-            };
60
-            blackboard_canvas.DefaultDrawingAttributes = drawingAttributes;
53
+        
61
 
54
 
62
 
55
 
63
 
56
 
89
 
82
 
90
             DataContext = viewModel;
83
             DataContext = viewModel;
91
         }
84
         }
92
-
93
-
94
-
95
         /// <summary>
85
         /// <summary>
96
         /// 画笔颜色事件 白色
86
         /// 画笔颜色事件 白色
97
         /// </summary>
87
         /// </summary>
210
         
200
         
211
             blackboard_canvas.Cursor = Cursors.Pen;
201
             blackboard_canvas.Cursor = Cursors.Pen;
212
         }
202
         }
213
-        private bool IsRound = false;
214
-        StrokeCollection StrokeCollectionRound; 
215
         /// <summary>
203
         /// <summary>
216
         /// 圆
204
         /// 圆
217
         /// </summary>
205
         /// </summary>
218
         public void Round()
206
         public void Round()
219
         {
207
         {
220
             flg = 2;
208
             flg = 2;
209
+            drawingAttributes = new DrawingAttributes
210
+            {
211
+                Color = Colors.Red,
212
+                Width = 2,
213
+                Height = 2,
214
+                StylusTip = StylusTip.Rectangle,
215
+                //FitToCurve = true,
216
+                IsHighlighter = false,
217
+                IgnorePressure = true,
218
+
219
+            };
220
+            blackboard_canvas.DefaultDrawingAttributes = drawingAttributes;
221
             blackboard_canvas.EditingMode = InkCanvasEditingMode.None;
221
             blackboard_canvas.EditingMode = InkCanvasEditingMode.None;
222
         }
222
         }
223
         /// <summary>
223
         /// <summary>
305
             }
305
             }
306
             return pointList;
306
             return pointList;
307
         }
307
         }
308
-
309
-        private void blackboard_canvas_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
310
-        {
311
-
312
-        }
313
         /// <summary>
308
         /// <summary>
314
         /// 鼠标松开时
309
         /// 鼠标松开时
315
         /// </summary>
310
         /// </summary>

Loading…
Cancel
Save