// 关闭窗口
 public static void designForm_Close(object sender, EventArgs e)
 {
     if (ReportChange_Flag)
     {
         DialogResult _save = MessageBox.Show("是否保存报表文件?", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
         if (_save.ToString().Equals("Yes"))
         {
             RBuild_File.Save_File();
         }
         if (_save.ToString().Equals("No"))
         {
             design_Form._formObject.Close();
         }
     }
     else
     {
         design_Form._formObject.Close();
     }
 }
    /// 点击工具栏图标
    private static void toolControl_Click(object sender, EventArgs e)
    {
        PictureBoxEx pL = (PictureBoxEx)sender;

        switch (pL.Tag)
        {
        case "FILE_NWE":
            RBuild_File.New_File();
            break;

        case "FILE_OPEN":
            RBuild_File.Open_File();
            break;

        case "FILE_SAVE":
            RBuild_File.Save_File();
            break;

        case "FILE_SETPAGE":
            DialogUse_HotKey = true;
            new RBuild_SetPageType().Set_Type();
            break;

        case "FILE_SETDATABASE":
            DialogUse_HotKey = true;
            new RBuild_SetDataBase().Set_Data();
            break;

        case "SYSTEM_CLOSE":
            RBuild_Design.designForm_Close(null, null);
            break;

        case "EDIT_CUT":
            Object_OperationCopy();
            Delete_Control(true);
            break;

        case "EDIT_COPY":
            Object_OperationCopy();
            break;

        case "EDIT_PAST":
            Object_OperationPast(0, 21);
            break;

        case "EDIT_DELETE":
            Delete_Control(true);
            break;

        case "EDIT_CANCEL":
            Object_Operation(0);
            break;

        case "EDIT_REDO":
            Object_Operation(1);
            break;

        case "EDIT_DELALL":
            Object_Record();
            for (int i = 0; i < DraggableObjects.Count; i++)
            {
                Delete_Control(false);
            }
            break;

        case "EDIT_PREVIEW":
            new RBuild_Preview().View();
            break;

        case "EDIT_PRINT":
            break;

        case "DESIGN_PONINTER":
            RBuild_Design.design_Form._formObject.Cursor = Cursors.Default;
            control_Type = -1;
            break;

        case "DESIGN_SHOWLINE":
            Show_Line = !Show_Line;
            page_Install.Invalidate();
            page_Container.Invalidate();
            Print_PageType.Invalidate();
            break;

        case "DESIGN_BAND":
            DialogUse_HotKey = true;
            new RBuild_SetBandRect().Set_Band(0);
            break;

        case "DESIGN_TEXTBOX":
            pL.Cursor    = custom_MouseCursor(control_icon[0], 5, 5);
            control_Type = 1;
            break;

        case "DESIGN_IMGBOX":
            pL.Cursor    = custom_MouseCursor(control_icon[1], 5, 5);
            control_Type = 2;
            break;

        case "DESIGN_SHAPEBOX":
            pL.Cursor    = custom_MouseCursor(control_icon[2], 5, 5);
            control_Type = 3;
            break;

        case "DESIGN_DATAFIELD":
            pL.Cursor    = custom_MouseCursor(control_icon[3], 5, 5);
            control_Type = 4;
            break;

        case "DESIGN_PAGECODE":
            pL.Cursor    = custom_MouseCursor(control_icon[4], 5, 5);
            control_Type = 5;
            break;

        case "DESIGN_FUNCTION":
            pL.Cursor    = custom_MouseCursor(control_icon[5], 5, 5);
            control_Type = 6;
            break;

        case "DESIGN_SETCOLOR":
            DialogUse_HotKey = true;
            new RBuild_SetColor().Set_Colors();
            break;

        case "DESIGN_TOPMOSE":
            ListSwap_Top();
            break;

        case "DESIGN_BOTMOST":
            ListSwap_Bottom();
            break;

        case "DESIGN_SETLEFT":
            Set_BoxPoint(0);
            break;

        case "DESIGN_SETRIGHT":
            Set_BoxPoint(1);
            break;

        case "DESIGN_SETTOP":
            Set_BoxPoint(2);
            break;

        case "DESIGN_SETBOT":
            Set_BoxPoint(3);
            break;

        case "DESIGN_ALEFT":
            Set_FillAlign(0);
            break;

        case "DESIGN_ACENTER":
            Set_FillAlign(1);
            break;

        case "DESIGN_ARIGHT":
            Set_FillAlign(2);
            break;

        case "DESIGN_ATOP":
            Set_FillAlign(3);
            break;

        case "DESIGN_ABOTTOM":
            Set_FillAlign(4);
            break;

        case "DESIGN_LINEBOT":
            Set_LineBorder(0);
            break;

        case "DESIGN_LINETOP":
            Set_LineBorder(1);
            break;

        case "DESIGN_LINELEFT":
            Set_LineBorder(2);
            break;

        case "DESIGN_LINERIGHT":
            Set_LineBorder(3);
            break;

        case "DESIGN_LINENO":
            Set_LineBorder(4);
            break;

        case "DESIGN_LINEEXTER":
            Set_LineBorder(5);
            break;

        case "DESIGN_LINEBIASDOWN":
            Set_LineBorder(6);
            break;

        case "DESIGN_LINE_BIASUP":
            Set_LineBorder(7);
            break;

        case "DESIGN_LINETHICK":
            DialogUse_HotKey = true;
            new RBuild_SetLineThick().Set_Thick();
            break;

        default:
            break;
        }
    }