5 Commits
v1.1 ... v1.3

Author SHA1 Message Date
4fa818f35e More examples 2023-05-17 04:33:04 +03:00
11b268a350 Baseline support 2023-05-17 04:32:44 +03:00
703e8d91ef More keyboard shortcuts 2023-05-16 21:52:36 +03:00
de8aa295da Fixed open file procedure - minilist code leading zeroes 2023-05-16 21:38:30 +03:00
Anton Mukhin
232b543a35 Files re-arrange in the repo; Screenshots; Update readme.md 2023-05-16 09:58:17 +03:00
17 changed files with 200 additions and 78 deletions

View File

@@ -50,22 +50,18 @@
this.label5 = new System.Windows.Forms.Label(); this.label5 = new System.Windows.Forms.Label();
this.menuStrip1 = new System.Windows.Forms.MenuStrip(); this.menuStrip1 = new System.Windows.Forms.MenuStrip();
this.fileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.fileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.editToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.toolsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.exportToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.aboutToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.dlgSave = new System.Windows.Forms.SaveFileDialog();
this.dlgOpen = new System.Windows.Forms.OpenFileDialog();
this.newToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.newToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.openToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.openToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.saveToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.saveToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.exitToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.exitToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.editToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.copyToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.copyToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.pasteToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.pasteToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.prependSymbolToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.prependSymbolToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.appendSymbolToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.appendSymbolToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.removeSymbolToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.removeSymbolToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.applyToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.applyToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.toolsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.shiftUpToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.shiftUpToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.shiftDownToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.shiftDownToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.shiftLeftToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.shiftLeftToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
@@ -73,6 +69,11 @@
this.invertToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.invertToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.mirrorXToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.mirrorXToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.mirrorYToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.mirrorYToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.exportToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.aboutToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.dlgSave = new System.Windows.Forms.SaveFileDialog();
this.dlgOpen = new System.Windows.Forms.OpenFileDialog();
this.btnBaseline = new System.Windows.Forms.Button();
((System.ComponentModel.ISupportInitialize)(this.nudX)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudX)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.nudY)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudY)).BeginInit();
this.panel1.SuspendLayout(); this.panel1.SuspendLayout();
@@ -122,7 +123,7 @@
// nudY // nudY
// //
this.nudY.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.nudY.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.nudY.Location = new System.Drawing.Point(717, 53); this.nudY.Location = new System.Drawing.Point(717, 49);
this.nudY.Maximum = new decimal(new int[] { this.nudY.Maximum = new decimal(new int[] {
255, 255,
0, 0,
@@ -157,7 +158,7 @@
// //
this.label2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.label2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.label2.AutoSize = true; this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(670, 55); this.label2.Location = new System.Drawing.Point(670, 51);
this.label2.Name = "label2"; this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(41, 13); this.label2.Size = new System.Drawing.Size(41, 13);
this.label2.TabIndex = 4; this.label2.TabIndex = 4;
@@ -202,7 +203,7 @@
// //
this.label4.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.label4.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.label4.AutoSize = true; this.label4.AutoSize = true;
this.label4.Location = new System.Drawing.Point(602, 29); this.label4.Location = new System.Drawing.Point(604, 29);
this.label4.Name = "label4"; this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(62, 13); this.label4.Size = new System.Drawing.Size(62, 13);
this.label4.TabIndex = 7; this.label4.TabIndex = 7;
@@ -304,7 +305,7 @@
// btnExport // btnExport
// //
this.btnExport.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.btnExport.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.btnExport.Location = new System.Drawing.Point(696, 99); this.btnExport.Location = new System.Drawing.Point(696, 109);
this.btnExport.Name = "btnExport"; this.btnExport.Name = "btnExport";
this.btnExport.Size = new System.Drawing.Size(75, 23); this.btnExport.Size = new System.Drawing.Size(75, 23);
this.btnExport.TabIndex = 10; this.btnExport.TabIndex = 10;
@@ -343,7 +344,7 @@
// btnApply // btnApply
// //
this.btnApply.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.btnApply.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.btnApply.Location = new System.Drawing.Point(589, 99); this.btnApply.Location = new System.Drawing.Point(615, 109);
this.btnApply.Name = "btnApply"; this.btnApply.Name = "btnApply";
this.btnApply.Size = new System.Drawing.Size(75, 23); this.btnApply.Size = new System.Drawing.Size(75, 23);
this.btnApply.TabIndex = 13; this.btnApply.TabIndex = 13;
@@ -376,7 +377,7 @@
// //
this.label5.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.label5.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.label5.AutoSize = true; this.label5.AutoSize = true;
this.label5.Location = new System.Drawing.Point(640, 71); this.label5.Location = new System.Drawing.Point(554, 114);
this.label5.Name = "label5"; this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(24, 13); this.label5.Size = new System.Drawing.Size(24, 13);
this.label5.TabIndex = 16; this.label5.TabIndex = 16;
@@ -407,60 +408,6 @@
this.fileToolStripMenuItem.Size = new System.Drawing.Size(37, 20); this.fileToolStripMenuItem.Size = new System.Drawing.Size(37, 20);
this.fileToolStripMenuItem.Text = "File"; this.fileToolStripMenuItem.Text = "File";
// //
// editToolStripMenuItem
//
this.editToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.copyToolStripMenuItem,
this.pasteToolStripMenuItem,
this.prependSymbolToolStripMenuItem,
this.appendSymbolToolStripMenuItem,
this.removeSymbolToolStripMenuItem,
this.applyToolStripMenuItem});
this.editToolStripMenuItem.Name = "editToolStripMenuItem";
this.editToolStripMenuItem.Size = new System.Drawing.Size(39, 20);
this.editToolStripMenuItem.Text = "Edit";
//
// toolsToolStripMenuItem
//
this.toolsToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.shiftUpToolStripMenuItem,
this.shiftDownToolStripMenuItem,
this.shiftLeftToolStripMenuItem,
this.shiftRightToolStripMenuItem,
this.invertToolStripMenuItem,
this.mirrorXToolStripMenuItem,
this.mirrorYToolStripMenuItem,
this.exportToolStripMenuItem});
this.toolsToolStripMenuItem.Name = "toolsToolStripMenuItem";
this.toolsToolStripMenuItem.Size = new System.Drawing.Size(46, 20);
this.toolsToolStripMenuItem.Text = "Tools";
//
// exportToolStripMenuItem
//
this.exportToolStripMenuItem.Name = "exportToolStripMenuItem";
this.exportToolStripMenuItem.ShortcutKeyDisplayString = "Ctrl+E";
this.exportToolStripMenuItem.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.E)));
this.exportToolStripMenuItem.Size = new System.Drawing.Size(197, 22);
this.exportToolStripMenuItem.Text = "Export";
this.exportToolStripMenuItem.Click += new System.EventHandler(this.button1_Click);
//
// aboutToolStripMenuItem
//
this.aboutToolStripMenuItem.Name = "aboutToolStripMenuItem";
this.aboutToolStripMenuItem.Size = new System.Drawing.Size(52, 20);
this.aboutToolStripMenuItem.Text = "About";
this.aboutToolStripMenuItem.Click += new System.EventHandler(this.aboutToolStripMenuItem_Click);
//
// dlgSave
//
this.dlgSave.DefaultExt = "mbf";
this.dlgSave.Filter = "McBitFont files|*.mbf|All files|*.*";
//
// dlgOpen
//
this.dlgOpen.DefaultExt = "mbf";
this.dlgOpen.Filter = "McBitFont files|*.mbf|All files|*.*";
//
// newToolStripMenuItem // newToolStripMenuItem
// //
this.newToolStripMenuItem.Image = global::McBitFont.Properties.Resources.file; this.newToolStripMenuItem.Image = global::McBitFont.Properties.Resources.file;
@@ -501,6 +448,19 @@
this.exitToolStripMenuItem.Text = "Exit"; this.exitToolStripMenuItem.Text = "Exit";
this.exitToolStripMenuItem.Click += new System.EventHandler(this.exitToolStripMenuItem_Click); this.exitToolStripMenuItem.Click += new System.EventHandler(this.exitToolStripMenuItem_Click);
// //
// editToolStripMenuItem
//
this.editToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.copyToolStripMenuItem,
this.pasteToolStripMenuItem,
this.prependSymbolToolStripMenuItem,
this.appendSymbolToolStripMenuItem,
this.removeSymbolToolStripMenuItem,
this.applyToolStripMenuItem});
this.editToolStripMenuItem.Name = "editToolStripMenuItem";
this.editToolStripMenuItem.Size = new System.Drawing.Size(39, 20);
this.editToolStripMenuItem.Text = "Edit";
//
// copyToolStripMenuItem // copyToolStripMenuItem
// //
this.copyToolStripMenuItem.Enabled = false; this.copyToolStripMenuItem.Enabled = false;
@@ -508,7 +468,7 @@
this.copyToolStripMenuItem.Name = "copyToolStripMenuItem"; this.copyToolStripMenuItem.Name = "copyToolStripMenuItem";
this.copyToolStripMenuItem.ShortcutKeyDisplayString = "Ctrl+C"; this.copyToolStripMenuItem.ShortcutKeyDisplayString = "Ctrl+C";
this.copyToolStripMenuItem.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.C))); this.copyToolStripMenuItem.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.C)));
this.copyToolStripMenuItem.Size = new System.Drawing.Size(160, 22); this.copyToolStripMenuItem.Size = new System.Drawing.Size(212, 22);
this.copyToolStripMenuItem.Text = "Copy"; this.copyToolStripMenuItem.Text = "Copy";
this.copyToolStripMenuItem.Click += new System.EventHandler(this.copyToolStripMenuItem_Click); this.copyToolStripMenuItem.Click += new System.EventHandler(this.copyToolStripMenuItem_Click);
// //
@@ -519,7 +479,7 @@
this.pasteToolStripMenuItem.Name = "pasteToolStripMenuItem"; this.pasteToolStripMenuItem.Name = "pasteToolStripMenuItem";
this.pasteToolStripMenuItem.ShortcutKeyDisplayString = "Ctrl+V"; this.pasteToolStripMenuItem.ShortcutKeyDisplayString = "Ctrl+V";
this.pasteToolStripMenuItem.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.V))); this.pasteToolStripMenuItem.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.V)));
this.pasteToolStripMenuItem.Size = new System.Drawing.Size(160, 22); this.pasteToolStripMenuItem.Size = new System.Drawing.Size(212, 22);
this.pasteToolStripMenuItem.Text = "Paste"; this.pasteToolStripMenuItem.Text = "Paste";
this.pasteToolStripMenuItem.Click += new System.EventHandler(this.pasteToolStripMenuItem_Click); this.pasteToolStripMenuItem.Click += new System.EventHandler(this.pasteToolStripMenuItem_Click);
// //
@@ -528,7 +488,9 @@
this.prependSymbolToolStripMenuItem.Enabled = false; this.prependSymbolToolStripMenuItem.Enabled = false;
this.prependSymbolToolStripMenuItem.Image = global::McBitFont.Properties.Resources.action_add; this.prependSymbolToolStripMenuItem.Image = global::McBitFont.Properties.Resources.action_add;
this.prependSymbolToolStripMenuItem.Name = "prependSymbolToolStripMenuItem"; this.prependSymbolToolStripMenuItem.Name = "prependSymbolToolStripMenuItem";
this.prependSymbolToolStripMenuItem.Size = new System.Drawing.Size(160, 22); this.prependSymbolToolStripMenuItem.ShortcutKeyDisplayString = "Ctrl+Ins";
this.prependSymbolToolStripMenuItem.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.Insert)));
this.prependSymbolToolStripMenuItem.Size = new System.Drawing.Size(212, 22);
this.prependSymbolToolStripMenuItem.Text = "Prepend symbol"; this.prependSymbolToolStripMenuItem.Text = "Prepend symbol";
this.prependSymbolToolStripMenuItem.Click += new System.EventHandler(this.prependSymbolToolStripMenuItem_Click); this.prependSymbolToolStripMenuItem.Click += new System.EventHandler(this.prependSymbolToolStripMenuItem_Click);
// //
@@ -537,7 +499,9 @@
this.appendSymbolToolStripMenuItem.Enabled = false; this.appendSymbolToolStripMenuItem.Enabled = false;
this.appendSymbolToolStripMenuItem.Image = global::McBitFont.Properties.Resources.action_add; this.appendSymbolToolStripMenuItem.Image = global::McBitFont.Properties.Resources.action_add;
this.appendSymbolToolStripMenuItem.Name = "appendSymbolToolStripMenuItem"; this.appendSymbolToolStripMenuItem.Name = "appendSymbolToolStripMenuItem";
this.appendSymbolToolStripMenuItem.Size = new System.Drawing.Size(160, 22); this.appendSymbolToolStripMenuItem.ShortcutKeyDisplayString = "Ctrl+End";
this.appendSymbolToolStripMenuItem.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.End)));
this.appendSymbolToolStripMenuItem.Size = new System.Drawing.Size(212, 22);
this.appendSymbolToolStripMenuItem.Text = "Append symbol"; this.appendSymbolToolStripMenuItem.Text = "Append symbol";
this.appendSymbolToolStripMenuItem.Click += new System.EventHandler(this.prependSymbolToolStripMenuItem_Click); this.appendSymbolToolStripMenuItem.Click += new System.EventHandler(this.prependSymbolToolStripMenuItem_Click);
// //
@@ -546,7 +510,9 @@
this.removeSymbolToolStripMenuItem.Enabled = false; this.removeSymbolToolStripMenuItem.Enabled = false;
this.removeSymbolToolStripMenuItem.Image = global::McBitFont.Properties.Resources.action_remove; this.removeSymbolToolStripMenuItem.Image = global::McBitFont.Properties.Resources.action_remove;
this.removeSymbolToolStripMenuItem.Name = "removeSymbolToolStripMenuItem"; this.removeSymbolToolStripMenuItem.Name = "removeSymbolToolStripMenuItem";
this.removeSymbolToolStripMenuItem.Size = new System.Drawing.Size(160, 22); this.removeSymbolToolStripMenuItem.ShortcutKeyDisplayString = "Ctrl+Del";
this.removeSymbolToolStripMenuItem.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.Delete)));
this.removeSymbolToolStripMenuItem.Size = new System.Drawing.Size(212, 22);
this.removeSymbolToolStripMenuItem.Text = "Remove symbol"; this.removeSymbolToolStripMenuItem.Text = "Remove symbol";
this.removeSymbolToolStripMenuItem.Click += new System.EventHandler(this.removeSymbolToolStripMenuItem_Click); this.removeSymbolToolStripMenuItem.Click += new System.EventHandler(this.removeSymbolToolStripMenuItem_Click);
// //
@@ -554,10 +520,27 @@
// //
this.applyToolStripMenuItem.Image = global::McBitFont.Properties.Resources.action_check; this.applyToolStripMenuItem.Image = global::McBitFont.Properties.Resources.action_check;
this.applyToolStripMenuItem.Name = "applyToolStripMenuItem"; this.applyToolStripMenuItem.Name = "applyToolStripMenuItem";
this.applyToolStripMenuItem.Size = new System.Drawing.Size(160, 22); this.applyToolStripMenuItem.ShortcutKeyDisplayString = "Ctrl+Space";
this.applyToolStripMenuItem.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.Space)));
this.applyToolStripMenuItem.Size = new System.Drawing.Size(212, 22);
this.applyToolStripMenuItem.Text = "Apply"; this.applyToolStripMenuItem.Text = "Apply";
this.applyToolStripMenuItem.Click += new System.EventHandler(this.button2_Click); this.applyToolStripMenuItem.Click += new System.EventHandler(this.button2_Click);
// //
// toolsToolStripMenuItem
//
this.toolsToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.shiftUpToolStripMenuItem,
this.shiftDownToolStripMenuItem,
this.shiftLeftToolStripMenuItem,
this.shiftRightToolStripMenuItem,
this.invertToolStripMenuItem,
this.mirrorXToolStripMenuItem,
this.mirrorYToolStripMenuItem,
this.exportToolStripMenuItem});
this.toolsToolStripMenuItem.Name = "toolsToolStripMenuItem";
this.toolsToolStripMenuItem.Size = new System.Drawing.Size(46, 20);
this.toolsToolStripMenuItem.Text = "Tools";
//
// shiftUpToolStripMenuItem // shiftUpToolStripMenuItem
// //
this.shiftUpToolStripMenuItem.Image = global::McBitFont.Properties.Resources.arrow_top; this.shiftUpToolStripMenuItem.Image = global::McBitFont.Properties.Resources.arrow_top;
@@ -628,11 +611,49 @@
this.mirrorYToolStripMenuItem.Text = "Mirror Y"; this.mirrorYToolStripMenuItem.Text = "Mirror Y";
this.mirrorYToolStripMenuItem.Click += new System.EventHandler(this.btnMirrorY_Click); this.mirrorYToolStripMenuItem.Click += new System.EventHandler(this.btnMirrorY_Click);
// //
// exportToolStripMenuItem
//
this.exportToolStripMenuItem.Name = "exportToolStripMenuItem";
this.exportToolStripMenuItem.ShortcutKeyDisplayString = "Ctrl+E";
this.exportToolStripMenuItem.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.E)));
this.exportToolStripMenuItem.Size = new System.Drawing.Size(197, 22);
this.exportToolStripMenuItem.Text = "Export";
this.exportToolStripMenuItem.Click += new System.EventHandler(this.button1_Click);
//
// aboutToolStripMenuItem
//
this.aboutToolStripMenuItem.Name = "aboutToolStripMenuItem";
this.aboutToolStripMenuItem.Size = new System.Drawing.Size(52, 20);
this.aboutToolStripMenuItem.Text = "About";
this.aboutToolStripMenuItem.Click += new System.EventHandler(this.aboutToolStripMenuItem_Click);
//
// dlgSave
//
this.dlgSave.DefaultExt = "mbf";
this.dlgSave.Filter = "McBitFont files|*.mbf|All files|*.*";
//
// dlgOpen
//
this.dlgOpen.DefaultExt = "mbf";
this.dlgOpen.Filter = "McBitFont files|*.mbf|All files|*.*";
//
// btnBaseline
//
this.btnBaseline.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.btnBaseline.Location = new System.Drawing.Point(615, 80);
this.btnBaseline.Name = "btnBaseline";
this.btnBaseline.Size = new System.Drawing.Size(75, 23);
this.btnBaseline.TabIndex = 18;
this.btnBaseline.Text = "Baseline";
this.btnBaseline.UseVisualStyleBackColor = true;
this.btnBaseline.Click += new System.EventHandler(this.btnBaseline_Click);
//
// MainForm // MainForm
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(784, 561); this.ClientSize = new System.Drawing.Size(784, 561);
this.Controls.Add(this.btnBaseline);
this.Controls.Add(this.btnApply); this.Controls.Add(this.btnApply);
this.Controls.Add(this.btnExport); this.Controls.Add(this.btnExport);
this.Controls.Add(this.label5); this.Controls.Add(this.label5);
@@ -717,6 +738,7 @@
private System.Windows.Forms.ToolStripMenuItem appendSymbolToolStripMenuItem; private System.Windows.Forms.ToolStripMenuItem appendSymbolToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem copyToolStripMenuItem; private System.Windows.Forms.ToolStripMenuItem copyToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem pasteToolStripMenuItem; private System.Windows.Forms.ToolStripMenuItem pasteToolStripMenuItem;
private System.Windows.Forms.Button btnBaseline;
} }
} }

