| 1 |
using System; |
| 2 |
using System.Collections; |
| 3 |
using System.ComponentModel; |
| 4 |
using System.Drawing; |
| 5 |
using System.Data; |
| 6 |
using System.Windows.Forms; |
| 7 |
|
| 8 |
namespace nft.controls |
| 9 |
{ |
| 10 |
/// <summary> |
| 11 |
/// MsgAndIconLabel の概要の説明です。 |
| 12 |
/// </summary> |
| 13 |
public class MsgAndIconLabel : System.Windows.Forms.UserControl |
| 14 |
{ |
| 15 |
private System.Windows.Forms.Label labelIcon; |
| 16 |
private System.Windows.Forms.Label labelMsg; |
| 17 |
private System.Windows.Forms.Panel mainPanel; |
| 18 |
//private System.ComponentModel.IContainer components; |
| 19 |
|
| 20 |
public MsgAndIconLabel() |
| 21 |
{ |
| 22 |
// この呼び出しは、Windows.Forms フォーム デザイナで必要です。 |
| 23 |
InitializeComponent(); |
| 24 |
|
| 25 |
} |
| 26 |
|
| 27 |
public ImageList ImageList |
| 28 |
{ |
| 29 |
get{ return labelIcon.ImageList; } |
| 30 |
set{ labelIcon.ImageList = value; } |
| 31 |
} |
| 32 |
|
| 33 |
public int ImageIndex |
| 34 |
{ |
| 35 |
get{ return labelIcon.ImageIndex; } |
| 36 |
set{ labelIcon.ImageIndex = value; } |
| 37 |
} |
| 38 |
|
| 39 |
public override string Text |
| 40 |
{ |
| 41 |
get{ return labelMsg.Text; } |
| 42 |
set{ labelMsg.Text = value; } |
| 43 |
} |
| 44 |
|
| 45 |
public string Message |
| 46 |
{ |
| 47 |
get{ return labelMsg.Text; } |
| 48 |
set{ labelMsg.Text = value; } |
| 49 |
} |
| 50 |
|
| 51 |
public new Font Font |
| 52 |
{ |
| 53 |
get{ return labelMsg.Font; } |
| 54 |
set{ labelMsg.Font = value; } |
| 55 |
} |
| 56 |
|
| 57 |
public new BorderStyle BorderStyle |
| 58 |
{ |
| 59 |
get{ return mainPanel.BorderStyle; } |
| 60 |
set{ mainPanel.BorderStyle = value; } |
| 61 |
} |
| 62 |
|
| 63 |
#region コンポーネント デザイナで生成されたコード |
| 64 |
/// <summary> |
| 65 |
/// デザイナ サポートに必要なメソッドです。このメソッドの内容を |
| 66 |
/// コード エディタで変更しないでください。 |
| 67 |
/// </summary> |
| 68 |
private void InitializeComponent() |
| 69 |
{ |
| 70 |
this.labelIcon = new System.Windows.Forms.Label(); |
| 71 |
this.labelMsg = new System.Windows.Forms.Label(); |
| 72 |
this.mainPanel = new System.Windows.Forms.Panel(); |
| 73 |
this.mainPanel.SuspendLayout(); |
| 74 |
this.SuspendLayout(); |
| 75 |
// |
| 76 |
// labelIcon |
| 77 |
// |
| 78 |
this.labelIcon.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) |
| 79 |
| System.Windows.Forms.AnchorStyles.Left))); |
| 80 |
this.labelIcon.BackColor = System.Drawing.Color.Transparent; |
| 81 |
this.labelIcon.Location = new System.Drawing.Point(3, 0); |
| 82 |
this.labelIcon.Name = "labelIcon"; |
| 83 |
this.labelIcon.Size = new System.Drawing.Size(18, 24); |
| 84 |
this.labelIcon.TabIndex = 0; |
| 85 |
// |
| 86 |
// labelMsg |
| 87 |
// |
| 88 |
this.labelMsg.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) |
| 89 |
| System.Windows.Forms.AnchorStyles.Left) |
| 90 |
| System.Windows.Forms.AnchorStyles.Right))); |
| 91 |
this.labelMsg.BackColor = System.Drawing.Color.Transparent; |
| 92 |
this.labelMsg.Location = new System.Drawing.Point(24, 0); |
| 93 |
this.labelMsg.Name = "labelMsg"; |
| 94 |
this.labelMsg.Size = new System.Drawing.Size(192, 24); |
| 95 |
this.labelMsg.TabIndex = 0; |
| 96 |
this.labelMsg.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; |
| 97 |
// |
| 98 |
// mainPanel |
| 99 |
// |
| 100 |
this.mainPanel.Controls.Add(this.labelIcon); |
| 101 |
this.mainPanel.Controls.Add(this.labelMsg); |
| 102 |
this.mainPanel.Dock = System.Windows.Forms.DockStyle.Fill; |
| 103 |
this.mainPanel.Location = new System.Drawing.Point(0, 0); |
| 104 |
this.mainPanel.Name = "mainPanel"; |
| 105 |
this.mainPanel.Size = new System.Drawing.Size(216, 24); |
| 106 |
this.mainPanel.TabIndex = 1; |
| 107 |
// |
| 108 |
// MsgAndIconLabel |
| 109 |
// |
| 110 |
this.BackColor = System.Drawing.SystemColors.Control; |
| 111 |
this.Controls.Add(this.mainPanel); |
| 112 |
this.Name = "MsgAndIconLabel"; |
| 113 |
this.Size = new System.Drawing.Size(216, 24); |
| 114 |
this.mainPanel.ResumeLayout(false); |
| 115 |
this.ResumeLayout(false); |
| 116 |
|
| 117 |
} |
| 118 |
|
| 119 |
/// <summary> |
| 120 |
/// 使用されているリソースに後処理を実行します。 |
| 121 |
/// </summary> |
| 122 |
protected override void Dispose( bool disposing ) |
| 123 |
{ |
| 124 |
// if( disposing ) |
| 125 |
// { |
| 126 |
// if(components != null) |
| 127 |
// { |
| 128 |
// components.Dispose(); |
| 129 |
// } |
| 130 |
// } |
| 131 |
base.Dispose( disposing ); |
| 132 |
} |
| 133 |
#endregion |
| 134 |
} |
| 135 |
} |