From 20f7a5d415c255a7c62f791fa75fc3c3442ff1a4 Mon Sep 17 00:00:00 2001 From: Jaex Date: Mon, 28 Oct 2019 15:24:54 +0300 Subject: [PATCH] Make ImageSplitterForm localizable --- .../Forms/ImageSplitterForm.Designer.cs | 63 +--- ShareX.MediaLib/Forms/ImageSplitterForm.resx | 294 ++++++++++++++++++ .../Forms/ApplicationSettingsForm.Designer.cs | 40 +-- ShareX/Forms/ApplicationSettingsForm.resx | 8 +- 4 files changed, 331 insertions(+), 74 deletions(-) diff --git a/ShareX.MediaLib/Forms/ImageSplitterForm.Designer.cs b/ShareX.MediaLib/Forms/ImageSplitterForm.Designer.cs index bf8673469..5f5e5c9c5 100644 --- a/ShareX.MediaLib/Forms/ImageSplitterForm.Designer.cs +++ b/ShareX.MediaLib/Forms/ImageSplitterForm.Designer.cs @@ -28,6 +28,7 @@ protected override void Dispose(bool disposing) /// private void InitializeComponent() { + System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(ImageSplitterForm)); this.lblImageFilePath = new System.Windows.Forms.Label(); this.lblRowCount = new System.Windows.Forms.Label(); this.lblColumnCount = new System.Windows.Forms.Label(); @@ -45,43 +46,28 @@ private void InitializeComponent() // // lblImageFilePath // - this.lblImageFilePath.AutoSize = true; - this.lblImageFilePath.Location = new System.Drawing.Point(13, 16); + resources.ApplyResources(this.lblImageFilePath, "lblImageFilePath"); this.lblImageFilePath.Name = "lblImageFilePath"; - this.lblImageFilePath.Size = new System.Drawing.Size(79, 13); - this.lblImageFilePath.TabIndex = 0; - this.lblImageFilePath.Text = "Image file path:"; // // lblRowCount // - this.lblRowCount.AutoSize = true; - this.lblRowCount.Location = new System.Drawing.Point(13, 40); + resources.ApplyResources(this.lblRowCount, "lblRowCount"); this.lblRowCount.Name = "lblRowCount"; - this.lblRowCount.Size = new System.Drawing.Size(62, 13); - this.lblRowCount.TabIndex = 3; - this.lblRowCount.Text = "Row count:"; // // lblColumnCount // - this.lblColumnCount.AutoSize = true; - this.lblColumnCount.Location = new System.Drawing.Point(13, 64); + resources.ApplyResources(this.lblColumnCount, "lblColumnCount"); this.lblColumnCount.Name = "lblColumnCount"; - this.lblColumnCount.Size = new System.Drawing.Size(75, 13); - this.lblColumnCount.TabIndex = 5; - this.lblColumnCount.Text = "Column count:"; // // nudRowCount // - this.nudRowCount.Location = new System.Drawing.Point(120, 36); + resources.ApplyResources(this.nudRowCount, "nudRowCount"); this.nudRowCount.Minimum = new decimal(new int[] { 1, 0, 0, 0}); this.nudRowCount.Name = "nudRowCount"; - this.nudRowCount.Size = new System.Drawing.Size(56, 20); - this.nudRowCount.TabIndex = 4; - this.nudRowCount.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; this.nudRowCount.Value = new decimal(new int[] { 1, 0, @@ -90,16 +76,13 @@ private void InitializeComponent() // // nudColumnCount // - this.nudColumnCount.Location = new System.Drawing.Point(120, 60); + resources.ApplyResources(this.nudColumnCount, "nudColumnCount"); this.nudColumnCount.Minimum = new decimal(new int[] { 1, 0, 0, 0}); this.nudColumnCount.Name = "nudColumnCount"; - this.nudColumnCount.Size = new System.Drawing.Size(56, 20); - this.nudColumnCount.TabIndex = 6; - this.nudColumnCount.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; this.nudColumnCount.Value = new decimal(new int[] { 1, 0, @@ -108,63 +91,45 @@ private void InitializeComponent() // // txtImageFilePath // - this.txtImageFilePath.Location = new System.Drawing.Point(120, 12); + resources.ApplyResources(this.txtImageFilePath, "txtImageFilePath"); this.txtImageFilePath.Name = "txtImageFilePath"; - this.txtImageFilePath.Size = new System.Drawing.Size(280, 20); - this.txtImageFilePath.TabIndex = 1; // // lblOutputFolder // - this.lblOutputFolder.AutoSize = true; - this.lblOutputFolder.Location = new System.Drawing.Point(13, 88); + resources.ApplyResources(this.lblOutputFolder, "lblOutputFolder"); this.lblOutputFolder.Name = "lblOutputFolder"; - this.lblOutputFolder.Size = new System.Drawing.Size(71, 13); - this.lblOutputFolder.TabIndex = 7; - this.lblOutputFolder.Text = "Output folder:"; // // txtOutputFolder // - this.txtOutputFolder.Location = new System.Drawing.Point(120, 84); + resources.ApplyResources(this.txtOutputFolder, "txtOutputFolder"); this.txtOutputFolder.Name = "txtOutputFolder"; - this.txtOutputFolder.Size = new System.Drawing.Size(280, 20); - this.txtOutputFolder.TabIndex = 8; // // btnImageFilePathBrowse // - this.btnImageFilePathBrowse.Location = new System.Drawing.Point(408, 11); + resources.ApplyResources(this.btnImageFilePathBrowse, "btnImageFilePathBrowse"); this.btnImageFilePathBrowse.Name = "btnImageFilePathBrowse"; - this.btnImageFilePathBrowse.Size = new System.Drawing.Size(32, 23); - this.btnImageFilePathBrowse.TabIndex = 2; - this.btnImageFilePathBrowse.Text = "..."; this.btnImageFilePathBrowse.UseVisualStyleBackColor = true; this.btnImageFilePathBrowse.Click += new System.EventHandler(this.BtnImageFilePathBrowse_Click); // // btnOutputFolderBrowse // - this.btnOutputFolderBrowse.Location = new System.Drawing.Point(408, 83); + resources.ApplyResources(this.btnOutputFolderBrowse, "btnOutputFolderBrowse"); this.btnOutputFolderBrowse.Name = "btnOutputFolderBrowse"; - this.btnOutputFolderBrowse.Size = new System.Drawing.Size(32, 23); - this.btnOutputFolderBrowse.TabIndex = 9; - this.btnOutputFolderBrowse.Text = "..."; this.btnOutputFolderBrowse.UseVisualStyleBackColor = true; this.btnOutputFolderBrowse.Click += new System.EventHandler(this.BtnOutputFolderBrowse_Click); // // btnSplitImage // - this.btnSplitImage.Location = new System.Drawing.Point(16, 112); + resources.ApplyResources(this.btnSplitImage, "btnSplitImage"); this.btnSplitImage.Name = "btnSplitImage"; - this.btnSplitImage.Size = new System.Drawing.Size(424, 24); - this.btnSplitImage.TabIndex = 10; - this.btnSplitImage.Text = "Split image"; this.btnSplitImage.UseVisualStyleBackColor = true; this.btnSplitImage.Click += new System.EventHandler(this.BtnSplitImage_Click); // // ImageSplitterForm // - this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + resources.ApplyResources(this, "$this"); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.BackColor = System.Drawing.SystemColors.Window; - this.ClientSize = new System.Drawing.Size(449, 145); this.Controls.Add(this.btnSplitImage); this.Controls.Add(this.btnOutputFolderBrowse); this.Controls.Add(this.btnImageFilePathBrowse); @@ -179,8 +144,6 @@ private void InitializeComponent() this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle; this.MaximizeBox = false; this.Name = "ImageSplitterForm"; - this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; - this.Text = "ShareX - Image splitter"; ((System.ComponentModel.ISupportInitialize)(this.nudRowCount)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.nudColumnCount)).EndInit(); this.ResumeLayout(false); diff --git a/ShareX.MediaLib/Forms/ImageSplitterForm.resx b/ShareX.MediaLib/Forms/ImageSplitterForm.resx index 1af7de150..b10c56758 100644 --- a/ShareX.MediaLib/Forms/ImageSplitterForm.resx +++ b/ShareX.MediaLib/Forms/ImageSplitterForm.resx @@ -117,4 +117,298 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + True + + + + 13, 16 + + + 79, 13 + + + 0 + + + Image file path: + + + lblImageFilePath + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 10 + + + True + + + 13, 40 + + + 62, 13 + + + 3 + + + Row count: + + + lblRowCount + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 9 + + + True + + + 13, 64 + + + 75, 13 + + + 5 + + + Column count: + + + lblColumnCount + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 8 + + + 120, 36 + + + 56, 20 + + + 4 + + + + Center + + + nudRowCount + + + System.Windows.Forms.NumericUpDown, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 7 + + + 120, 60 + + + 56, 20 + + + 6 + + + Center + + + nudColumnCount + + + System.Windows.Forms.NumericUpDown, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 6 + + + 120, 12 + + + 280, 20 + + + 1 + + + txtImageFilePath + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 5 + + + True + + + 13, 88 + + + 71, 13 + + + 7 + + + Output folder: + + + lblOutputFolder + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 4 + + + 120, 84 + + + 280, 20 + + + 8 + + + txtOutputFolder + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 3 + + + 408, 11 + + + 32, 23 + + + 2 + + + ... + + + btnImageFilePathBrowse + + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 2 + + + 408, 83 + + + 32, 23 + + + 9 + + + ... + + + btnOutputFolderBrowse + + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 1 + + + 16, 112 + + + 424, 24 + + + 10 + + + Split image + + + btnSplitImage + + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 0 + + + True + + + 6, 13 + + + 449, 145 + + + CenterScreen + + + ShareX - Image splitter + + + ImageSplitterForm + + + System.Windows.Forms.Form, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + \ No newline at end of file diff --git a/ShareX/Forms/ApplicationSettingsForm.Designer.cs b/ShareX/Forms/ApplicationSettingsForm.Designer.cs index 954c56d78..0bc574bcb 100644 --- a/ShareX/Forms/ApplicationSettingsForm.Designer.cs +++ b/ShareX/Forms/ApplicationSettingsForm.Designer.cs @@ -91,6 +91,8 @@ private void InitializeComponent() this.lblSaveImageSubFolderPatternPreview = new System.Windows.Forms.Label(); this.txtSaveImageSubFolderPattern = new System.Windows.Forms.TextBox(); this.tpExportImport = new System.Windows.Forms.TabPage(); + this.cbExportHistory = new System.Windows.Forms.CheckBox(); + this.cbExportSettings = new System.Windows.Forms.CheckBox(); this.lblExportImportNote = new System.Windows.Forms.Label(); this.btnResetSettings = new System.Windows.Forms.Button(); this.pbExportImport = new System.Windows.Forms.ProgressBar(); @@ -154,8 +156,6 @@ private void InitializeComponent() this.tpAdvanced = new System.Windows.Forms.TabPage(); this.pgSettings = new System.Windows.Forms.PropertyGrid(); this.tttvMain = new ShareX.HelpersLib.TabToTreeView(); - this.cbExportSettings = new System.Windows.Forms.CheckBox(); - this.cbExportHistory = new System.Windows.Forms.CheckBox(); this.tcSettings.SuspendLayout(); this.tpGeneral.SuspendLayout(); this.tpTheme.SuspendLayout(); @@ -652,6 +652,24 @@ private void InitializeComponent() resources.ApplyResources(this.tpExportImport, "tpExportImport"); this.tpExportImport.Name = "tpExportImport"; // + // cbExportHistory + // + resources.ApplyResources(this.cbExportHistory, "cbExportHistory"); + this.cbExportHistory.Checked = true; + this.cbExportHistory.CheckState = System.Windows.Forms.CheckState.Checked; + this.cbExportHistory.Name = "cbExportHistory"; + this.cbExportHistory.UseVisualStyleBackColor = true; + this.cbExportHistory.CheckedChanged += new System.EventHandler(this.cbExportHistory_CheckedChanged); + // + // cbExportSettings + // + resources.ApplyResources(this.cbExportSettings, "cbExportSettings"); + this.cbExportSettings.Checked = true; + this.cbExportSettings.CheckState = System.Windows.Forms.CheckState.Checked; + this.cbExportSettings.Name = "cbExportSettings"; + this.cbExportSettings.UseVisualStyleBackColor = true; + this.cbExportSettings.CheckedChanged += new System.EventHandler(this.cbExportSettings_CheckedChanged); + // // lblExportImportNote // resources.ApplyResources(this.lblExportImportNote, "lblExportImportNote"); @@ -1145,24 +1163,6 @@ private void InitializeComponent() this.tttvMain.TreeViewSize = 175; this.tttvMain.TabChanged += new ShareX.HelpersLib.TabToTreeView.TabChangedEventHandler(this.tttvMain_TabChanged); // - // cbExportSettings - // - resources.ApplyResources(this.cbExportSettings, "cbExportSettings"); - this.cbExportSettings.Checked = true; - this.cbExportSettings.CheckState = System.Windows.Forms.CheckState.Checked; - this.cbExportSettings.Name = "cbExportSettings"; - this.cbExportSettings.UseVisualStyleBackColor = true; - this.cbExportSettings.CheckedChanged += new System.EventHandler(this.cbExportSettings_CheckedChanged); - // - // cbExportHistory - // - resources.ApplyResources(this.cbExportHistory, "cbExportHistory"); - this.cbExportHistory.Checked = true; - this.cbExportHistory.CheckState = System.Windows.Forms.CheckState.Checked; - this.cbExportHistory.Name = "cbExportHistory"; - this.cbExportHistory.UseVisualStyleBackColor = true; - this.cbExportHistory.CheckedChanged += new System.EventHandler(this.cbExportHistory_CheckedChanged); - // // ApplicationSettingsForm // resources.ApplyResources(this, "$this"); diff --git a/ShareX/Forms/ApplicationSettingsForm.resx b/ShareX/Forms/ApplicationSettingsForm.resx index 80bee8817..3502ff91d 100644 --- a/ShareX/Forms/ApplicationSettingsForm.resx +++ b/ShareX/Forms/ApplicationSettingsForm.resx @@ -1753,7 +1753,7 @@ 0 - Note: Do not share this exported file with anyone because it may contain private informations such as your account passwords. + Note: Do not share the exported file with anyone because it might contain private information such as account details and your upload history. lblExportImportNote @@ -1777,7 +1777,7 @@ 184, 24 - 6 + 5 Reset settings... @@ -1804,7 +1804,7 @@ 184, 23 - 4 + 6 False @@ -1858,7 +1858,7 @@ 184, 23 - 5 + 4 Import...