mirror of
https://git.do.srb2.org/STJr/UltimateZoneBuilder.git
synced 2024-11-23 04:12:12 +00:00
For some reason, folders in Texture browser were sorted in descending order.
Color Picker plugin: color can now be displayed as HEX or Float.
This commit is contained in:
parent
b477309168
commit
91080d618a
5 changed files with 323 additions and 176 deletions
|
@ -11,6 +11,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "UDMFControls", "..\Plugins\
|
|||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ColorPicker", "..\Plugins\ColorPicker\ColorPicker.csproj", "{A4761900-0EA3-4FE4-A919-847FD5080EFC}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TagExplorer", "..\Plugins\TagExplorer\TagExplorer.csproj", "{BE7917F3-E6FE-4D5B-8FA9-B8E7668AC731}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
|
@ -71,6 +73,16 @@ Global
|
|||
{A4761900-0EA3-4FE4-A919-847FD5080EFC}.Release|Mixed Platforms.Build.0 = Release|x86
|
||||
{A4761900-0EA3-4FE4-A919-847FD5080EFC}.Release|x86.ActiveCfg = Release|x86
|
||||
{A4761900-0EA3-4FE4-A919-847FD5080EFC}.Release|x86.Build.0 = Release|x86
|
||||
{BE7917F3-E6FE-4D5B-8FA9-B8E7668AC731}.Debug|Any CPU.ActiveCfg = Debug|x86
|
||||
{BE7917F3-E6FE-4D5B-8FA9-B8E7668AC731}.Debug|Mixed Platforms.ActiveCfg = Debug|x86
|
||||
{BE7917F3-E6FE-4D5B-8FA9-B8E7668AC731}.Debug|Mixed Platforms.Build.0 = Debug|x86
|
||||
{BE7917F3-E6FE-4D5B-8FA9-B8E7668AC731}.Debug|x86.ActiveCfg = Debug|x86
|
||||
{BE7917F3-E6FE-4D5B-8FA9-B8E7668AC731}.Debug|x86.Build.0 = Debug|x86
|
||||
{BE7917F3-E6FE-4D5B-8FA9-B8E7668AC731}.Release|Any CPU.ActiveCfg = Release|x86
|
||||
{BE7917F3-E6FE-4D5B-8FA9-B8E7668AC731}.Release|Mixed Platforms.ActiveCfg = Release|x86
|
||||
{BE7917F3-E6FE-4D5B-8FA9-B8E7668AC731}.Release|Mixed Platforms.Build.0 = Release|x86
|
||||
{BE7917F3-E6FE-4D5B-8FA9-B8E7668AC731}.Release|x86.ActiveCfg = Release|x86
|
||||
{BE7917F3-E6FE-4D5B-8FA9-B8E7668AC731}.Release|x86.Build.0 = Release|x86
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
|
|
|
@ -67,7 +67,7 @@ namespace CodeImp.DoomBuilder.Windows
|
|||
// Update the used textures
|
||||
General.Map.Data.UpdateUsedTextures();
|
||||
|
||||
tvTextureSets.SuspendLayout();//mxd
|
||||
tvTextureSets.BeginUpdate();//mxd
|
||||
|
||||
//mxd. Set title
|
||||
this.Text = "Browse " + (browseFlats ? "flats" : "textures");
|
||||
|
@ -90,8 +90,17 @@ namespace CodeImp.DoomBuilder.Windows
|
|||
item.ImageIndex = 2 + ts.Location.type;
|
||||
item.SelectedImageIndex = item.ImageIndex;
|
||||
|
||||
if (ts.Location.type != DataLocation.RESOURCE_WAD)
|
||||
if (ts.Location.type != DataLocation.RESOURCE_WAD) {
|
||||
createNodes(item);
|
||||
|
||||
/*if (item.Nodes.Count > 1) { //sort them
|
||||
TreeNode[] children = new TreeNode[item.Nodes.Count];
|
||||
item.Nodes.CopyTo(children, 0);
|
||||
Array.Sort(children, sortTreeNodes);
|
||||
item.Nodes.Clear();
|
||||
item.Nodes.AddRange(children);
|
||||
}*/
|
||||
}
|
||||
}
|
||||
|
||||
//mxd. Add All textures set
|
||||
|
@ -129,6 +138,7 @@ namespace CodeImp.DoomBuilder.Windows
|
|||
selectedset = match;
|
||||
|
||||
tvTextureSets.ExpandAll();//mxd
|
||||
tvTextureSets.EndUpdate();//mxd
|
||||
|
||||
if (selectedset != null) {//mxd
|
||||
tvTextureSets.SelectedNode = selectedset;
|
||||
|
@ -154,6 +164,11 @@ namespace CodeImp.DoomBuilder.Windows
|
|||
this.ResumeLayout(true);
|
||||
}
|
||||
|
||||
//mxd
|
||||
private int sortImageData(ImageData img1, ImageData img2) {
|
||||
return img1.FullName.CompareTo(img2.FullName);
|
||||
}
|
||||
|
||||
//mxd
|
||||
private TreeNode findTextureByLongName(TreeNode node, long longname) {
|
||||
//first search in child nodes
|
||||
|
@ -202,8 +217,12 @@ namespace CodeImp.DoomBuilder.Windows
|
|||
|
||||
int imageIndex = set.Location.type + 4;
|
||||
string[] separator = new string[]{ Path.DirectorySeparatorChar.ToString() };
|
||||
|
||||
ImageData[] textures = new ImageData[set.Textures.Count];
|
||||
set.Textures.CopyTo(textures, 0);
|
||||
Array.Sort(textures, sortImageData);
|
||||
|
||||
foreach (ImageData image in set.Textures) {
|
||||
foreach (ImageData image in textures) {
|
||||
string localName = image.FullName.Replace(set.Location.location, "");
|
||||
string[] parts = localName.Split(separator, StringSplitOptions.RemoveEmptyEntries);
|
||||
TreeNode curNode = root;
|
||||
|
|
|
@ -5,6 +5,7 @@ using System.Drawing;
|
|||
using System.Data;
|
||||
using System.Text;
|
||||
using System.Windows.Forms;
|
||||
using System.Globalization;
|
||||
|
||||
namespace CodeImp.DoomBuilder.ColorPicker.Controls {
|
||||
public partial class ColorPickerControl : UserControl {
|
||||
|
@ -14,6 +15,13 @@ namespace CodeImp.DoomBuilder.ColorPicker.Controls {
|
|||
RGB,
|
||||
None
|
||||
}
|
||||
|
||||
private const string COLOR_INFO_RGB = "RGB";
|
||||
private const string COLOR_INFO_HEX = "Hex";
|
||||
private const string COLOR_INFO_FLOAT = "Float";
|
||||
private readonly object[] COLOR_INFO = new object[] { COLOR_INFO_RGB, COLOR_INFO_HEX, COLOR_INFO_FLOAT };
|
||||
|
||||
private static int colorInfoMode;
|
||||
|
||||
private ChangeStyle changeType = ChangeStyle.None;
|
||||
private Point selectedPoint;
|
||||
|
@ -40,6 +48,9 @@ namespace CodeImp.DoomBuilder.ColorPicker.Controls {
|
|||
isInUpdate = true;
|
||||
InitializeComponent();
|
||||
isInUpdate = false;
|
||||
|
||||
cbColorInfo.Items.AddRange(COLOR_INFO);
|
||||
cbColorInfo.SelectedIndex = colorInfoMode;
|
||||
}
|
||||
|
||||
private void nudValueChanged(object sender, System.EventArgs e) {
|
||||
|
@ -49,7 +60,7 @@ namespace CodeImp.DoomBuilder.ColorPicker.Controls {
|
|||
if (!isInUpdate) {
|
||||
changeType = ChangeStyle.RGB;
|
||||
RGB = new ColorHandler.RGB((int)nudRed.Value, (int)nudGreen.Value, (int)nudBlue.Value);
|
||||
updateOKButton(RGB);
|
||||
updateColorInfo(RGB);
|
||||
this.Invalidate();
|
||||
}
|
||||
}
|
||||
|
@ -58,20 +69,49 @@ namespace CodeImp.DoomBuilder.ColorPicker.Controls {
|
|||
// Update the RGB values on the form, but don't trigger the ValueChanged event of the form. The isInUpdate
|
||||
// variable ensures that the event procedures exit without doing anything.
|
||||
isInUpdate = true;
|
||||
refreshNudValue(nudRed, RGB.Red);
|
||||
refreshNudValue(nudBlue, RGB.Blue);
|
||||
refreshNudValue(nudGreen, RGB.Green);
|
||||
updateOKButton(RGB);
|
||||
updateColorInfo(RGB);
|
||||
isInUpdate = false;
|
||||
}
|
||||
|
||||
private void updateOKButton(ColorHandler.RGB RGB) {
|
||||
private void updateColorInfo(ColorHandler.RGB RGB) {
|
||||
this.RGB = RGB;
|
||||
btnOK.BackColor = ColorHandler.RGBtoColor(RGB);
|
||||
btnOK.ForeColor = (RGB.Red < 180 && RGB.Green < 180) ? Color.White : Color.Black;
|
||||
|
||||
//update float vals
|
||||
tbFloatVals.Text = (float)Math.Round((float)RGB.Red / 255f, 2) + " " + (float)Math.Round((float)RGB.Green / 255f, 2) + " " + (float)Math.Round((float)RGB.Blue / 255f, 2);
|
||||
//update color info
|
||||
switch (cbColorInfo.SelectedItem.ToString()) {
|
||||
case COLOR_INFO_RGB:
|
||||
refreshNudValue(nudRed, RGB.Red);
|
||||
refreshNudValue(nudBlue, RGB.Blue);
|
||||
refreshNudValue(nudGreen, RGB.Green);
|
||||
break;
|
||||
|
||||
case COLOR_INFO_HEX:
|
||||
string r = RGB.Red.ToString("X");
|
||||
if (r.Length == 1) r = "0" + r;
|
||||
string g = RGB.Green.ToString("X");
|
||||
if (g.Length == 1) r = "0" + g;
|
||||
string b = RGB.Blue.ToString("X");
|
||||
if (b.Length == 1) r = "0" + b;
|
||||
|
||||
isInUpdate = true;
|
||||
tbFloatVals.Text = r + g + b;
|
||||
isInUpdate = false;
|
||||
break;
|
||||
|
||||
case COLOR_INFO_FLOAT:
|
||||
string r2 = ((float)Math.Round((float)RGB.Red / 255f, 2)).ToString();
|
||||
if (r2.Length == 1) r2 += ".0";
|
||||
string g2 = ((float)Math.Round((float)RGB.Green / 255f, 2)).ToString();
|
||||
if (g2.Length == 1) g2 += ".0";
|
||||
string b2 = ((float)Math.Round((float)RGB.Blue / 255f, 2)).ToString();
|
||||
if (b2.Length == 1) b2 += ".0";
|
||||
|
||||
isInUpdate = true;
|
||||
tbFloatVals.Text = r2 + " " + g2 + " " + b2;
|
||||
isInUpdate = false;
|
||||
break;
|
||||
}
|
||||
|
||||
//dispatch event further
|
||||
EventHandler<ColorChangedEventArgs> handler = ColorChanged;
|
||||
|
@ -98,10 +138,7 @@ namespace CodeImp.DoomBuilder.ColorPicker.Controls {
|
|||
changeType = ChangeStyle.RGB;
|
||||
RGB = new ColorHandler.RGB(c.R, c.G, c.B);
|
||||
|
||||
refreshNudValue(nudRed, RGB.Red);
|
||||
refreshNudValue(nudBlue, RGB.Blue);
|
||||
refreshNudValue(nudGreen, RGB.Green);
|
||||
updateOKButton(RGB);
|
||||
updateColorInfo(RGB);
|
||||
isInUpdate = false;
|
||||
this.Invalidate();
|
||||
}
|
||||
|
@ -187,8 +224,63 @@ namespace CodeImp.DoomBuilder.ColorPicker.Controls {
|
|||
handler(this, e);
|
||||
}
|
||||
|
||||
private void tbFloatVals_Click(object sender, EventArgs e) {
|
||||
tbFloatVals.Select(0, tbFloatVals.Text.Length);
|
||||
}
|
||||
private void cbColorInfo_SelectedIndexChanged(object sender, EventArgs e) {
|
||||
if (cbColorInfo.SelectedItem.ToString() == COLOR_INFO_RGB) {
|
||||
pRGB.Visible = true;
|
||||
tbFloatVals.Visible = false;
|
||||
} else {
|
||||
pRGB.Visible = false;
|
||||
tbFloatVals.Visible = true;
|
||||
}
|
||||
colorInfoMode = cbColorInfo.SelectedIndex;
|
||||
updateColorInfo(RGB);
|
||||
}
|
||||
|
||||
private void tbFloatVals_TextChanged(object sender, EventArgs e) {
|
||||
if (isInUpdate) return;
|
||||
|
||||
if (COLOR_INFO[colorInfoMode].ToString() == COLOR_INFO_FLOAT) {
|
||||
string[] parts = tbFloatVals.Text.Split(new char[] { ' ' }, StringSplitOptions.RemoveEmptyEntries);
|
||||
if (parts.Length != 3) return;
|
||||
|
||||
ColorHandler.RGB rgb = new ColorHandler.RGB();
|
||||
|
||||
float c;
|
||||
if (!float.TryParse(parts[0].Trim(), NumberStyles.Float, CultureInfo.InvariantCulture, out c)) return;
|
||||
rgb.Red = (int)(c * 255);
|
||||
|
||||
if (!float.TryParse(parts[1].Trim(), NumberStyles.Float, CultureInfo.InvariantCulture, out c)) return;
|
||||
rgb.Green = (int)(c * 255);
|
||||
|
||||
if (!float.TryParse(parts[2].Trim(), NumberStyles.Float, CultureInfo.InvariantCulture, out c)) return;
|
||||
rgb.Blue = (int)(c * 255);
|
||||
|
||||
changeType = ChangeStyle.RGB;
|
||||
updateColorInfo(rgb);
|
||||
this.Invalidate();
|
||||
} else if (COLOR_INFO[colorInfoMode].ToString() == COLOR_INFO_HEX) {
|
||||
string hexColor = tbFloatVals.Text;
|
||||
if (hexColor.Length != 6) return;
|
||||
|
||||
ColorHandler.RGB rgb = new ColorHandler.RGB();
|
||||
int color;
|
||||
|
||||
string colorStr = hexColor.Substring(0, 2);
|
||||
if (!int.TryParse(colorStr, NumberStyles.HexNumber, CultureInfo.InvariantCulture, out color)) return;
|
||||
rgb.Red = color;
|
||||
|
||||
colorStr = hexColor.Substring(2, 2);
|
||||
if (!int.TryParse(colorStr, NumberStyles.HexNumber, CultureInfo.InvariantCulture, out color)) return;
|
||||
rgb.Green = color;
|
||||
|
||||
colorStr = hexColor.Substring(4, 2);
|
||||
if (!int.TryParse(colorStr, NumberStyles.HexNumber, CultureInfo.InvariantCulture, out color)) return;
|
||||
rgb.Blue = color;
|
||||
|
||||
changeType = ChangeStyle.RGB;
|
||||
updateColorInfo(rgb);
|
||||
this.Invalidate();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -23,175 +23,197 @@
|
|||
/// содержимое данного метода при помощи редактора кода.
|
||||
/// </summary>
|
||||
private void InitializeComponent() {
|
||||
this.btnCancel = new System.Windows.Forms.Button();
|
||||
this.btnOK = new System.Windows.Forms.Button();
|
||||
this.Label3 = new System.Windows.Forms.Label();
|
||||
this.nudRed = new System.Windows.Forms.NumericUpDown();
|
||||
this.pnlColor = new System.Windows.Forms.Panel();
|
||||
this.Label1 = new System.Windows.Forms.Label();
|
||||
this.pnlBrightness = new System.Windows.Forms.Panel();
|
||||
this.nudBlue = new System.Windows.Forms.NumericUpDown();
|
||||
this.nudGreen = new System.Windows.Forms.NumericUpDown();
|
||||
this.Label2 = new System.Windows.Forms.Label();
|
||||
this.tbFloatVals = new System.Windows.Forms.TextBox();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nudRed)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nudBlue)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nudGreen)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// btnCancel
|
||||
//
|
||||
this.btnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.btnCancel.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
|
||||
this.btnCancel.Font = new System.Drawing.Font("Arial", 10F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.btnCancel.Location = new System.Drawing.Point(214, 44);
|
||||
this.btnCancel.Name = "btnCancel";
|
||||
this.btnCancel.Size = new System.Drawing.Size(94, 42);
|
||||
this.btnCancel.TabIndex = 54;
|
||||
this.btnCancel.Text = "Cancel";
|
||||
this.btnCancel.Click += new System.EventHandler(this.btnCancel_Click);
|
||||
//
|
||||
// btnOK
|
||||
//
|
||||
this.btnOK.BackColor = System.Drawing.SystemColors.Control;
|
||||
this.btnOK.DialogResult = System.Windows.Forms.DialogResult.OK;
|
||||
this.btnOK.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
|
||||
this.btnOK.Font = new System.Drawing.Font("Arial", 10F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.btnOK.ForeColor = System.Drawing.SystemColors.ControlText;
|
||||
this.btnOK.Location = new System.Drawing.Point(214, 3);
|
||||
this.btnOK.Name = "btnOK";
|
||||
this.btnOK.Size = new System.Drawing.Size(94, 42);
|
||||
this.btnOK.TabIndex = 53;
|
||||
this.btnOK.Text = "OK";
|
||||
this.btnOK.UseVisualStyleBackColor = true;
|
||||
this.btnOK.Click += new System.EventHandler(this.btnOK_Click);
|
||||
//
|
||||
// Label3
|
||||
//
|
||||
this.Label3.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.Label3.Location = new System.Drawing.Point(214, 133);
|
||||
this.Label3.Name = "Label3";
|
||||
this.Label3.Size = new System.Drawing.Size(40, 23);
|
||||
this.Label3.TabIndex = 60;
|
||||
this.Label3.Text = "Blue:";
|
||||
this.Label3.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
|
||||
//
|
||||
// nudRed
|
||||
//
|
||||
this.nudRed.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.nudRed.Location = new System.Drawing.Point(260, 89);
|
||||
this.nudRed.Maximum = new decimal(new int[] {
|
||||
this.btnCancel = new System.Windows.Forms.Button();
|
||||
this.btnOK = new System.Windows.Forms.Button();
|
||||
this.Label3 = new System.Windows.Forms.Label();
|
||||
this.nudRed = new System.Windows.Forms.NumericUpDown();
|
||||
this.pnlColor = new System.Windows.Forms.Panel();
|
||||
this.Label1 = new System.Windows.Forms.Label();
|
||||
this.pnlBrightness = new System.Windows.Forms.Panel();
|
||||
this.nudBlue = new System.Windows.Forms.NumericUpDown();
|
||||
this.nudGreen = new System.Windows.Forms.NumericUpDown();
|
||||
this.Label2 = new System.Windows.Forms.Label();
|
||||
this.tbFloatVals = new System.Windows.Forms.TextBox();
|
||||
this.pRGB = new System.Windows.Forms.Panel();
|
||||
this.cbColorInfo = new System.Windows.Forms.ComboBox();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nudRed)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nudBlue)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nudGreen)).BeginInit();
|
||||
this.pRGB.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// btnCancel
|
||||
//
|
||||
this.btnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.btnCancel.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
|
||||
this.btnCancel.Font = new System.Drawing.Font("Arial", 10F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.btnCancel.Location = new System.Drawing.Point(214, 44);
|
||||
this.btnCancel.Name = "btnCancel";
|
||||
this.btnCancel.Size = new System.Drawing.Size(94, 42);
|
||||
this.btnCancel.TabIndex = 54;
|
||||
this.btnCancel.Text = "Cancel";
|
||||
this.btnCancel.Click += new System.EventHandler(this.btnCancel_Click);
|
||||
//
|
||||
// btnOK
|
||||
//
|
||||
this.btnOK.BackColor = System.Drawing.SystemColors.Control;
|
||||
this.btnOK.DialogResult = System.Windows.Forms.DialogResult.OK;
|
||||
this.btnOK.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
|
||||
this.btnOK.Font = new System.Drawing.Font("Arial", 10F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.btnOK.ForeColor = System.Drawing.SystemColors.ControlText;
|
||||
this.btnOK.Location = new System.Drawing.Point(214, 3);
|
||||
this.btnOK.Name = "btnOK";
|
||||
this.btnOK.Size = new System.Drawing.Size(94, 42);
|
||||
this.btnOK.TabIndex = 53;
|
||||
this.btnOK.Text = "OK";
|
||||
this.btnOK.UseVisualStyleBackColor = true;
|
||||
this.btnOK.Click += new System.EventHandler(this.btnOK_Click);
|
||||
//
|
||||
// Label3
|
||||
//
|
||||
this.Label3.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.Label3.Location = new System.Drawing.Point(3, 48);
|
||||
this.Label3.Name = "Label3";
|
||||
this.Label3.Size = new System.Drawing.Size(40, 23);
|
||||
this.Label3.TabIndex = 60;
|
||||
this.Label3.Text = "Blue:";
|
||||
this.Label3.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
|
||||
//
|
||||
// nudRed
|
||||
//
|
||||
this.nudRed.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.nudRed.Location = new System.Drawing.Point(49, 4);
|
||||
this.nudRed.Maximum = new decimal(new int[] {
|
||||
255,
|
||||
0,
|
||||
0,
|
||||
0});
|
||||
this.nudRed.Name = "nudRed";
|
||||
this.nudRed.Size = new System.Drawing.Size(48, 20);
|
||||
this.nudRed.TabIndex = 55;
|
||||
this.nudRed.ValueChanged += new System.EventHandler(this.nudValueChanged);
|
||||
//
|
||||
// pnlColor
|
||||
//
|
||||
this.pnlColor.Location = new System.Drawing.Point(3, 3);
|
||||
this.pnlColor.Name = "pnlColor";
|
||||
this.pnlColor.Size = new System.Drawing.Size(176, 176);
|
||||
this.pnlColor.TabIndex = 61;
|
||||
this.pnlColor.Visible = false;
|
||||
//
|
||||
// Label1
|
||||
//
|
||||
this.Label1.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.Label1.Location = new System.Drawing.Point(214, 87);
|
||||
this.Label1.Name = "Label1";
|
||||
this.Label1.Size = new System.Drawing.Size(40, 23);
|
||||
this.Label1.TabIndex = 58;
|
||||
this.Label1.Text = "Red:";
|
||||
this.Label1.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
|
||||
//
|
||||
// pnlBrightness
|
||||
//
|
||||
this.pnlBrightness.Location = new System.Drawing.Point(185, 3);
|
||||
this.pnlBrightness.Name = "pnlBrightness";
|
||||
this.pnlBrightness.Size = new System.Drawing.Size(16, 176);
|
||||
this.pnlBrightness.TabIndex = 62;
|
||||
this.pnlBrightness.Visible = false;
|
||||
//
|
||||
// nudBlue
|
||||
//
|
||||
this.nudBlue.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.nudBlue.Location = new System.Drawing.Point(260, 135);
|
||||
this.nudBlue.Maximum = new decimal(new int[] {
|
||||
this.nudRed.Name = "nudRed";
|
||||
this.nudRed.Size = new System.Drawing.Size(48, 20);
|
||||
this.nudRed.TabIndex = 55;
|
||||
this.nudRed.ValueChanged += new System.EventHandler(this.nudValueChanged);
|
||||
//
|
||||
// pnlColor
|
||||
//
|
||||
this.pnlColor.Location = new System.Drawing.Point(3, 3);
|
||||
this.pnlColor.Name = "pnlColor";
|
||||
this.pnlColor.Size = new System.Drawing.Size(176, 176);
|
||||
this.pnlColor.TabIndex = 61;
|
||||
this.pnlColor.Visible = false;
|
||||
//
|
||||
// Label1
|
||||
//
|
||||
this.Label1.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.Label1.Location = new System.Drawing.Point(3, 2);
|
||||
this.Label1.Name = "Label1";
|
||||
this.Label1.Size = new System.Drawing.Size(40, 23);
|
||||
this.Label1.TabIndex = 58;
|
||||
this.Label1.Text = "Red:";
|
||||
this.Label1.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
|
||||
//
|
||||
// pnlBrightness
|
||||
//
|
||||
this.pnlBrightness.Location = new System.Drawing.Point(185, 3);
|
||||
this.pnlBrightness.Name = "pnlBrightness";
|
||||
this.pnlBrightness.Size = new System.Drawing.Size(16, 176);
|
||||
this.pnlBrightness.TabIndex = 62;
|
||||
this.pnlBrightness.Visible = false;
|
||||
//
|
||||
// nudBlue
|
||||
//
|
||||
this.nudBlue.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.nudBlue.Location = new System.Drawing.Point(49, 50);
|
||||
this.nudBlue.Maximum = new decimal(new int[] {
|
||||
255,
|
||||
0,
|
||||
0,
|
||||
0});
|
||||
this.nudBlue.Name = "nudBlue";
|
||||
this.nudBlue.Size = new System.Drawing.Size(48, 20);
|
||||
this.nudBlue.TabIndex = 57;
|
||||
this.nudBlue.ValueChanged += new System.EventHandler(this.nudValueChanged);
|
||||
//
|
||||
// nudGreen
|
||||
//
|
||||
this.nudGreen.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.nudGreen.Location = new System.Drawing.Point(260, 112);
|
||||
this.nudGreen.Maximum = new decimal(new int[] {
|
||||
this.nudBlue.Name = "nudBlue";
|
||||
this.nudBlue.Size = new System.Drawing.Size(48, 20);
|
||||
this.nudBlue.TabIndex = 57;
|
||||
this.nudBlue.ValueChanged += new System.EventHandler(this.nudValueChanged);
|
||||
//
|
||||
// nudGreen
|
||||
//
|
||||
this.nudGreen.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.nudGreen.Location = new System.Drawing.Point(49, 27);
|
||||
this.nudGreen.Maximum = new decimal(new int[] {
|
||||
255,
|
||||
0,
|
||||
0,
|
||||
0});
|
||||
this.nudGreen.Name = "nudGreen";
|
||||
this.nudGreen.Size = new System.Drawing.Size(48, 20);
|
||||
this.nudGreen.TabIndex = 56;
|
||||
this.nudGreen.ValueChanged += new System.EventHandler(this.nudValueChanged);
|
||||
//
|
||||
// Label2
|
||||
//
|
||||
this.Label2.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.Label2.Location = new System.Drawing.Point(214, 110);
|
||||
this.Label2.Name = "Label2";
|
||||
this.Label2.Size = new System.Drawing.Size(40, 23);
|
||||
this.Label2.TabIndex = 59;
|
||||
this.Label2.Text = "Green:";
|
||||
this.Label2.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
|
||||
//
|
||||
// tbFloatVals
|
||||
//
|
||||
this.tbFloatVals.Location = new System.Drawing.Point(217, 158);
|
||||
this.tbFloatVals.Name = "tbFloatVals";
|
||||
this.tbFloatVals.ReadOnly = true;
|
||||
this.tbFloatVals.Size = new System.Drawing.Size(90, 20);
|
||||
this.tbFloatVals.TabIndex = 63;
|
||||
this.tbFloatVals.Text = "1.01 0.55 0.33";
|
||||
this.tbFloatVals.Click += new System.EventHandler(this.tbFloatVals_Click);
|
||||
//
|
||||
// ColorPickerControl
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.Controls.Add(this.tbFloatVals);
|
||||
this.Controls.Add(this.btnCancel);
|
||||
this.Controls.Add(this.btnOK);
|
||||
this.Controls.Add(this.Label3);
|
||||
this.Controls.Add(this.nudRed);
|
||||
this.Controls.Add(this.pnlColor);
|
||||
this.Controls.Add(this.Label1);
|
||||
this.Controls.Add(this.pnlBrightness);
|
||||
this.Controls.Add(this.nudBlue);
|
||||
this.Controls.Add(this.nudGreen);
|
||||
this.Controls.Add(this.Label2);
|
||||
this.Name = "ColorPickerControl";
|
||||
this.Size = new System.Drawing.Size(311, 183);
|
||||
this.Load += new System.EventHandler(this.ColorPickerControl_Load);
|
||||
this.MouseLeave += new System.EventHandler(this.onMouseUp);
|
||||
this.Paint += new System.Windows.Forms.PaintEventHandler(this.onPaint);
|
||||
this.MouseMove += new System.Windows.Forms.MouseEventHandler(this.handleMouse);
|
||||
this.MouseDown += new System.Windows.Forms.MouseEventHandler(this.ColorPickerControl_MouseDown);
|
||||
this.MouseUp += new System.Windows.Forms.MouseEventHandler(this.onMouseUp);
|
||||
((System.ComponentModel.ISupportInitialize)(this.nudRed)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nudBlue)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nudGreen)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
this.nudGreen.Name = "nudGreen";
|
||||
this.nudGreen.Size = new System.Drawing.Size(48, 20);
|
||||
this.nudGreen.TabIndex = 56;
|
||||
this.nudGreen.ValueChanged += new System.EventHandler(this.nudValueChanged);
|
||||
//
|
||||
// Label2
|
||||
//
|
||||
this.Label2.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.Label2.Location = new System.Drawing.Point(3, 25);
|
||||
this.Label2.Name = "Label2";
|
||||
this.Label2.Size = new System.Drawing.Size(40, 23);
|
||||
this.Label2.TabIndex = 59;
|
||||
this.Label2.Text = "Green:";
|
||||
this.Label2.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
|
||||
//
|
||||
// tbFloatVals
|
||||
//
|
||||
this.tbFloatVals.Location = new System.Drawing.Point(218, 115);
|
||||
this.tbFloatVals.Name = "tbFloatVals";
|
||||
this.tbFloatVals.Size = new System.Drawing.Size(91, 20);
|
||||
this.tbFloatVals.TabIndex = 63;
|
||||
this.tbFloatVals.Text = "1.01 0.55 0.33";
|
||||
this.tbFloatVals.TextChanged += new System.EventHandler(this.tbFloatVals_TextChanged);
|
||||
//
|
||||
// pRGB
|
||||
//
|
||||
this.pRGB.Controls.Add(this.Label2);
|
||||
this.pRGB.Controls.Add(this.nudGreen);
|
||||
this.pRGB.Controls.Add(this.nudBlue);
|
||||
this.pRGB.Controls.Add(this.Label1);
|
||||
this.pRGB.Controls.Add(this.Label3);
|
||||
this.pRGB.Controls.Add(this.nudRed);
|
||||
this.pRGB.Location = new System.Drawing.Point(212, 111);
|
||||
this.pRGB.Name = "pRGB";
|
||||
this.pRGB.Size = new System.Drawing.Size(104, 76);
|
||||
this.pRGB.TabIndex = 64;
|
||||
//
|
||||
// cbColorInfo
|
||||
//
|
||||
this.cbColorInfo.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||
this.cbColorInfo.FormattingEnabled = true;
|
||||
this.cbColorInfo.Location = new System.Drawing.Point(214, 89);
|
||||
this.cbColorInfo.Name = "cbColorInfo";
|
||||
this.cbColorInfo.Size = new System.Drawing.Size(94, 21);
|
||||
this.cbColorInfo.TabIndex = 65;
|
||||
this.cbColorInfo.SelectedIndexChanged += new System.EventHandler(this.cbColorInfo_SelectedIndexChanged);
|
||||
//
|
||||
// ColorPickerControl
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.Controls.Add(this.cbColorInfo);
|
||||
this.Controls.Add(this.pRGB);
|
||||
this.Controls.Add(this.tbFloatVals);
|
||||
this.Controls.Add(this.btnCancel);
|
||||
this.Controls.Add(this.btnOK);
|
||||
this.Controls.Add(this.pnlColor);
|
||||
this.Controls.Add(this.pnlBrightness);
|
||||
this.Name = "ColorPickerControl";
|
||||
this.Size = new System.Drawing.Size(311, 183);
|
||||
this.Load += new System.EventHandler(this.ColorPickerControl_Load);
|
||||
this.MouseLeave += new System.EventHandler(this.onMouseUp);
|
||||
this.Paint += new System.Windows.Forms.PaintEventHandler(this.onPaint);
|
||||
this.MouseMove += new System.Windows.Forms.MouseEventHandler(this.handleMouse);
|
||||
this.MouseDown += new System.Windows.Forms.MouseEventHandler(this.ColorPickerControl_MouseDown);
|
||||
this.MouseUp += new System.Windows.Forms.MouseEventHandler(this.onMouseUp);
|
||||
((System.ComponentModel.ISupportInitialize)(this.nudRed)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nudBlue)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nudGreen)).EndInit();
|
||||
this.pRGB.ResumeLayout(false);
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
|
@ -208,5 +230,7 @@
|
|||
internal System.Windows.Forms.NumericUpDown nudGreen;
|
||||
internal System.Windows.Forms.Label Label2;
|
||||
private System.Windows.Forms.TextBox tbFloatVals;
|
||||
private System.Windows.Forms.Panel pRGB;
|
||||
private System.Windows.Forms.ComboBox cbColorInfo;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -19,7 +19,7 @@ namespace CodeImp.DoomBuilder.TagExplorer
|
|||
private const string DISPLAY_TAGS_AND_ACTIONS = "Tags and Action specials";
|
||||
private const string DISPLAY_TAGS = "Tags";
|
||||
private const string DISPLAY_ACTIONS = "Action specials";
|
||||
private object[] DISPLAY_MODES = new object[] { DISPLAY_TAGS_AND_ACTIONS, DISPLAY_TAGS, DISPLAY_ACTIONS };
|
||||
private readonly object[] DISPLAY_MODES = new object[] { DISPLAY_TAGS_AND_ACTIONS, DISPLAY_TAGS, DISPLAY_ACTIONS };
|
||||
|
||||
private string currentDisplayMode;
|
||||
private string currentSortMode;
|
||||
|
|
Loading…
Reference in a new issue