View File

@@ -37,6 +37,7 @@ namespace McBitFont {
public struct SaveBlock { public struct SaveBlock {
public bool monospaced; public bool monospaced;
public int codepage; public int codepage;
public int baseline;
public List<FrameMiniature> frames; public List<FrameMiniature> frames;
} }
@@ -50,11 +51,13 @@ namespace McBitFont {
public bool monospaced = false; public bool monospaced = false;
bool modified = false; bool modified = false;
bool prjModified = false; bool prjModified = false;
public const string version = "1.1"; public const string version = "1.3";
public string prjName = "Untitled"; public string prjName = "Untitled";
public int codepage = 1251; public int codepage = 1251;
private FrameMiniature fbuf; private FrameMiniature fbuf;
private bool fbuffer = false; private bool fbuffer = false;
public int baseline = 0;
public bool set_base = false;
public MainForm() { public MainForm() {
InitializeComponent(); InitializeComponent();
@@ -275,6 +278,26 @@ namespace McBitFont {
} }
private void dotPanel_MouseMove(object sender, MouseEventArgs e) { private void dotPanel_MouseMove(object sender, MouseEventArgs e) {
if (set_base) {
int yy = pixelOffset + baseline * (cellSize + gap) - vScroll.Value - 1;
Rectangle rect1 = new Rectangle(pixelOffset, yy, w, 3);
baseline = (e.Y - pixelOffset + vScroll.Value) / (cellSize + gap);
if (baseline >= dotHeight) baseline = dotHeight - 1;
if (baseline < 0) baseline = 0;
yy = pixelOffset + baseline * (cellSize + gap) - vScroll.Value - 1;
Rectangle rect2 = new Rectangle(pixelOffset, yy, w, 3);
dotPanel.Invalidate(rect1);
dotPanel.Invalidate(rect2);
if (e.Button == MouseButtons.Left) {
set_base = false;
return;
}
}
if (e.X >= w || e.X <= pixelOffset || e.Y >= h || e.Y <= pixelOffset) return; if (e.X >= w || e.X <= pixelOffset || e.Y >= h || e.Y <= pixelOffset) return;
int i = (e.X - pixelOffset + hScroll.Value) / (cellSize + gap); int i = (e.X - pixelOffset + hScroll.Value) / (cellSize + gap);
int j = (e.Y - pixelOffset + vScroll.Value) / (cellSize + gap); int j = (e.Y - pixelOffset + vScroll.Value) / (cellSize + gap);
@@ -453,6 +476,16 @@ namespace McBitFont {
g.FillRectangle(sb, x, y, cellSize, cellSize); g.FillRectangle(sb, x, y, cellSize, cellSize);
} }
} }
if (baseline > 0 && gap > 0) {
x = pixelOffset - hScroll.Value;
y = pixelOffset + baseline * (cellSize + gap) - vScroll.Value - 1;
g.DrawLine(
new Pen(Color.Blue, 2),
x, y,
w, y
);
}
} }
private void exitToolStripMenuItem_Click(object sender, EventArgs e) { private void exitToolStripMenuItem_Click(object sender, EventArgs e) {
@@ -597,6 +630,7 @@ namespace McBitFont {
sav.monospaced = monospaced; sav.monospaced = monospaced;
sav.frames = frames; sav.frames = frames;
sav.codepage = codepage; sav.codepage = codepage;
sav.baseline = baseline;
BinaryFormatter formatter = new BinaryFormatter(); BinaryFormatter formatter = new BinaryFormatter();
using (Stream ms = File.OpenWrite(dlgSave.FileName)) { using (Stream ms = File.OpenWrite(dlgSave.FileName)) {
formatter.Serialize(ms, sav); formatter.Serialize(ms, sav);
@@ -625,12 +659,13 @@ namespace McBitFont {
} }
monospaced = sav.monospaced; monospaced = sav.monospaced;
codepage = sav.codepage; codepage = sav.codepage;
baseline = sav.baseline;
lblType.Text = monospaced ? "Monospaced" : "Variable width / Single"; lblType.Text = monospaced ? "Monospaced" : "Variable width / Single";
frames = sav.frames; frames = sav.frames;
miniList.Items.Clear(); miniList.Items.Clear();
ilMiniatures.Images.Clear(); ilMiniatures.Images.Clear();
foreach (FrameMiniature ff in frames) { foreach (FrameMiniature ff in frames) {
var s = ff.code.ToString(); var s = ff.code.ToString().PadLeft(3, '0');
ilMiniatures.Images.Add(s, (Image)getMiniPictue(ff)); ilMiniatures.Images.Add(s, (Image)getMiniPictue(ff));
miniList.Items.Add(s, s + ' ' + (char)ff.code, s); miniList.Items.Add(s, s + ' ' + (char)ff.code, s);
} }
@@ -713,6 +748,10 @@ namespace McBitFont {
form.ShowDialog(); form.ShowDialog();
} }
private void btnBaseline_Click(object sender, EventArgs e) {
set_base = !set_base;
}
private void MainForm_FormClosing(object sender, FormClosingEventArgs e) { private void MainForm_FormClosing(object sender, FormClosingEventArgs e) {
if (prjModified) { if (prjModified) {
if (MessageBox.Show("The project is modified.\nAre you sure you want to quit?", "Are you sure?", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.No) { if (MessageBox.Show("The project is modified.\nAre you sure you want to quit?", "Are you sure?", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.No) {

View File

@@ -12,6 +12,21 @@
<FileAlignment>512</FileAlignment> <FileAlignment>512</FileAlignment>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects> <AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<Deterministic>true</Deterministic> <Deterministic>true</Deterministic>
<PublishUrl>publish\</PublishUrl>
<Install>true</Install>
<InstallFrom>Disk</InstallFrom>
<UpdateEnabled>false</UpdateEnabled>
<UpdateMode>Foreground</UpdateMode>
<UpdateInterval>7</UpdateInterval>
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
<UpdatePeriodically>false</UpdatePeriodically>
<UpdateRequired>false</UpdateRequired>
<MapFileExtensions>true</MapFileExtensions>
<ApplicationRevision>0</ApplicationRevision>
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
<IsWebBootstrapper>false</IsWebBootstrapper>
<UseApplicationTrust>false</UseApplicationTrust>
<BootstrapperEnabled>true</BootstrapperEnabled>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>AnyCPU</PlatformTarget>
@@ -177,5 +192,17 @@
<None Include="Resources\icon_32.png" /> <None Include="Resources\icon_32.png" />
<None Include="Resources\icon.png" /> <None Include="Resources\icon.png" />
</ItemGroup> </ItemGroup>
<ItemGroup>
<BootstrapperPackage Include=".NETFramework,Version=v4.7.2">
<Visible>False</Visible>
<ProductName>Microsoft .NET Framework 4.7.2 %28x86 и x64%29</ProductName>
<Install>true</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1</ProductName>
<Install>false</Install>
</BootstrapperPackage>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project> </Project>

View File

@@ -10,7 +10,7 @@ using System.Runtime.InteropServices;
[assembly: AssemblyConfiguration("")] [assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")] [assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("McBitFont")] [assembly: AssemblyProduct("McBitFont")]
[assembly: AssemblyCopyright("Anton Mukhin © 2023")] [assembly: AssemblyCopyright("© Anton Mukhin, 2023")]
[assembly: AssemblyTrademark("")] [assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")] [assembly: AssemblyCulture("")]
@@ -32,5 +32,5 @@ using System.Runtime.InteropServices;
// Можно задать все значения или принять номера сборки и редакции по умолчанию // Можно задать все значения или принять номера сборки и редакции по умолчанию
// используя "*", как показано ниже: // используя "*", как показано ниже:
// [assembly: AssemblyVersion("1.0.*")] // [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.1.0.0")] [assembly: AssemblyVersion("1.3.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyFileVersion("1.3.0.0")]

View File

@@ -1,3 +1,37 @@
# McBitFont # McBitFont
pixel based Font to C arrays converter McFLY's Bit Font and Image Editor
Features:
- Generate a project based on a font installed in the system
- Basic pixel manipulations: shift, flip, invert, etc...
- Save / Load your project for later edits
- Export as a C array in different formats
Requires .Net Framework 4.7+
Some basic hints on the interface:
- Mouse 1 to mark a puxel black
- Mouse 2 to mark a puxel white
- Drag the mouse holding a button to draw pixels
- Mouse Scroll to scroll up and down
- Crtl + scroll to scroll left and right
- Shift + scroll to zoom
Download in the Releases section!
### Screenshots:
Main window
![Main window](/images/Screenshot_01.png)
New project dialog
![New project](/images/Screenshot_02.png)
Export dialog
![Export](/images/Screenshot_03.png)

BIN
examples/CP437_Cyr_8x16.mbf Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

Before

Width:  |  Height:  |  Size: 894 B

After

Width:  |  Height:  |  Size: 894 B

View File

Before

Width:  |  Height:  |  Size: 2.5 KiB

After

Width:  |  Height:  |  Size: 2.5 KiB

View File

Before

Width:  |  Height:  |  Size: 3.2 KiB

After

Width:  |  Height:  |  Size: 3.2 KiB

View File

Before

Width:  |  Height:  |  Size: 1.7 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

View File

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 13 KiB

View File

Before

Width:  |  Height:  |  Size: 1.8 KiB

After

Width:  |  Height:  |  Size: 1.8 KiB

BIN
images/Screenshot_01.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

BIN
images/Screenshot_02.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

BIN
images/Screenshot_03.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 43 KiB