NO

Author Topic: myEditor  (Read 9684 times)

Grincheux

  • Guest
myEditor
« on: January 09, 2020, 05:54:42 PM »
This editori is not again really finished, ther is always something to add or to improve.
It works!
It is able to generate project, to build them and to compile a source file (asm and C only).
I don't use the process error code because when there is no error in a source file, but many warnings, the compiler returns the same exit code like there is no warnings.
You can create your own compiler command lines. By default there is a compiler named... PellesC
This program is not a IDE and does not want to be it, it just is a text editor with some project capabilities.
The project is stored into a ".Prj" file that looks like an "ini" file.
When a project (*.prj) is opened it creates a sqlite database. When the project is modified the database is rebuilt.
When the database is created, a ".Cmd" file is created. It contains all the commands for compiling and linking.
The file also thest the errorlevel variable.
At compile time, only the first 65536 bytes are recorded. The max is 204800 bytes... MS dixit.
It is available for downloading (source code and executables...) here

Things I will add :
- Find strings in files
- Search & Replace using RegEx...

Added :
- Now you can insert a GUUID
- When a windows or a SQLite function is selected, by pressing F2 you can see the parameters on the statusbar.
« Last Edit: January 12, 2020, 04:59:57 AM by Grincheux »

Grincheux

  • Guest
Re: myEditor
« Reply #1 on: January 26, 2020, 08:31:56 PM »
I don't want to plagiarize from some text editor. I pick up ideas on the right and on the left, that's all. When you make a program you have to stand out from the others, so I introduced batch processing. Later there will be the possibility of adding a hash (MD5, SHA3 ...). I try to invent utilities for programmers and for those who have to prepare databases.

I have many ideas but not a lot of time.

I am creating a help file too.

When there are significants changes in the sources files I update the site on
MediaFire

If some people tested the program telle me the bugs you find.

Thank You
« Last Edit: January 26, 2020, 08:37:21 PM by Grincheux »

Offline jj2007

  • Member
  • *
  • Posts: 536
Re: myEditor
« Reply #2 on: January 28, 2020, 11:43:41 PM »
When launching E++.exe, it tells me "not enough memory for this operation", and then it crashes with an exception. This is Windows 7-64.

Online AlexN

  • Global Moderator
  • Member
  • *****
  • Posts: 394
    • Alex's Link Sammlung
Re: myEditor
« Reply #3 on: January 29, 2020, 09:31:05 AM »
When launching E++.exe, it tells me "not enough memory for this operation", and then it crashes with an exception. This is Windows 7-64.
I had the same problem and found that E++ tries to open a recent not existing file. Look at E++.ini and delete there all recent files.
best regards
 Alex ;)

Offline jj2007

  • Member
  • *
  • Posts: 536
Re: myEditor
« Reply #4 on: January 31, 2020, 11:26:55 AM »
No luck, Alex. It still crashes >:(

Offline John Z

  • Member
  • *
  • Posts: 860
Re: myEditor
« Reply #5 on: January 31, 2020, 11:06:57 PM »
Two inputs, just downloaded and tried it.  It crashes with the error above on Windows 10 64 bit as well. Error is as mentioned "Not enough memory for this operation".  Deleted the INI file then another error.  IMO if there is not an INI file the program should automatically create a minimum clean empty one, not crash....so that is a possible improvement.
Troubleshooting :
Deleted all entries under [Recent Files] does not help.
Deleted all entries under [User tools] does not help.
Deleted all entries under [System Tools] does not help.
These are the culprits and the danger of providing a 'used' ini rather than a fresh clean one
Load Last Project=1
Load Last File=1
Last Project=C:\Users\Philippe\Documents\Pelles C Projects\E++\E++.prj
Last File=C:\Users\Philippe\Documents\Pelles C Projects\E++\E++.c

In particular change Load Last File=0 and the program will not crash.

For autoloading items the technique I use to prevent this situation is to ignore auto loading if the last program start-up crashed.  I handle this by writing to the ini file a value of crash=true before opening and loading a file then if it was a success write to the ini file crash=false.  On startup check the crash flag if set to crash=true don't load the last file.

Regarding Batch Processing in an editor: I use WildEdit, and use TextPad for most things.  However they are not free.
https://www.textpad.com/

Hope this is helpful, Regards,
John



Offline John Z

  • Member
  • *
  • Posts: 860
Re: myEditor
« Reply #6 on: February 01, 2020, 12:51:55 AM »
Some inputs for you other than my  post above.

If some people tested the program telle me the bugs you find.

Thank You

Understanding without documentation sometimes there are misunderstandings ….. here are some inputs:

1) Under temp I see many log files. When the program was crashing nothing indicating that the crash happened, or what error message were displayed, or any reason were written to the log files.  This seems to be an oversight.  Also how many log files will there be, and is there a mechanism to clean out the files? Already have 16 of them.

2) It is inconvenient to always need to resize the editor window, keeping it from using the full screen, every time it is started. Can you store the last used window size and position and use that for the startup?

3) The two language files are not in synch. [File.Filters] in particular.
   [Dialogs.Batch.Cmds] in French has double entries for the same id number #6, and #7
   [Menus.Titles] in English has double entries for the same id number #7
   [Menu.Tools] in English has French for item #1
   
4) Tool tips show three icons with the same tip "First", the light bulb, the gear and checkmark.  The bulb brings up the CPU information, the gear does nothing, and also the globe icon and checkmark does nothing that I could figure out. The checkmark icon does change when using lock origin and unlock origin but nothing seems to change in the document or cursor positioning.

5) First and Last toolbar icons actually execute Next and Previous, while the Next and Previous icons don't do anything.

6) Using Find box - each letter I type in was quadrupled "log" became "lllloooogggg".  When I carefully backspaced out the extra characters and searched, I'm not sure what it is highlighting - much more than the word...
   Screen shots taken.
   
7) Using "Replace" the letters also quadrupled.  Backspace technique did not work fixing the word.  Could never get just "log"
   screen shot taken.
   
Maybe when the help file is complete more things will become clear.
This was all done on a Windows 10 64 bit system version 1903, with a just downloaded copy of the program, which btw I could not find any version information to report back from within the program but the file information shows 0.0.0.6222 489K modified date 1/28/2020 3:26PM

Hope this is useful to you.

Regards,
John  (Jean en Français)  :)

Offline jj2007

  • Member
  • *
  • Posts: 536
Re: myEditor
« Reply #7 on: February 01, 2020, 06:05:19 AM »
Load Last File=0 made the difference, thanks John.

The find box has a weird bug, every character you type appears 4x

Offline John Z

  • Member
  • *
  • Posts: 860
Re: myEditor
« Reply #8 on: February 02, 2020, 05:12:07 AM »
I hesitate to add more tests results for fear that without the documentation
I do not understand the features.  I'll add these for now:

Edit - Go To ...
  Go to Column is selecting from line start to N rather than just moving the cursor
  Go to Line is going to the line number then selecting the entire line
  [ just fyi - dialog boxes are in French ]
  In my experience Go To just moves a cursor not performs a selection.
 
 
Columns - English has French for 'insert a column'
 I'm not able to figure out how the Columns - items are really supposed to work.
 I've not been able to select just a column, even if selecting one character the
 'change' affects much more than a column.  Screen shots attached,
 

Selection - Lowercase and Uppercase have some issue.
Attached screen shots show an example.

Regards,
John

Some of the screen shots will be fuzzy trying to fit all into the
1 Meg upload limit.

Offline jj2007

  • Member
  • *
  • Posts: 536
Re: myEditor
« Reply #9 on: February 03, 2020, 01:34:51 AM »
Edit menu:
- Find box: typing impossible
- Find box: if you insert a string using the right-click menu,
  a) it gets inserted twice in the main text
  b) it doesn't get found
- Delete: doesn't work in the first line
- Clear: inserts spaces (??)

Selection menu:
- reverse: funny but it works
- check an expression: always returns "no syntax error found"
- lowercase, uppercase: inserts random extra characters
- Clear: inserts one random extra character
- Delete: compliments, it seems to work as it should!
- same for Translate to Morse

Columns menu:
- Lowercase: dangerous, don't use
- insert a column, Insert a number: ditto, destroys the text with only a few lines of undo

Lines menu:
- Delete until the end of line: inserts random characters or "?" before the insertion point
- Go to the first/last line: shows the first/last line, but when typing, the cursor is still at the same position

Inserts menu:
- insert a comma: does exactly that, in all lines of the document. Not enough undo, of course.
- Insert a new line: doesn't insert a line but prepends "®" to all lines in the doc
- Insert Date, Time, Guid: works!

Mode menu:
- lowercase: disables the Shift key and all typing is lowercase
- uppercase: disables the Shift key and all typing is uppercase

Close button: "Do you want to save changes?"->Cancel: closes instead of staying open.

Conclusion: dangerous, don't use

Offline John Z

  • Member
  • *
  • Posts: 860
Re: myEditor
« Reply #10 on: February 03, 2020, 10:50:24 PM »
Good summary,  there are more issues as well, but this is more than enough to get started on. However one other item is very  concerning.  I do not know the sequence that caused this (several times) but all System Tools and User Tools disappear. Fortunately I had made a copy of the INI to easily restore and continue testing.

John

Grincheux

  • Guest
Re: myEditor
« Reply #11 on: February 09, 2020, 04:21:56 AM »
Thank you for all the answers. I am correcting bugs. I will make an update asap.
The last version is here.
I am writing a documentation too.
I have added the possibility to run many commands. It is not finished. I am working on the possibility to add a hash. I made this because sqlite does not permit to compute a MD5. This option is buggee. The hash possibility is the last option I add.
The batch utility (from Edit/Batch Commands) is tested on a fixed length file of 4097 records, and on a C source file of 300 lines.
I do efforts mainly on the fixed length files because we also have to prepare datas files when writing a program.
For the instant the help file is in French, but I will translate it in English.
With all of your remarks I have many work but I like thanks again.
« Last Edit: February 09, 2020, 04:37:12 AM by Grincheux »

