📄 form1.h
字号:
#pragma once
namespace Example {
using namespace System;
using namespace System::ComponentModel;
using namespace System::Collections;
using namespace System::Windows::Forms;
using namespace System::Data;
using namespace System::Drawing;
/// <summary>
/// Form1 摘要
///
/// 警告: 如果更改此类的名称,则需要更改
/// 与此类所依赖的所有 .resx 文件关联的托管资源编译器工具的
/// “资源文件名”属性。否则,
/// 设计器将不能与此窗体的关联
/// 本地化资源正确交互。
/// </summary>
public ref class Form1 : public System::Windows::Forms::Form
{
public:
Form1(void)
{
InitializeComponent();
//
//TODO: 在此处添加构造函数代码
//
}
protected:
/// <summary>
/// 清理所有正在使用的资源。
/// </summary>
~Form1()
{
if (components)
{
delete components;
}
}
private: System::Windows::Forms::PictureBox^ pictureBox1;
protected:
private: System::Windows::Forms::TableLayoutPanel^ tableLayoutPanel1;
private: System::Windows::Forms::TextBox^ textBox1;
private: System::Windows::Forms::RichTextBox^ richTextBox1;
private: System::Windows::Forms::Label^ label3;
private: System::Windows::Forms::Label^ label2;
private: System::Windows::Forms::Panel^ panel1;
private: System::Windows::Forms::Label^ label1;
protected:
private:
/// <summary>
/// 必需的设计器变量。
/// </summary>
System::ComponentModel::Container ^components;
#pragma region Windows Form Designer generated code
/// <summary>
/// 设计器支持所需的方法 - 不要
/// 使用代码编辑器修改此方法的内容。
/// </summary>
void InitializeComponent(void)
{
System::ComponentModel::ComponentResourceManager^ resources = (gcnew System::ComponentModel::ComponentResourceManager(Form1::typeid));
this->pictureBox1 = (gcnew System::Windows::Forms::PictureBox());
this->label2 = (gcnew System::Windows::Forms::Label());
this->label3 = (gcnew System::Windows::Forms::Label());
this->richTextBox1 = (gcnew System::Windows::Forms::RichTextBox());
this->textBox1 = (gcnew System::Windows::Forms::TextBox());
this->tableLayoutPanel1 = (gcnew System::Windows::Forms::TableLayoutPanel());
this->panel1 = (gcnew System::Windows::Forms::Panel());
this->label1 = (gcnew System::Windows::Forms::Label());
(cli::safe_cast<System::ComponentModel::ISupportInitialize^ >(this->pictureBox1))->BeginInit();
this->tableLayoutPanel1->SuspendLayout();
this->panel1->SuspendLayout();
this->SuspendLayout();
//
// pictureBox1
//
this->pictureBox1->Dock = System::Windows::Forms::DockStyle::Fill;
this->pictureBox1->Image = (cli::safe_cast<System::Drawing::Image^ >(resources->GetObject(L"pictureBox1.Image")));
this->pictureBox1->Location = System::Drawing::Point(200, 41);
this->pictureBox1->Name = L"pictureBox1";
this->tableLayoutPanel1->SetRowSpan(this->pictureBox1, 2);
this->pictureBox1->Size = System::Drawing::Size(187, 170);
this->pictureBox1->SizeMode = System::Windows::Forms::PictureBoxSizeMode::StretchImage;
this->pictureBox1->TabIndex = 6;
this->pictureBox1->TabStop = false;
//
// label2
//
this->label2->AutoSize = true;
this->label2->Location = System::Drawing::Point(3, 38);
this->label2->Name = L"label2";
this->label2->Size = System::Drawing::Size(65, 12);
this->label2->TabIndex = 2;
this->label2->Text = L"雇员姓名:";
//
// label3
//
this->label3->AutoSize = true;
this->label3->Location = System::Drawing::Point(3, 65);
this->label3->Name = L"label3";
this->label3->Size = System::Drawing::Size(65, 12);
this->label3->TabIndex = 7;
this->label3->Text = L"基本情况:";
//
// richTextBox1
//
this->richTextBox1->Dock = System::Windows::Forms::DockStyle::Fill;
this->richTextBox1->Location = System::Drawing::Point(78, 68);
this->richTextBox1->Name = L"richTextBox1";
this->richTextBox1->Size = System::Drawing::Size(116, 143);
this->richTextBox1->TabIndex = 8;
this->richTextBox1->Text = L"获北京大学心理学学士学位。她同时完成了冷食的艺术。张颖是国际美食协会的会员。";
//
// textBox1
//
this->textBox1->Dock = System::Windows::Forms::DockStyle::Fill;
this->textBox1->Location = System::Drawing::Point(78, 41);
this->textBox1->Name = L"textBox1";
this->textBox1->Size = System::Drawing::Size(116, 21);
this->textBox1->TabIndex = 9;
this->textBox1->Text = L"张颖";
//
// tableLayoutPanel1
//
this->tableLayoutPanel1->ColumnCount = 3;
this->tableLayoutPanel1->ColumnStyles->Add((gcnew System::Windows::Forms::ColumnStyle(System::Windows::Forms::SizeType::Absolute,
75)));
this->tableLayoutPanel1->ColumnStyles->Add((gcnew System::Windows::Forms::ColumnStyle(System::Windows::Forms::SizeType::Absolute,
122)));
this->tableLayoutPanel1->ColumnStyles->Add((gcnew System::Windows::Forms::ColumnStyle(System::Windows::Forms::SizeType::Absolute,
193)));
this->tableLayoutPanel1->Controls->Add(this->textBox1, 1, 1);
this->tableLayoutPanel1->Controls->Add(this->richTextBox1, 1, 2);
this->tableLayoutPanel1->Controls->Add(this->label3, 0, 2);
this->tableLayoutPanel1->Controls->Add(this->label2, 0, 1);
this->tableLayoutPanel1->Controls->Add(this->pictureBox1, 2, 1);
this->tableLayoutPanel1->Controls->Add(this->panel1, 0, 0);
this->tableLayoutPanel1->Dock = System::Windows::Forms::DockStyle::Fill;
this->tableLayoutPanel1->Location = System::Drawing::Point(0, 0);
this->tableLayoutPanel1->Name = L"tableLayoutPanel1";
this->tableLayoutPanel1->RowCount = 3;
this->tableLayoutPanel1->RowStyles->Add((gcnew System::Windows::Forms::RowStyle(System::Windows::Forms::SizeType::Absolute, 38)));
this->tableLayoutPanel1->RowStyles->Add((gcnew System::Windows::Forms::RowStyle(System::Windows::Forms::SizeType::Absolute, 27)));
this->tableLayoutPanel1->RowStyles->Add((gcnew System::Windows::Forms::RowStyle(System::Windows::Forms::SizeType::Absolute, 149)));
this->tableLayoutPanel1->RowStyles->Add((gcnew System::Windows::Forms::RowStyle(System::Windows::Forms::SizeType::Absolute, 20)));
this->tableLayoutPanel1->Size = System::Drawing::Size(390, 214);
this->tableLayoutPanel1->TabIndex = 0;
//
// panel1
//
this->panel1->BackColor = System::Drawing::SystemColors::HotTrack;
this->tableLayoutPanel1->SetColumnSpan(this->panel1, 3);
this->panel1->Controls->Add(this->label1);
this->panel1->Dock = System::Windows::Forms::DockStyle::Fill;
this->panel1->Location = System::Drawing::Point(3, 3);
this->panel1->Name = L"panel1";
this->panel1->Size = System::Drawing::Size(384, 32);
this->panel1->TabIndex = 10;
//
// label1
//
this->label1->AutoSize = true;
this->label1->Font = (gcnew System::Drawing::Font(L"宋体", 15.75F, System::Drawing::FontStyle::Bold, System::Drawing::GraphicsUnit::Point,
static_cast<System::Byte>(134)));
this->label1->ForeColor = System::Drawing::SystemColors::ControlLightLight;
this->label1->Location = System::Drawing::Point(3, 5);
this->label1->Name = L"label1";
this->label1->Size = System::Drawing::Size(98, 21);
this->label1->TabIndex = 0;
this->label1->Text = L"个人简历";
//
// Form1
//
this->AutoScaleDimensions = System::Drawing::SizeF(6, 12);
this->AutoScaleMode = System::Windows::Forms::AutoScaleMode::Font;
this->ClientSize = System::Drawing::Size(390, 214);
this->Controls->Add(this->tableLayoutPanel1);
this->Name = L"Form1";
this->StartPosition = System::Windows::Forms::FormStartPosition::CenterScreen;
this->Text = L"演示使用表格定位窗体控件";
(cli::safe_cast<System::ComponentModel::ISupportInitialize^ >(this->pictureBox1))->EndInit();
this->tableLayoutPanel1->ResumeLayout(false);
this->tableLayoutPanel1->PerformLayout();
this->panel1->ResumeLayout(false);
this->panel1->PerformLayout();
this->ResumeLayout(false);
}
#pragma endregion
};
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -