mirror of
https://git.alee14.me/shiftos-archive/ShiftOS_TheReturn.git
synced 2025-01-23 02:12:14 +00:00
TriWrite is so far now a TextPad clone
This commit is contained in:
parent
a41f947d8a
commit
0c2f232911
3 changed files with 142 additions and 9 deletions
86
ShiftOS.WinForms/Applications/TriWrite.Designer.cs
generated
86
ShiftOS.WinForms/Applications/TriWrite.Designer.cs
generated
|
@ -28,7 +28,7 @@
|
|||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(AddressBook));
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(TriWrite));
|
||||
this.menuStrip1 = new System.Windows.Forms.MenuStrip();
|
||||
this.addContactToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.removeToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
|
@ -36,8 +36,14 @@
|
|||
this.panel1 = new System.Windows.Forms.Panel();
|
||||
this.txtbody = new System.Windows.Forms.Label();
|
||||
this.lbtitle = new System.Windows.Forms.Label();
|
||||
this.txtcontents = new System.Windows.Forms.TextBox();
|
||||
this.menuStrip2 = new System.Windows.Forms.MenuStrip();
|
||||
this.newToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.openToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.saveToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.menuStrip1.SuspendLayout();
|
||||
this.panel1.SuspendLayout();
|
||||
this.menuStrip2.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// menuStrip1
|
||||
|
@ -51,9 +57,20 @@
|
|||
this.menuStrip1.TabIndex = 0;
|
||||
this.menuStrip1.Text = "menuStrip1";
|
||||
//
|
||||
// addContactToolStripMenuItem
|
||||
//
|
||||
this.addContactToolStripMenuItem.Name = "addContactToolStripMenuItem";
|
||||
this.addContactToolStripMenuItem.Size = new System.Drawing.Size(32, 19);
|
||||
//
|
||||
// removeToolStripMenuItem
|
||||
//
|
||||
this.removeToolStripMenuItem.Name = "removeToolStripMenuItem";
|
||||
this.removeToolStripMenuItem.Size = new System.Drawing.Size(32, 19);
|
||||
//
|
||||
// tvcontacts
|
||||
//
|
||||
this.tvcontacts.Dock = System.Windows.Forms.DockStyle.Left;
|
||||
this.tvcontacts.LineColor = System.Drawing.Color.Empty;
|
||||
this.tvcontacts.Location = new System.Drawing.Point(0, 24);
|
||||
this.tvcontacts.Name = "tvcontacts";
|
||||
this.tvcontacts.Size = new System.Drawing.Size(224, 551);
|
||||
|
@ -71,8 +88,8 @@
|
|||
//
|
||||
// txtbody
|
||||
//
|
||||
this.txtbody.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||
| System.Windows.Forms.AnchorStyles.Left)
|
||||
this.txtbody.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.txtbody.Location = new System.Drawing.Point(7, 54);
|
||||
this.txtbody.Name = "txtbody";
|
||||
|
@ -85,10 +102,66 @@
|
|||
this.lbtitle.AutoSize = true;
|
||||
this.lbtitle.Location = new System.Drawing.Point(7, 4);
|
||||
this.lbtitle.Name = "lbtitle";
|
||||
this.lbtitle.Size = new System.Drawing.Size(73, 13);
|
||||
this.lbtitle.Size = new System.Drawing.Size(44, 13);
|
||||
this.lbtitle.TabIndex = 0;
|
||||
this.lbtitle.Tag = "header1";
|
||||
this.lbtitle.Text = "TriWrite";
|
||||
//
|
||||
// txtcontents
|
||||
//
|
||||
this.txtcontents.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.txtcontents.Location = new System.Drawing.Point(-61, 53);
|
||||
this.txtcontents.Multiline = true;
|
||||
this.txtcontents.Name = "txtcontents";
|
||||
this.txtcontents.Size = new System.Drawing.Size(588, 460);
|
||||
this.txtcontents.TabIndex = 1;
|
||||
this.txtcontents.TabStop = false;
|
||||
//
|
||||
// menuStrip2
|
||||
//
|
||||
this.menuStrip2.Dock = System.Windows.Forms.DockStyle.None;
|
||||
this.menuStrip2.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||
this.newToolStripMenuItem,
|
||||
this.openToolStripMenuItem,
|
||||
this.saveToolStripMenuItem});
|
||||
this.menuStrip2.Location = new System.Drawing.Point(0, 0);
|
||||
this.menuStrip2.Name = "menuStrip2";
|
||||
this.menuStrip2.Size = new System.Drawing.Size(648, 24);
|
||||
this.menuStrip2.TabIndex = 2;
|
||||
this.menuStrip2.Text = "menuStrip2";
|
||||
//
|
||||
// newToolStripMenuItem
|
||||
//
|
||||
this.newToolStripMenuItem.Name = "newToolStripMenuItem";
|
||||
this.newToolStripMenuItem.Size = new System.Drawing.Size(43, 20);
|
||||
this.newToolStripMenuItem.Text = "New";
|
||||
//
|
||||
// openToolStripMenuItem
|
||||
//
|
||||
this.openToolStripMenuItem.Name = "openToolStripMenuItem";
|
||||
this.openToolStripMenuItem.Size = new System.Drawing.Size(48, 20);
|
||||
this.openToolStripMenuItem.Text = "Open";
|
||||
//
|
||||
// saveToolStripMenuItem
|
||||
//
|
||||
this.saveToolStripMenuItem.Name = "saveToolStripMenuItem";
|
||||
this.saveToolStripMenuItem.Size = new System.Drawing.Size(43, 20);
|
||||
this.saveToolStripMenuItem.Text = "Save";
|
||||
//
|
||||
// TriWrite
|
||||
//
|
||||
this.Controls.Add(this.menuStrip2);
|
||||
this.Controls.Add(this.txtcontents);
|
||||
this.Name = "TriWrite";
|
||||
this.Size = new System.Drawing.Size(527, 513);
|
||||
this.menuStrip1.ResumeLayout(false);
|
||||
this.menuStrip1.PerformLayout();
|
||||
this.panel1.ResumeLayout(false);
|
||||
this.panel1.PerformLayout();
|
||||
this.menuStrip2.ResumeLayout(false);
|
||||
this.menuStrip2.PerformLayout();
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
|
@ -101,5 +174,10 @@
|
|||
private System.Windows.Forms.Panel panel1;
|
||||
private System.Windows.Forms.Label txtbody;
|
||||
private System.Windows.Forms.Label lbtitle;
|
||||
private System.Windows.Forms.TextBox txtcontents;
|
||||
private System.Windows.Forms.MenuStrip menuStrip2;
|
||||
private System.Windows.Forms.ToolStripMenuItem newToolStripMenuItem;
|
||||
private System.Windows.Forms.ToolStripMenuItem openToolStripMenuItem;
|
||||
private System.Windows.Forms.ToolStripMenuItem saveToolStripMenuItem;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,15 +1,14 @@
|
|||
using System;
|
||||
using ShiftOS.Objects.ShiftFS;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Drawing;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
using ShiftOS.Engine;
|
||||
using static ShiftOS.Objects.ShiftFS.Utils;
|
||||
using Newtonsoft.Json;
|
||||
|
||||
namespace ShiftOS.WinForms.Applications
|
||||
{
|
||||
|
@ -20,11 +19,40 @@ namespace ShiftOS.WinForms.Applications
|
|||
public partial class TriWrite : UserControl, IShiftOSWindow
|
||||
{
|
||||
|
||||
public void OnLoad()
|
||||
public TriWrite()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
private void newToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
{
|
||||
txtcontents.Text = "";
|
||||
}
|
||||
|
||||
private void openToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public void LoadFile(string file)
|
||||
{
|
||||
txtcontents.Text = Utils.ReadAllText(file);
|
||||
}
|
||||
|
||||
public void SaveFile(string file)
|
||||
{
|
||||
Utils.WriteAllText(file, txtcontents.Text);
|
||||
}
|
||||
|
||||
private void saveToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public void OnLoad()
|
||||
{
|
||||
}
|
||||
|
||||
public void OnSkinLoad()
|
||||
{
|
||||
}
|
||||
|
|
|
@ -120,6 +120,18 @@
|
|||
<metadata name="menuStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
<metadata name="menuStrip1.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="tvcontacts.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="panel1.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="txtbody.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<data name="txtbody.Text" xml:space="preserve">
|
||||
<value>The Address Book helps you keep track of all your contacts within the digital society, whether they be friends, enemies, or whatnot.
|
||||
|
||||
|
@ -127,4 +139,19 @@ On the left, we have made a list of all your contacts. You can click on one to v
|
|||
|
||||
To add a contact, simply click "Add Contact", and to remove one, click "Remove". Some contacts may not be removed as they are integral to the progression of your adventures within the digital society.</value>
|
||||
</data>
|
||||
<metadata name="lbtitle.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="txtcontents.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="menuStrip2.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>132, 17</value>
|
||||
</metadata>
|
||||
<metadata name="menuStrip2.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="$this.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
</root>
|
Loading…
Reference in a new issue