Offline John Z

  • Member
  • *
  • Posts: 860
Re: myEditor
« Reply #12 on: February 09, 2020, 08:33:11 AM »
You are welcome.  Will watch this thread for a new good version to test.  The "last version" link mentioned above provides a version that still crashes upon startup so I'm sure not all of your fixes are in place yet. : -)

Regards,
John

Grincheux

  • Guest
Re: myEditor
« Reply #13 on: February 09, 2020, 09:53:26 AM »
OK :-[

Grincheux

  • Guest
Re: myEditor
« Reply #14 on: February 10, 2020, 01:08:38 PM »
 :) :) :) First of all I would thank the members who test my program. When I write it there many things I don't see (or don't want to see...).

I made some changes and I will give you some help (I hope).


Download binaries and source files from http://www.mediafire.com/folder/ofyulrxut5g17/Editor

Quote
Some files

E++.pfi is a Photofiltre file containing the toolbar icons. http://www.photofiltre-studio.com/pf7.htm
E++.gde is my todo list. http://theguide.sourceforge.net/
E++.hnd is the file used to create the help file. https://www.helpndoc.com/
sqlite3.lib is from https://www.sqlite.org/index.html
E++.ini is the program profile file.
E++.bmp is used when compiling E++.rc

*.db3 can be modified/viewed using http://www.sqliteexpert.com/download.html

-------------------------------------------
The following folders must always exist :

1-Compilers
2-Databases
3-Languages

All the others can be deleted. If the program need them it will create the folder.

The "MakeSqlite3" contains utilities to create a lib file from sqlite.def when
downloaded from sqlite.org

POLIB /DEF:sqlite3.def /MACHINE:X64 /OUT:sqlite3.lib /VERBOSE>sqlite3_make_lib.Out
-------------------------------------------
Compilers folder
-----------

Into it there is a text file "PellesC.cmp" It defines the rules for the compiler.
-------------------------------------------
Databases folder
-----------

It contains too sqlite databases: Function.db3 and Windows.db3

Function.db3
-----------

It is used by the match process. It contains :
1-the name of the function,
2-the command number
3-The number of arguments for each dialog boxes

Don't modify

Windows.db3
-----------

Contains three tables : CRT, SQLITE and WIN32
Each of them have three columns : NumRec, Function, Desription.
Don't modify
-------------------------------------------
Languages Folder
-----------

Contains the text files used for translation.
Can be modified/
-------------------------------------------

Log files removed
-------------------------------------------
Bugs corrected to :
-Edit/Delete and Edit/Clear The characters must be selected.
-Edit/Replace has been rewriten. Acts like in the batch command. Replace from Top.
-Edit/Find and Edit/Next not modified yet.
-Edit/Goto... Not modified again. Goto Lines goes one line too far.
-Edit/Batch commands. Not already finished but many commands are working.
-Menu Columns/All has been corrected
-Menu Lines/All has been corrected except "Goto"

-------------------------------------------
Toolbar
The icons for First and Last are available when 3 files/documents minimum are opened.
But they don't do what I expect. !!!

-------------------------------------------
Keyboard:F2
Select a windows or a SQLite function, press F2 and you get the syntax on the statusbar.
In fact I took Pelle's tag file and added SQLite functions.

-------------------------------------------
Check an Expression
Only verify [], () and {}

-------------------------------------------
Insert Menu
I created it because it takes a long time to transform a text into a CSV file.
-------------------------------------------
Read Only mode.
I created it because very often my cats are playing with my keyboard.
What they do in my opened source files is WRONG... When I select
this mode, they can do what they want they don't modify anything.
You can see this mode with the last toolbar icon. The cadenas will remove this mode.

Tooltips after "Insert Date" are wrong, not corrected yet.
-------------------------------------------
Added a header in language files and profile file

[Author]
Author=Philippe RIO
Allias=Grincheux / Jokaste
Country=France
City=Mathenay, Jura
Version=0.0.0.7423
Software Key=54F05988DD290BBD438CFBA2D0C1B64EC0547205DBA13A1206A38B59
Translation=English

This will help me to check if the files are uptodate
The [Software Key] will have to be the same.
-------------------------------------------
To do ASAP
----------
Find & Find Next
Save main window position and size
Clean Project Options
GOTO takes a line too far
- Go to the first/last line: shows the first/last line, but when typing, the cursor is still at the same position
Close button: "Do you want to save changes?"->Cancel: closes instead of staying open.
Add bookmarks
Save files before Build and Compile
-------------------------------------------
« Last Edit: February 10, 2020, 01:16:57 PM by Grincheux »