diff --git a/Commands/Commands.csproj b/Commands/Commands.csproj
index dc3b0bf..4e736f8 100644
--- a/Commands/Commands.csproj
+++ b/Commands/Commands.csproj
@@ -36,12 +36,6 @@
..\ThirdParty\OpenTK\OpenTK.dll
-
-
-
-
-
-
diff --git a/Commands/ICommand.cs b/Commands/ICommand.cs
index 220094d..4918da8 100644
--- a/Commands/ICommand.cs
+++ b/Commands/ICommand.cs
@@ -1,8 +1,4 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-
+
namespace Commands
{
public abstract class ICommand
diff --git a/Commands/MoveTool.cs b/Commands/MoveTool.cs
index 1fa1623..98b2775 100644
--- a/Commands/MoveTool.cs
+++ b/Commands/MoveTool.cs
@@ -1,8 +1,4 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using OpenTK;
+using OpenTK;
namespace Commands
{
diff --git a/GUI/COMPortForm.cs b/GUI/COMPortForm.cs
index f163985..b289846 100644
--- a/GUI/COMPortForm.cs
+++ b/GUI/COMPortForm.cs
@@ -107,11 +107,11 @@ private void connect_Click(object sender, EventArgs e)
port.Open(portName, baudRate);
connect.Text = "Disconnect";
}
- catch (NullReferenceException ex)
+ catch (NullReferenceException)
{
MessageBox.Show("Error Opening Com Port: No Port Name Selected!");
}
- catch (FormatException ex)
+ catch (FormatException)
{
MessageBox.Show("Error Opening Com Port: Invalid Baud Rate!");
}
diff --git a/GUI/Drawing3D.Designer.cs b/GUI/Drawing3D.Designer.cs
index 856e6af..147b1f4 100644
--- a/GUI/Drawing3D.Designer.cs
+++ b/GUI/Drawing3D.Designer.cs
@@ -30,11 +30,11 @@ private void InitializeComponent()
{
this.SuspendLayout();
//
- // UserControl1
+ // Drawing3D
//
- this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.Name = "UserControl1";
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Inherit;
+ this.Name = "Drawing3D";
+ this.Size = new System.Drawing.Size(159, 121);
this.Load += new System.EventHandler(this.UserControl1_Load);
this.ResumeLayout(false);
diff --git a/GUI/Drawing3D.resx b/GUI/Drawing3D.resx
index 1af7de1..7080a7d 100644
--- a/GUI/Drawing3D.resx
+++ b/GUI/Drawing3D.resx
@@ -112,9 +112,9 @@
2.0
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
\ No newline at end of file
diff --git a/GUI/GUI.csproj b/GUI/GUI.csproj
index c703b49..1afef94 100644
--- a/GUI/GUI.csproj
+++ b/GUI/GUI.csproj
@@ -64,7 +64,6 @@
-
diff --git a/GUI/PathCAM.cs b/GUI/PathCAM.cs
index 6000cbe..720d922 100644
--- a/GUI/PathCAM.cs
+++ b/GUI/PathCAM.cs
@@ -159,7 +159,7 @@ void IOpenGLDrawable.Draw()
mesh.Draw();
}
}
- catch (Exception ex)
+ catch (Exception)
{
}
}
@@ -282,7 +282,7 @@ private void InitializeComponent()
this.boundaryCheck = new System.Windows.Forms.Button();
this.comboBox1 = new System.Windows.Forms.ComboBox();
this.openFileButton = new System.Windows.Forms.Button();
- this.checkBox1 = new System.Windows.Forms.CheckBox();
+ this.showRobotFormCheckbox = new System.Windows.Forms.CheckBox();
this.pictureBox1 = new System.Windows.Forms.PictureBox();
this.robotControl = new GUI.RobotControl();
this.drawing3D = new GUI.Drawing3D();
@@ -371,16 +371,16 @@ private void InitializeComponent()
this.openFileButton.UseVisualStyleBackColor = true;
this.openFileButton.Click += new System.EventHandler(this.loadButton_Click);
//
- // checkBox1
+ // showRobotFormCheckbox
//
- this.checkBox1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
- this.checkBox1.AutoSize = true;
- this.checkBox1.Location = new System.Drawing.Point(0, 588);
- this.checkBox1.Name = "checkBox1";
- this.checkBox1.Size = new System.Drawing.Size(15, 14);
- this.checkBox1.TabIndex = 69;
- this.checkBox1.UseVisualStyleBackColor = true;
- this.checkBox1.CheckedChanged += new System.EventHandler(this.checkBox1_CheckedChanged);
+ this.showRobotFormCheckbox.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
+ this.showRobotFormCheckbox.AutoSize = true;
+ this.showRobotFormCheckbox.Location = new System.Drawing.Point(-1, 449);
+ this.showRobotFormCheckbox.Name = "showRobotFormCheckbox";
+ this.showRobotFormCheckbox.Size = new System.Drawing.Size(15, 14);
+ this.showRobotFormCheckbox.TabIndex = 69;
+ this.showRobotFormCheckbox.UseVisualStyleBackColor = true;
+ this.showRobotFormCheckbox.CheckedChanged += new System.EventHandler(this.checkBox1_CheckedChanged);
//
// pictureBox1
//
@@ -395,9 +395,9 @@ private void InitializeComponent()
//
this.robotControl.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.robotControl.BackColor = System.Drawing.Color.Transparent;
- this.robotControl.Location = new System.Drawing.Point(0, 466);
+ this.robotControl.Location = new System.Drawing.Point(-1, 327);
this.robotControl.Name = "robotControl";
- this.robotControl.Size = new System.Drawing.Size(183, 136);
+ this.robotControl.Size = new System.Drawing.Size(169, 136);
this.robotControl.TabIndex = 8;
this.robotControl.Visible = false;
//
@@ -407,13 +407,14 @@ private void InitializeComponent()
this.drawing3D.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
+ this.drawing3D.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
this.drawing3D.BackColor = System.Drawing.Color.Black;
this.drawing3D.ClearColor = System.Drawing.Color.Empty;
- this.drawing3D.Location = new System.Drawing.Point(0, -1);
+ this.drawing3D.Location = new System.Drawing.Point(472, 12);
this.drawing3D.MinimumSize = new System.Drawing.Size(10, 10);
this.drawing3D.Name = "drawing3D";
this.drawing3D.RightToLeft = System.Windows.Forms.RightToLeft.Yes;
- this.drawing3D.Size = new System.Drawing.Size(986, 603);
+ this.drawing3D.Size = new System.Drawing.Size(100, 98);
this.drawing3D.TabIndex = 68;
this.drawing3D.VSync = false;
//
@@ -421,8 +422,8 @@ private void InitializeComponent()
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(986, 601);
- this.Controls.Add(this.checkBox1);
+ this.ClientSize = new System.Drawing.Size(584, 462);
+ this.Controls.Add(this.showRobotFormCheckbox);
this.Controls.Add(this.saveGcodeButton);
this.Controls.Add(this.button2);
this.Controls.Add(this.clearPathsButton);
@@ -434,9 +435,10 @@ private void InitializeComponent()
this.Controls.Add(this.pictureBox1);
this.Controls.Add(this.drawing3D);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
- this.MinimumSize = new System.Drawing.Size(800, 600);
+ this.MinimumSize = new System.Drawing.Size(600, 500);
this.Name = "PathCAM";
this.Text = "PathCAM - Toolpath generation software for CNC robots";
+ this.Load += new System.EventHandler(this.PathCAM_Load);
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
this.ResumeLayout(false);
this.PerformLayout();
@@ -460,7 +462,23 @@ private void saveGcodeButton_Click(object sender, EventArgs e)
private void checkBox1_CheckedChanged(object sender, EventArgs e)
{
- robotControl.Visible = checkBox1.Checked;
+ robotControl.Visible = showRobotFormCheckbox.Checked;
+ }
+
+ private void drawing3D_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ private void PathCAM_Load(object sender, EventArgs e)
+ {
+ // Programatically fill the entire client rectangle with the drawing area.
+ // This makes sure the size is independent of window border and makes
+ // editing the GUI in the designer much easier.
+ this.drawing3D.Location = new Point(0, 0);
+ this.drawing3D.Size = this.ClientRectangle.Size;
+ robotControl.Location = new Point(0, ClientRectangle.Height - robotControl.Height);
+ showRobotFormCheckbox.Location = new Point(0, ClientRectangle.Height - showRobotFormCheckbox.Height + 1);
}
}
}
diff --git a/GUI/PathCAM.resx b/GUI/PathCAM.resx
index 35790c0..7a9b7e8 100644
--- a/GUI/PathCAM.resx
+++ b/GUI/PathCAM.resx
@@ -112,12 +112,12 @@
2.0
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
+
AAABAAEAICAAAAAAIACoEAAAFgAAACgAAAAgAAAAQAAAAAEAIAAAAAAAACAAAAAAAAAAAAAAAAAAAAAA
diff --git a/GUI/RobotControl.Designer.cs b/GUI/RobotControl.Designer.cs
index 63dded5..85d341d 100644
--- a/GUI/RobotControl.Designer.cs
+++ b/GUI/RobotControl.Designer.cs
@@ -131,8 +131,7 @@ private void InitializeComponent()
//
// RobotControl
//
- this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Inherit;
this.Controls.Add(this.label1);
this.Controls.Add(this.button4);
this.Controls.Add(this.runButton);
diff --git a/GUI/RobotControl.resx b/GUI/RobotControl.resx
index 1af7de1..7080a7d 100644
--- a/GUI/RobotControl.resx
+++ b/GUI/RobotControl.resx
@@ -112,9 +112,9 @@
2.0
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
\ No newline at end of file
diff --git a/GUI/RouterGUI.cs b/GUI/RouterGUI.cs
index 0216691..c96aaed 100644
--- a/GUI/RouterGUI.cs
+++ b/GUI/RouterGUI.cs
@@ -125,7 +125,7 @@ void IOpenGLDrawable.Draw()
GL.PointSize(1);
GL.Enable(EnableCap.Lighting);
}
- catch (Exception ex)
+ catch (Exception)
{
}
}
diff --git a/GUI/RouterUI.Designer.cs b/GUI/RouterUI.Designer.cs
index c7bee15..a84d5ec 100644
--- a/GUI/RouterUI.Designer.cs
+++ b/GUI/RouterUI.Designer.cs
@@ -17,7 +17,7 @@ partial class PathCAM
private System.Windows.Forms.Button clearPathsButton;
private System.Windows.Forms.ComboBox comboBox1;
private System.Windows.Forms.Button saveGcodeButton;
- private System.Windows.Forms.CheckBox checkBox1;
+ private System.Windows.Forms.CheckBox showRobotFormCheckbox;
private System.Windows.Forms.PictureBox pictureBox1;
}
diff --git a/GUI/TriangleMeshGUI.cs b/GUI/TriangleMeshGUI.cs
index e574b08..f78f39f 100644
--- a/GUI/TriangleMeshGUI.cs
+++ b/GUI/TriangleMeshGUI.cs
@@ -77,7 +77,7 @@ public void GenerateTabPaths(float toolRadius)
tabs.Add(new TabsGUI(line, toolRadius, true));
}
}
- catch (Exception ex)
+ catch (Exception)
{
}
this.Offset = offset; // Force the offset update in the tabs
diff --git a/Serial/Serial.csproj b/Serial/Serial.csproj
index 225d925..965ba64 100644
--- a/Serial/Serial.csproj
+++ b/Serial/Serial.csproj
@@ -35,7 +35,6 @@
-
diff --git a/Serial/SerialPacket.cs b/Serial/SerialPacket.cs
index c3d2b2f..6630d23 100644
--- a/Serial/SerialPacket.cs
+++ b/Serial/SerialPacket.cs
@@ -162,7 +162,6 @@ public void SerialByteTransmitComplete()
TransmitPacketComplete();
}
return;
- break;
default:
// Shouldn't ever get here.
diff --git a/Serial/SerialPortWrapper.cs b/Serial/SerialPortWrapper.cs
index 0324122..4295475 100644
--- a/Serial/SerialPortWrapper.cs
+++ b/Serial/SerialPortWrapper.cs
@@ -173,7 +173,7 @@ void port_DataReceived(object sender, SerialDataReceivedEventArgs e)
packet.ProcessDataChar(data);
}
}
- catch (Exception ex)
+ catch (Exception)
{
}
}