Additional Mono rendering fixes

- on initial rendering mono likes to send a resize event where the width
is 0, ignore it.  This was causing gbDatInfo to not render until a
manual resize was done.

- set AutoScaleMode to System.Windows.Forms.AutoScaleMode.None.  This
fixes a number of rendering issues under mono and didnt seem to have any
negative effect under c#/windows builds.

- tweak some of the initial form sizes and locations on FrmMain.  A
number of the setting didnt make sense based on the size of the panel
they were put it.  This resolves an issue with the gbDatInfo and
gbSetInfo starting off with the wrong size under mono.
This commit is contained in:
Jim Westfall
2014-11-01 17:05:14 -07:00
parent 0801ddc7f0
commit 76c4af0ec3
12 changed files with 24 additions and 18 deletions

View File

@@ -70,7 +70,7 @@
// FrmHelpAbout
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.BackgroundImage = global::ROMVault2.rvImages.romvaultTZ;
this.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
this.ClientSize = new System.Drawing.Size(471, 172);

View File

@@ -34,7 +34,7 @@
// FrmKey
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.BackColor = System.Drawing.SystemColors.ControlDark;
this.ClientSize = new System.Drawing.Size(600, 532);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWindow;

View File

@@ -286,7 +286,7 @@
this.gbDatInfo.Controls.Add(this.label8);
this.gbDatInfo.Location = new System.Drawing.Point(5, 0);
this.gbDatInfo.Name = "gbDatInfo";
this.gbDatInfo.Size = new System.Drawing.Size(440, 147);
this.gbDatInfo.Size = new System.Drawing.Size(468, 147);
this.gbDatInfo.TabIndex = 3;
this.gbDatInfo.TabStop = false;
this.gbDatInfo.Text = "Dat Info :";
@@ -517,7 +517,7 @@
//
// btnColorKey
//
this.btnColorKey.Location = new System.Drawing.Point(568, 85);
this.btnColorKey.Location = new System.Drawing.Point(547, 85);
this.btnColorKey.Name = "btnColorKey";
this.btnColorKey.Size = new System.Drawing.Size(89, 23);
this.btnColorKey.TabIndex = 9;
@@ -528,7 +528,7 @@
// chkBoxShowMerged
//
this.chkBoxShowMerged.AutoSize = true;
this.chkBoxShowMerged.Location = new System.Drawing.Point(568, 68);
this.chkBoxShowMerged.Location = new System.Drawing.Point(547, 68);
this.chkBoxShowMerged.Name = "chkBoxShowMerged";
this.chkBoxShowMerged.Size = new System.Drawing.Size(125, 17);
this.chkBoxShowMerged.TabIndex = 8;
@@ -541,7 +541,7 @@
this.chkBoxShowFixed.AutoSize = true;
this.chkBoxShowFixed.Checked = true;
this.chkBoxShowFixed.CheckState = System.Windows.Forms.CheckState.Checked;
this.chkBoxShowFixed.Location = new System.Drawing.Point(568, 52);
this.chkBoxShowFixed.Location = new System.Drawing.Point(547, 52);
this.chkBoxShowFixed.Name = "chkBoxShowFixed";
this.chkBoxShowFixed.Size = new System.Drawing.Size(102, 17);
this.chkBoxShowFixed.TabIndex = 7;
@@ -554,7 +554,7 @@
this.chkBoxShowMissing.AutoSize = true;
this.chkBoxShowMissing.Checked = true;
this.chkBoxShowMissing.CheckState = System.Windows.Forms.CheckState.Checked;
this.chkBoxShowMissing.Location = new System.Drawing.Point(568, 36);
this.chkBoxShowMissing.Location = new System.Drawing.Point(547, 36);
this.chkBoxShowMissing.Name = "chkBoxShowMissing";
this.chkBoxShowMissing.Size = new System.Drawing.Size(124, 17);
this.chkBoxShowMissing.TabIndex = 6;
@@ -567,7 +567,7 @@
this.chkBoxShowCorrect.AutoSize = true;
this.chkBoxShowCorrect.Checked = true;
this.chkBoxShowCorrect.CheckState = System.Windows.Forms.CheckState.Checked;
this.chkBoxShowCorrect.Location = new System.Drawing.Point(568, 20);
this.chkBoxShowCorrect.Location = new System.Drawing.Point(547, 20);
this.chkBoxShowCorrect.Name = "chkBoxShowCorrect";
this.chkBoxShowCorrect.Size = new System.Drawing.Size(123, 17);
this.chkBoxShowCorrect.TabIndex = 5;
@@ -579,7 +579,7 @@
//
this.gbSetInfo.Location = new System.Drawing.Point(5, 0);
this.gbSetInfo.Name = "gbSetInfo";
this.gbSetInfo.Size = new System.Drawing.Size(416, 147);
this.gbSetInfo.Size = new System.Drawing.Size(532, 147);
this.gbSetInfo.TabIndex = 4;
this.gbSetInfo.TabStop = false;
this.gbSetInfo.Text = "Game Info :";
@@ -987,7 +987,7 @@
// FrmMain
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.ClientSize = new System.Drawing.Size(1264, 762);
this.Controls.Add(this.splitContainer1);
this.Controls.Add(this.menuStrip1);

View File

@@ -479,6 +479,9 @@ namespace ROMVault2
private void splitContainer3_Panel1_Resize(object sender, EventArgs e)
{
// fixes a rendering issue in mono
if (splitContainer3.Panel1.Width == 0) return;
gbDatInfo.Width = splitContainer3.Panel1.Width - (gbDatInfo.Left * 2);
}
@@ -737,6 +740,9 @@ namespace ROMVault2
private void splitContainer4_Panel1_Resize(object sender, EventArgs e)
{
// fixes a rendering issue in mono
if (splitContainer4.Panel1.Width == 0) return;
int chkLeft = splitContainer4.Panel1.Width - 150;
if (chkLeft < 430) chkLeft = 430;

View File

@@ -185,7 +185,7 @@
// FrmProgressWindow
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.ClientSize = new System.Drawing.Size(591, 320);
this.Controls.Add(this.splitContainer1);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));

View File

@@ -244,7 +244,7 @@
// FrmProgressWindowFix
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.BackColor = System.Drawing.Color.White;
this.ClientSize = new System.Drawing.Size(1027, 500);
this.Controls.Add(this.splitContainer1);

View File

@@ -91,7 +91,7 @@
// FrmRegistration
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.ClientSize = new System.Drawing.Size(444, 178);
this.ControlBox = false;
this.Controls.Add(this.btnOK);

View File

@@ -198,7 +198,7 @@
// FrmSetDir
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.ClientSize = new System.Drawing.Size(694, 391);
this.Controls.Add(this.btnResetAll);
this.Controls.Add(this.btnClose);

View File

@@ -220,7 +220,7 @@
// FrmSettings
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.ClientSize = new System.Drawing.Size(545, 346);
this.Controls.Add(this.chkDoubleCheckDelete);
this.Controls.Add(this.label5);

View File

@@ -65,7 +65,7 @@
// FrmShowError
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.ClientSize = new System.Drawing.Size(589, 583);
this.Controls.Add(this.label1);
this.Controls.Add(this.button1);

View File

@@ -86,7 +86,7 @@
// FrmSplashScreen
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("$this.BackgroundImage")));
this.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
this.ClientSize = new System.Drawing.Size(465, 207);

View File

@@ -33,7 +33,7 @@
// rvTree
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.DoubleBuffered = true;
this.Name = "RvTree";