📄 setting.cs
字号:
using System;
using System.Collections.Generic;
using System.Text;
using System.Drawing;
namespace BinaryTree
{
/// <summary>
/// Setting 类用于设定环境变量
/// </summary>
class Setting
{
public static int[] initTree = new int[] { 50, 33, 89, 20, 45, 60, 95, 10, 25, 40 }; // 用以初始化Tree
public static int distanceHeight = 50; // 两个节点之间的高度差
public static int distanceWidth = 20; // 两个节点之间的宽度差
public static int disHChange = 3; // 高度差的变化幅度
public static int disWChange = 1; // 宽度差的变化幅度
public static int nodeRadius = 15; // 节点圆圈的半径
public static int radiusChange = 2; // 节点圆圈半径的变化幅度
public static int radiusMin = 15; // 节点圆圈半径所允许的最小值
public static int middleX = 300; // 绘图中心点的横坐标
public static int middleY = 260; // 绘图中心点的纵坐标
public static int screenH = 350; // 屏幕高度
public static int screenW = 600; // 屏幕宽度
public static Color backColor = Color.LightSteelBlue; // 背景颜色
private static Color fontColor = Color.Black; // 字体颜色
public static Brush fontBrush = new SolidBrush(fontColor);
private static Color lineColor = Color.Orange; // 线条颜色
public static SolidBrush cirBrush = new SolidBrush(lineColor);
public static Pen myPen = new Pen(lineColor);
public static float myPenChange = 1F;
public static Font myFont = new Font("Arial", 18, FontStyle.Regular, GraphicsUnit.Pixel);
public static float fontChange = 2.8F;
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -