?? renameentry.cs
字號(hào):
?// RenameEntry.cs
// Copyright (C) 2000 Mike Krueger
//
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation; either version 2
// of the License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
using System;
using System.Windows.Forms;
namespace ResEdit {
/// <summary>
/// This dialog is for editing a key entry
/// </summary>
public class RenameEntry : Form
{
private System.ComponentModel.Container components;
private Button button2;
private Button button1;
private TextBox textBox1;
private Label label1;
private GroupBox groupBox1;
public string Value;
public RenameEntry(string name)
{
InitializeComponent();
Icon = null;
textBox1.Text = name;
textBox1.Focus();
}
public override void Dispose()
{
base.Dispose();
components.Dispose();
}
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
this.groupBox1 = new GroupBox();
this.button1 = new Button();
this.textBox1 = new TextBox();
this.button2 = new Button();
this.label1 = new Label();
groupBox1.Location = new System.Drawing.Point(8, 8);
groupBox1.TabStop = false;
groupBox1.Text = "Entry";
groupBox1.Size = new System.Drawing.Size(272, 72);
button1.Location = new System.Drawing.Point(8, 88);
button1.DialogResult = DialogResult.OK;
button1.Size = new System.Drawing.Size(75, 23);
button1.TabIndex = 1;
button1.Text = "OK";
button1.Click += new System.EventHandler(button1_Click);
textBox1.Location = new System.Drawing.Point(8, 32);
textBox1.TabIndex = 0;
textBox1.Size = new System.Drawing.Size(256, 20);
button2.Location = new System.Drawing.Point(96, 88);
button2.DialogResult = DialogResult.Cancel;
button2.Size = new System.Drawing.Size(75, 23);
button2.TabIndex = 2;
button2.Text = "Cancel";
label1.Location = new System.Drawing.Point(8, 16);
label1.Text = "&Name";
label1.Size = new System.Drawing.Size(40, 16);
label1.TabIndex = 0;
this.Text = "Rename Resource";
this.MaximizeBox = false;
this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
this.CancelButton = button2;
this.FormBorderStyle = FormBorderStyle.FixedDialog;
this.ShowInTaskbar = false;
this.AcceptButton = button1;
this.TopMost = true;
this.MinimizeBox = false;
this.ControlBox = false;
this.ClientSize = new System.Drawing.Size(290, 119);
groupBox1.Controls.Add(textBox1);
groupBox1.Controls.Add(label1);
this.Controls.Add(button2);
this.Controls.Add(button1);
this.Controls.Add(groupBox1);
StartPosition = FormStartPosition.CenterScreen;
}
protected void button1_Click(object sender, System.EventArgs e)
{
Value = textBox1.Text;
}
}
}
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -