The MASM Forum

Members Gallery => Showcase => Topic started by: jj2007 on March 08, 2024, 01:54:01 PM

Title: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: jj2007 on March 08, 2024, 01:54:01 PM
Welcome to SimpleEditor.exe, a dedicated lightweight editor for Assembly :thup:

- extract the attached SimpleEditor.zip to a folder on the same drive as your Masm32 installation
- hit F6 to build your first Windows project

Of course, to use the editor for assembling your sources, you need the Masm32 SDK (https://www.jj2007.eu/Masm32_Tips_Tricks_and_Traps.htm).

If you have also the Masm64 SDK installed (https://masm32.com/board/index.php?topic=10880.0), you may use the "B" button to assemble 64-bit SDK code.

If you have also WinInc installed (https://www.terraspace.co.uk/uasm.html#p9), preferably as [Masm32 drive]:\WinInc, you may use the "B" button to assemble 64-bit WinInc code. Make sure \Masm32\bin\uasm64.exe is present (download (http://www.terraspace.co.uk/uasm.html#p2)).

Before building the sample source WinIncGui4SE, you need to place the \WinInc\Include\UAsm64.init file attached in the second archive in its proper location. The other files can go anywhere in folder of the Masm32 drive.

You may use the attached Chinese.asm as a template for Utf8 files. Alternative, save your source in the default *.asc format, i.e. in Rich Text Format.

Feedback welcome :thup:

(http://www.jj2007.eu/pics/SimpleEd.png)

P.S., the legal stuff: use at your own risk; backup important sources.
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: jj2007 on March 08, 2024, 11:34:14 PM
Version 3 attached above, with minor improvements. Inter alia, some non-translated messages are fixed, and the Language menu got improved. In case you know some of the more exotic languages (Chinese, Japanese, Arabic), please give me feedback via PM in case something can be improved. Thanks :thup:

One important improvement: if you use a Windows build, and there is an inkey or Inkey (https://www.jj2007.eu/MasmBasicQuickReference.htm#Mb1109) somewhere in your code, you'll get a message. The reason is that waiting for a keypress in a program that has no console is a really, really bad idea :cool:
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: learn64bit on March 09, 2024, 04:47:31 AM
who care about translated messages?
I only care about:
can it input, edit, search Chinese?
but no picture show that...
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: greenozon on March 09, 2024, 06:04:17 AM
@jj2007
feature request!
could you please add the version/trademark/etc info into binary properties please?


(https://i.postimg.cc/xkJ9RQYb/Screenshot-6.jpg) (https://postimg.cc/xkJ9RQYb)
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: greenozon on March 09, 2024, 06:08:18 AM
Another report
you run SimpleEditor.exe
it opens up Open Dialog right away

you press cancel and looks like it's crashing?...
Expectations: show empty window, not close/crash...


(https://i.postimg.cc/cvJ3dvMy/Screenshot-9.jpg) (https://postimg.cc/cvJ3dvMy)
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: greenozon on March 09, 2024, 06:19:34 AM
Another feature request (or bug report?)

if you try to open Recent Locations that points to .lnk  objects, the Editor opens up .lnk instead of following to destination dir/file!

eg:


(https://i.postimg.cc/pyzVnPX9/Screenshot-6.jpg) (https://postimg.cc/pyzVnPX9)


Expectations:  .lnk are resolved to destination file objects!
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: NoCforMe on March 09, 2024, 08:13:00 AM
I don't think this is quite ready for prime time, as they say ...
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: jj2007 on March 09, 2024, 10:43:44 AM
Quote from: learn64bit on March 09, 2024, 04:47:31 AMcan it input, edit, search Chinese?
but no picture show that...

Like this (file attached)?
(http://www.jj2007.eu/pics/SimpleEdChinese.png)
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: jj2007 on March 09, 2024, 10:52:25 AM
Quote from: greenozon on March 09, 2024, 06:04:17 AMcould you please add the version/trademark/etc info into binary properties please?

Done :thumbsup:

Quote from: greenozon on March 09, 2024, 06:08:18 AMyou run SimpleEditor.exe
it opens up Open Dialog right away

you press cancel and looks like it's crashing?...
Expectations: show empty window, not close/crash...

Fixed - no more crashes, it will now simply exit.

This is a rare/unrealistic case btw: if you have the Masm32 SDK installed (and we expect all members to have it installed), SimpleEditor will open on first launch [your Masm32 drive]:\Masm32\examples\exampl01\qikpad\qikpad.asm

Quote from: greenozon on March 09, 2024, 06:19:34 AMif you try to open Recent Locations that points to .lnk  objects, the Editor opens up .lnk instead of following to destination dir/file!

Fixed :thumbsup:

Thanks, greenozon, for testing the program, and for your constructive feedback :thup:
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: learn64bit on March 09, 2024, 11:08:06 AM
create a .asm, then save it(default as 65001withoutBOM), open it
(https://i.postimg.cc/YhLGYFsM/1.jpg) (https://postimg.cc/YhLGYFsM)

(https://i.postimg.cc/68s70QkR/2.jpg) (https://postimg.cc/68s70QkR)

(https://i.postimg.cc/S2437cr5/3.jpg) (https://postimg.cc/S2437cr5)
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: jj2007 on March 09, 2024, 11:19:05 AM
Quote from: learn64bit on March 09, 2024, 11:08:06 AMcreate a .asm, then save it, open it

- load the WinIncGui4SE.asc attached to reply #7
- click the new file item, and choose a new name
- edit and save

Requires version 5 attached in the top post.

Thanks for your feedback, learn64bit - you made me discover a bug with the "save nonetheless" logic (SimpleEditor warns you if the edited text is shorter than the original text).
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: learn64bit on March 09, 2024, 11:27:11 AM
ansi?? not utf8?
(https://i.postimg.cc/RWKz7CmW/4.jpg) (https://postimg.cc/RWKz7CmW)
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: jj2007 on March 09, 2024, 12:47:34 PM
Quote from: learn64bit on March 09, 2024, 11:27:11 AMansi?? not utf8?

The original file must already be in Utf8 or rtf/asc format - see attachment Chinese.zip on top of this post. You may call that a bug or a missing feature ;-)
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: greenozon on March 10, 2024, 12:46:36 AM
More questions, Unicode related
used latest build 5
BTW< thanks for embedding version info into exe!

1) I'm very impressed by Chinese symbols support
2) emoji are supported as well, but for some reason they are invisible
you have to select it in order to start seeing it...
eg:


(https://i.postimg.cc/YhqWVyb8/Screenshot-6.jpg) (https://postimg.cc/YhqWVyb8)
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: jj2007 on March 10, 2024, 05:57:53 AM
Quote from: greenozon on March 10, 2024, 12:46:36 AM2) emoji are supported as well, but for some reason they are invisible

I strongly suggest you use the rtf/asc format for emojis.
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: greenozon on March 10, 2024, 07:50:50 PM
Could you elaborate on the above statement a bit more?
do you mean editor does not support all Unicode code planes like emojies/country flags/etc?
Title: Re: A simple editor for the Masm32 and Masm64 SDKs and the UAsm/JWasm WinInc package
Post by: jj2007 on March 10, 2024, 08:51:47 PM
Quote from: jj2007 on March 10, 2024, 05:57:53 AMI strongly suggest you use the rtf/asc format for emojis.

The point is that a plain text RichText Unicode control can handle emojis; however, you would need to set a specific font to achieve that, and this font might not be the best for general coding.

If you use the same RichEdit control in rtf mode, it will "remember" what font you used for the emojis, not for the rest of the text. That is easier to handle; for example, another user may have set his SimpleEditor (or any other editor) to use plain Arial: no luck with your source. If you had saved it as rtf or asc, the editor on the other machine (SimpleEditor, WordPad, MS Word, ... many understand rtf) will have no problems to display the emojis.

I hope that was clear enough; let me know if not. I have abandoned plain text asm many years ago, and never regretted switching to Rich Text Format.