自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(8)
  • 收藏
  • 关注

转载 WPF获取当前用户控件的父级窗体

方式一、通过当前控件名获取父级窗体Window targetWindow = Window.GetWindow(button);方式二、通过当前控件获取父级窗体Window parentWindow = Window.GetWindow(this);方式三、类--ApplicationWindow mainwin = Applicati...

2019-04-19 11:09:00 780

转载 WPF RichTextBox不自动换行

1、RichTextBox扩展类using System;using System.Collections.Generic;using System.Globalization;using System.Linq;using System.Text;using System.Windows.Documents;using System.Windows.Me...

2019-03-15 19:03:00 679

转载 WPF控件保存为图片Bitmap

#region 控件保存为图片--放大图 /// <summary> /// 控件保存为图片--可处理放大图 /// </summary> /// <param name="element"></param> /// <re...

2019-03-15 18:54:00 383

转载 WPF MatrixTransform无差别缩放面板

/// <summary> /// 区域--缩放 /// </summary> /// <param name="Multiple">缩放倍数</param> private void SetMatrix(double Multiple) ...

2019-03-15 18:43:00 239

转载 c# 循环com,分别对串口写入与读取,获取需要的串口信息

private SerialPort serialPort;//串口对象类 private string strPortDataReceived = "";//记录串口返回值 private string serialPortName = "";//记录端口号 private bool isGet = false;...

2019-03-15 18:24:00 545

转载 c# 画刻度尺(支持缩放)

// 画标尺 private void DrawRule(double scale)//scale缩放的倍数 { if (cvRuler.Children != null) { cvRuler.Children.Clear(); } S...

2018-11-14 13:01:00 1354

转载 WPF ScrollViewer偏移量设置

//获取scrollViewer的偏移量private void scrollViewer1_ScrollChanged(object sender, ScrollChangedEventArgs e) { offsetValue = e.HorizontalOffset; border_Left.Margin = new T...

2018-11-14 11:37:00 647

转载 WPF 自定义表格(可添加、删除、合并、拆分)

初步效果图:xaml代码<Window xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:d="http://schemas....

2018-07-25 10:06:00 970

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除