Author Topic: Editor for testing.  (Read 2884 times)

hutch--

  • Administrator
  • Member
  • ******
  • Posts: 5852
  • Mnemonic Driven API Grinder
    • The MASM32 SDK
Editor for testing.
« on: December 04, 2016, 06:12:29 PM »
Could I impose on some of our members to run some simple tests on this editor. What I am aiming at is a base editor that does the basic stuff like loading and saving files, search and replace and with the correct confirmation for load and save operations. The target is a template generator so that a base editor can be written as a project quickly that saves you from having to do the hacky stuff so you can write your own custom versions of a rich text editor.

I have added the search and replace dialogs and code and seem to have the file IO confirmations done so they work OK. Since I have worked on it on and off for the last weeks or so, its possible that I may have missed something in terms of reliability, even though its test up OK at the moment.
hutch at movsd dot com
http://www.masm32.com    :biggrin:  :biggrin:

jj2007

  • Member
  • *****
  • Posts: 8776
  • Assembler is fun ;-)
    • MasmBasic
Re: Editor for testing.
« Reply #1 on: December 04, 2016, 09:26:10 PM »
Seems to work fine on Win7-64, Hutch. A lot of pretty basic things are missing, though, such as a filter for txt, doc, asm, inc in the file open dialog. Or a recent files list :P

MichaelW

  • Global Moderator
  • Member
  • *****
  • Posts: 1209
Re: Editor for testing.
« Reply #2 on: December 05, 2016, 12:21:21 PM »
It seems to work fine on my Windows 10 notebook, but with a 15.6" screen at its native resolution of 1366x768, your font selection, and white characters on a dark background, the characters are not easy for me to read. I do better with black characters on a white background.



Well Microsoft, here’s another nice mess you’ve gotten us into.

hutch--

  • Administrator
  • Member
  • ******
  • Posts: 5852
  • Mnemonic Driven API Grinder
    • The MASM32 SDK
Re: Editor for testing.
« Reply #3 on: December 05, 2016, 02:12:19 PM »
Thanks Michael and JJ, both colours are adjustable with a single COLORREF value. As far as file filters on open and save, its only a single line of code to change that and that is better left to the person doing the tweak. MRU lists are fine on a single instance application but close enough to impossible with a multi-instance tool. You would have to have a separate list display to try and keep track of them and with multiple instances it could become long and messy.
hutch at movsd dot com
http://www.masm32.com    :biggrin:  :biggrin:

jj2007

  • Member
  • *****
  • Posts: 8776
  • Assembler is fun ;-)
    • MasmBasic
Re: Editor for testing.
« Reply #4 on: December 05, 2016, 10:22:42 PM »
MRU lists are fine on a single instance application but close enough to impossible with a multi-instance tool. You would have to have a separate list display to try and keep track of them and with multiple instances it could become long and messy.

RichMasm writes the file list to disk whenever user changes a word in the current doc. When looking at the MRU, any RichMasm instance picks the list from disk and rebuilds the menu. Works 100% flawlessly.

hutch--

  • Administrator
  • Member
  • ******
  • Posts: 5852
  • Mnemonic Driven API Grinder
    • The MASM32 SDK
Re: Editor for testing.
« Reply #5 on: December 05, 2016, 11:19:26 PM »
If I was going to implement this in a multi-instance editor it would be a separate list that is added from the top after removing duplicates so that you did not have multiple copies of the same file name. Now the problem is it would end up being a very long list just through the normal rate of opening and closing files so you would have to create a cut off list length. The next thing would be that the list would have to be updated live over every open instance of the editor.

I can be done but there is no way I would write a mess like this. When I have the template finished so it can be routinely used, anyone who wants to make a mess like this is welcome to do what they like but there is no way I would touch it with a barge pole. I am reasonably happy with an editor that opens, creates and saves files with the correct confirmation and the search and replace working as it saves messy coding on a repeat basis. I still have some of the hot keys to menu items to do on it and a few tweaks here and there but its close to what I want as the end result. The font is currently set at Fixedsys so I should add an option to change it, "Consolas" reads and looks OK and is scalable so having the option of setting different fonts available in the source code makes sense.

It has all of the adjustments needed to change the toolbar sizes (once you supply a new image strip) so it can be made to look like whatever the author wants.
hutch at movsd dot com
http://www.masm32.com    :biggrin:  :biggrin:

jj2007

  • Member
  • *****
  • Posts: 8776
  • Assembler is fun ;-)
    • MasmBasic
Re: Editor for testing.
« Reply #6 on: December 05, 2016, 11:39:49 PM »
If I was going to implement this in a multi-instance editor it would be a separate list that is added from the top after removing duplicates so that you did not have multiple copies of the same file name. Now the problem is it would end up being a very long list just through the normal rate of opening and closing files so you would have to create a cut off list length. The next thing would be that the list would have to be updated live over every open instance of the editor.

Exactly :t

I have been using that system on a daily basis for a decade now, and it works perfectly - latest version always on top, no risk of opening an obsolete version, etc ;-)

Quote
a very long list just through the normal rate of opening and closing files
I adjust the list only if the user edits the source. So just opening a file to have a look won't update the MRU.

Below a screenshot. The extra info on time stamps is added only if user holds Shift while hovering over the file menu.
« Last Edit: December 06, 2016, 03:00:05 AM by jj2007 »

caballero

  • Member
  • *****
  • Posts: 1089
    • abre ojos ensamblador
Re: Editor for testing.
« Reply #7 on: December 05, 2016, 11:50:00 PM »
It works fine here, W7-64bits
En un lugar de la Mancha de cuyo nombre no quiero acordarme

- There are 10 kind of people: those who know binary numbers and those who don't -

ragdog

  • Member
  • ****
  • Posts: 572
Re: Editor for testing.
« Reply #8 on: December 09, 2016, 11:51:00 PM »
Works good i cannot found bugs. :t

hutch--

  • Administrator
  • Member
  • ******
  • Posts: 5852
  • Mnemonic Driven API Grinder
    • The MASM32 SDK
Re: Editor for testing.
« Reply #9 on: December 10, 2016, 12:58:22 AM »
Thanks guys, the testing is very useful.  :t
hutch at movsd dot com
http://www.masm32.com    :biggrin:  :biggrin: