TODO features:
Application: V Export comments now respects "Code in Hex" checkbox on the main form Bugs: V Frame modified flag persists when switching to another frame after rejected to save previous frame V Ctrl-C, Ctrl-V doesn't work in the Note editbox because it tries to copy/paste the frame! V Post "Backslash" instead of \ in comments
This commit is contained in:
@@ -233,7 +233,12 @@ namespace McBitFont {
|
||||
if (com && lines != 1 && fcount > 1) {
|
||||
// Comments enabled and other than "1 symbol per line" selected
|
||||
// Print a symbol comment before its data
|
||||
output += " // " + f.code.ToString() + " --> " + mainForm.DecodeSymbol(f.code);
|
||||
string character = f.code switch {
|
||||
92 => "Backslash",
|
||||
_ => mainForm.DecodeSymbol(f.code),
|
||||
};
|
||||
string code = mainForm.chkHexCodes.Checked ? "0x" + Convert.ToString(f.code, 16).PadLeft(2, '0').ToUpper() : f.code.ToString();
|
||||
output += " // " + code + " --> " + character;
|
||||
if (f.note != "" && f.note != null) output += " (" + f.note.ToString() + ")";
|
||||
output += "\n";
|
||||
}
|
||||
@@ -371,7 +376,12 @@ namespace McBitFont {
|
||||
if (!f.Equals(flast) && f.width > 0) output += ",";
|
||||
if (com && fcount > 1) {
|
||||
//...with a comment
|
||||
output += " // " + f.code.ToString() + " --> " + mainForm.DecodeSymbol(f.code);
|
||||
string character = f.code switch {
|
||||
92 => "Backslash",
|
||||
_ => mainForm.DecodeSymbol(f.code),
|
||||
};
|
||||
string code = mainForm.chkHexCodes.Checked ? "0x" + Convert.ToString(f.code, 16).PadLeft(2, '0').ToUpper() : f.code.ToString();
|
||||
output += " // " + code + " --> " + character;
|
||||
if (f.note != "" && f.note != null) output += " (" + f.note.ToString() + ")";
|
||||
}
|
||||
output += "\n";
|
||||
|
10
McBitFont/Form1.Designer.cs
generated
10
McBitFont/Form1.Designer.cs
generated
@@ -1216,13 +1216,13 @@
|
||||
//
|
||||
cmBaseline.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { tsmiTopline, tsmiMidline, tsmiBaseline });
|
||||
cmBaseline.Name = "cmBaseline";
|
||||
cmBaseline.Size = new System.Drawing.Size(181, 92);
|
||||
cmBaseline.Size = new System.Drawing.Size(121, 70);
|
||||
//
|
||||
// tsmiTopline
|
||||
//
|
||||
tsmiTopline.Image = Properties.Resources.fam_top;
|
||||
tsmiTopline.Name = "tsmiTopline";
|
||||
tsmiTopline.Size = new System.Drawing.Size(180, 22);
|
||||
tsmiTopline.Size = new System.Drawing.Size(120, 22);
|
||||
tsmiTopline.Text = "Top line";
|
||||
tsmiTopline.ToolTipText = "Set top base line";
|
||||
tsmiTopline.Click += tsmiTopline_Click;
|
||||
@@ -1231,7 +1231,7 @@
|
||||
//
|
||||
tsmiMidline.Image = Properties.Resources.fam_mid;
|
||||
tsmiMidline.Name = "tsmiMidline";
|
||||
tsmiMidline.Size = new System.Drawing.Size(180, 22);
|
||||
tsmiMidline.Size = new System.Drawing.Size(120, 22);
|
||||
tsmiMidline.Text = "Mid line";
|
||||
tsmiMidline.ToolTipText = "Set middle base line";
|
||||
tsmiMidline.Click += tsmiMidline_Click;
|
||||
@@ -1240,7 +1240,7 @@
|
||||
//
|
||||
tsmiBaseline.Image = Properties.Resources.fam_base;
|
||||
tsmiBaseline.Name = "tsmiBaseline";
|
||||
tsmiBaseline.Size = new System.Drawing.Size(180, 22);
|
||||
tsmiBaseline.Size = new System.Drawing.Size(120, 22);
|
||||
tsmiBaseline.Text = "Base line";
|
||||
tsmiBaseline.ToolTipText = "Set bottom (base) line";
|
||||
tsmiBaseline.Click += tsmiBaseline_Click;
|
||||
@@ -1358,7 +1358,6 @@
|
||||
private System.Windows.Forms.ToolStripMenuItem tsmiMakeVarWidth;
|
||||
private System.Windows.Forms.ToolStripMenuItem importImageToolStripMenuItem;
|
||||
private System.Windows.Forms.Label label3;
|
||||
private System.Windows.Forms.CheckBox chkHexCodes;
|
||||
private System.Windows.Forms.Button btnFill;
|
||||
private System.Windows.Forms.ToolStripMenuItem FillToolStripMenuItem;
|
||||
private System.Windows.Forms.CheckBox chkRectSelect;
|
||||
@@ -1393,6 +1392,7 @@
|
||||
private System.Windows.Forms.ToolStripMenuItem tsmiBaseline;
|
||||
private System.Windows.Forms.ToolStripMenuItem tsmiMidline;
|
||||
private System.Windows.Forms.ToolStripMenuItem tsmiTopline;
|
||||
public System.Windows.Forms.CheckBox chkHexCodes;
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -63,7 +63,6 @@ namespace McBitFont {
|
||||
|
||||
public FrameMiniature f;
|
||||
public List<FrameMiniature> frames = new List<FrameMiniature>();
|
||||
//private CanvasHistory history = new();
|
||||
private ChangeHistory history;
|
||||
private int cellSize = 10;
|
||||
public int dotWidth, dotHeight;
|
||||
@@ -73,7 +72,7 @@ namespace McBitFont {
|
||||
public bool monospaced = false;
|
||||
private bool modified = false;
|
||||
private bool prjModified = false;
|
||||
public const string version = "2.9";
|
||||
public const string version = "2.10";
|
||||
public string prjName = "Untitled";
|
||||
public string prjFileName = "";
|
||||
public int codepage = 1251;
|
||||
@@ -83,6 +82,7 @@ namespace McBitFont {
|
||||
private SetLines set_lines = SetLines.SL_None;
|
||||
private Point selection1, selection2;
|
||||
private Point[,] sidebarLocs = new Point[2, 3];
|
||||
private bool frameClipboard = false;
|
||||
|
||||
|
||||
public MainForm() {
|
||||
@@ -475,6 +475,9 @@ namespace McBitFont {
|
||||
var rectSel = chkRectSelect.Checked;
|
||||
bool rectSelUpdated = false;
|
||||
|
||||
// Set input focus to minilist if any mouse button is held
|
||||
if (!miniList.Focused && e.Button != MouseButtons.None) miniList.Focus();
|
||||
|
||||
// Drag with middle mouse button
|
||||
if (vScroll.Enabled || hScroll.Enabled) {
|
||||
if (mouseDownMiddle) {
|
||||
@@ -1182,12 +1185,22 @@ namespace McBitFont {
|
||||
}
|
||||
|
||||
private void copyToolStripMenuItem_Click(object sender, EventArgs e) {
|
||||
if (tbFrameNote.Focused) {
|
||||
tbFrameNote.Copy();
|
||||
frameClipboard = false;
|
||||
} else {
|
||||
var bb = MessagePackSerializer.Serialize(CopyFrame(f, true));
|
||||
DataObject clpbObj = new DataObject(clpbFormat.Name, bb);
|
||||
Clipboard.SetDataObject(clpbObj, true);
|
||||
frameClipboard = true;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private void pasteToolStripMenuItem_Click(object sender, EventArgs e) {
|
||||
if (tbFrameNote.Focused) {
|
||||
if (!frameClipboard) tbFrameNote.Paste();
|
||||
} else if (frameClipboard) {
|
||||
// Try to read from clipboard
|
||||
try {
|
||||
IDataObject clpbObj = Clipboard.GetDataObject();
|
||||
@@ -1224,6 +1237,7 @@ namespace McBitFont {
|
||||
dotPanel.Refresh();
|
||||
SetModified();
|
||||
}
|
||||
}
|
||||
|
||||
private void aboutToolStripMenuItem_Click(object sender, EventArgs e) {
|
||||
About form = new About();
|
||||
@@ -1239,8 +1253,8 @@ namespace McBitFont {
|
||||
if (modified) {
|
||||
if (MessageBox.Show("Current symbol is modified.\nDo you want to save the changes?", "Symbol was modified!", MessageBoxButtons.YesNo) == DialogResult.Yes) {
|
||||
SaveFrame();
|
||||
SetModified(false);
|
||||
}
|
||||
SetModified(false);
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -20,9 +20,9 @@
|
||||
<UseWindowsForms>true</UseWindowsForms>
|
||||
<ImportWindowsDesktopTargets>true</ImportWindowsDesktopTargets>
|
||||
<ApplicationIcon>icon_64.ico</ApplicationIcon>
|
||||
<AssemblyVersion>2.9.0.0</AssemblyVersion>
|
||||
<FileVersion>2.9.0.0</FileVersion>
|
||||
<Version>$(VersionPrefix)2.9.0</Version>
|
||||
<AssemblyVersion>2.10.0.0</AssemblyVersion>
|
||||
<FileVersion>2.10.0.0</FileVersion>
|
||||
<Version>$(VersionPrefix)2.10.0</Version>
|
||||
<Copyright>Anton Mukhin</Copyright>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
|
||||
|
8
TODO.txt
8
TODO.txt
@@ -1,11 +1,11 @@
|
||||
Application:
|
||||
- Consider migrating to WPF in order to make DPI aware UI
|
||||
|
||||
V Export comments now respects "Code in Hex" checkbox on the main form
|
||||
|
||||
Functionality:
|
||||
|
||||
|
||||
Bugs:
|
||||
- Frame modified flag persists when switching to another frame after rejected to save previous frame
|
||||
- Ctrl-C, Ctrl-V doesn't work in the Note editbox because it tries to copy/paste the frame!
|
||||
- Post "Backslash" instead of \ in comments
|
||||
V Frame modified flag persists when switching to another frame after rejected to save previous frame
|
||||
V Ctrl-C, Ctrl-V doesn't work in the Note editbox because it tries to copy/paste the frame!
|
||||
V Post "Backslash" instead of \ in comments
|
Reference in New Issue
Block a user