I'm using the source code for the open-source Thompson-Davis Editor http://adoxa.altervista.org/tde/, "a simple, public domain, multi-file, multi-window binary and text file editor written for IBM PCs and close compatibles running DOS, Win32 (console) or Linux" to learn C and curses programming. You may have noticed its coincidental acronym :-) and yes, it stores it's configuration information in $TDEHOME. TDE is small but non-trivial, and I think it will be a good resource for someone like me, who is attempting to get a grip on programming in the *nix environment; it's not so big as to be overwhelming, yet not as useless as HelloWorld.c. Thoughts?
Leslie
Leslie Turriff wrote:
Thoughts?
It looks like my editor of choice "ne". I am not sure it can do syntax highlighting, but it is great for the console. For coding I like Eclipse more. I tried kdevelop, but unfortunately it was too broken in some cases, so that I gave up on it.
regards
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA512
On 2018/06/10 04:12 PM, deloptes wrote:
I tried kdevelop, but unfortunately it was too broken in some cases, so that I gave up on it.
Strange, it works here. Perhaps you want to give it a second chance? Cheers Michele
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA512
On 2018/06/10 11:25 PM, deloptes wrote:
Michele Calgaro wrote:
Strange, it works here. Perhaps you want to give it a second chance?
c++ works well, but php is broken. perl I don't know.
Are you actively using it?
regards
I use it sometimes, not all the time. never used php there though. Why don't you file a bug report, unless you have already? Cheers Michele
Michele Calgaro wrote:
I use it sometimes, not all the time. never used php there though. Why don't you file a bug report, unless you have already?
I did long time ago, before I went for eclipse. I went for eclipse because I used it already for other projects. I am also not very happy with eclipse handling c++ - I guess I have to do fine tuning there, but if you say I should give TDevelop another chance, I will follow your advise. You are wise man.
regards
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA512
I am also not very happy with eclipse handling c++ - I guess I have to do fine tuning there, but if you say I should give TDevelop another chance, I will follow your advise. You are wise man.
Most of time I use vim/neovim/kate or even a simple text editor to write code. TDevelop helps when looking at code made by others, but I use TDEFileReplace (R14.1, not R14.0) more and more for that, really good tool. The more powerful your IDE is, the less you tend to learn, because the IDE do a lot of things for you ;-) Cheers Michele
PS: Kate session panel as for R14.1 (not in R14.0) let you quickly work on many bugs at the same time, switching is just a click of the mouse
On Monday 11 June 2018 06:02:35 Michele Calgaro wrote:
I am also not very happy with eclipse handling c++ - I guess I have to do fine tuning there, but if you say I should give TDevelop another chance, I will follow your advise. You are wise man.
Most of time I use vim/neovim/kate or even a simple text editor to write code. TDevelop helps when looking at code made by others, but I use TDEFileReplace (R14.1, not R14.0) more and more for that, really good tool. The more powerful your IDE is, the less you tend to learn, because the IDE do a lot of things for you ;-) Cheers Michele
PS: Kate session panel as for R14.1 (not in R14.0) let you quickly work on many bugs at the same time, switching is just a click of the mouse
This I take it is similar to geany, which helpfully (not) opens the last 2 dozen files its looked at. With todays mice being way the hell and gone too sensitive, this is not quite what I'd call helpful. It might be handy when working on a big project, but it also gets in the way much of the time by changing tabs with insufficient notice to the user. Geany is an otherwise good editor, unlike gedit which has played mix & miss-match with important configuration files enough times I have banned it from the premises.
To unsubscribe, e-mail: trinity-users-unsubscribe@lists.pearsoncomputing.net For additional commands, e-mail: trinity-users-help@lists.pearsoncomputing.net Read list messages on the web archive: http://trinity-users.pearsoncomputing.net/ Please remember not to top-post: http://trinity.pearsoncomputing.net/mailing_lists/#top-posting
On 06/11/2018 06:27 AM, Gene Heskett wrote:
This I take it is similar to geany, which helpfully (not) opens the last 2 dozen files its looked at. With todays mice being way the hell and gone too sensitive, this is not quite what I'd call helpful. It might be handy when working on a big project, but it also gets in the way much of the time by changing tabs with insufficient notice to the user. Geany is an otherwise good editor, unlike gedit which has played mix & miss-match with important configuration files enough times I have banned it from the premises.
Edit->preferences->[Startup tab]
Startup [ ] Load files from the last sessions
(disable it...)
On 06/09/2018 10:16 PM, Leslie Turriff wrote:
I'm using the source code for the open-source Thompson-Davis Editor http://adoxa.altervista.org/tde/, "a simple, public domain, multi-file, multi-window binary and text file editor written for IBM PCs and close compatibles running DOS, Win32 (console) or Linux" to learn C and curses programming. You may have noticed its coincidental acronym :-) and yes, it stores it's configuration information in $TDEHOME. TDE is small but non-trivial, and I think it will be a good resource for someone like me, who is attempting to get a grip on programming in the *nix environment; it's not so big as to be overwhelming, yet not as useless as HelloWorld.c. Thoughts?
Leslie
Leslie,
If you truly want to learn C, and you are looking for editors, you have two basic classes of editors you can use (both more than capable). Your choices are either traditional text-console/curses based (e.g. vim, emacs and what sounds like Thompson-Davis is), or you have your ui-toolkit based editors like kate, kwrite, geany (https://github.com/geany/geany) or codeblocks (http://www.codeblocks.org/downloads).
Of the two, I prefer the ui-toolkit based editors, but I'm at home with vim as well. In the ui category -- you really cannot do better than kate/kwrite (and if you aren't smart enough to use TDE, then a geany or codeblocks work well).
For the text/curses based class, it's a preferences thing. vim, or emacs are both incredibly capable, though I find emacs a bit heavier than vim.
Learning C is one of the best choices you can make. Nothing else (aside from assembly) provides you the complete control over hardware as C does. However, working at the hardware level comes with great responsibility. You are responsible for memory management. One-byte too few and you walk off into the realm of Undefined Behavior. Leaning C, you learn to program and will be a better programmer as a result, regardless of which language you ultimately end up writing in.
The best advice anyone can give you in learning C is simply to slow-down. C is an exact language. Understand every declaration, the proper use of each library function and for God sake validate the return of every allocation and every I/O call. You don't digest the whole library at once. When you use a library function, open the man page -- read it -- pay careful attention to all parameter type, return types and the RETURN section of the page.
(pay particular attention to the man page for the scanf family -- which provides no end of pitfall for the new C programmer who fails to learn the distinction between a *matching* and *input* failure and fails to understand that when either occur, no further characters are extracted from the input stream and are left unread -- just waiting to bite you on your next call)
When you are learning, forget an IDE, build your code on the command line so you actually learn what the compiler option are and how to correctly use them -- then you can properly use an IDE. Until you understand how to compile and link your code -- there is no way you can tell an IDE how to do it.
*Always* compile with *warnings enabled* and do not accept code until it compile cleanly, without warning. For gcc/clang that means adding -Wall -Wextra -pedantic (and I would add -Wshadow) to your command line. (clang also provides -Weverything). If you hop on a windoze box, the for VS (cl.exe) use /W3 (/Wall provides a great deal of non-code specific warnings that are a bit much).
Finally, go get an account on StackOverflow.com -- seriously. If you have a C question -- it has probably already be answered 50 times over, and the answer peer-reviewed. (the same applies for just about any language, it is a fantastic site) Before you post a question you are expected to have searched for a similar one and taken the http://stackoverflow.com/tour, visited http://stackoverflow.com/questions/how-to-ask and when posting always provide a http://stackoverflow.com/help/mcve (a minimal, complete and verifiable example -- meaning something those there can compile to verify your code behavior and help debug)
Learning C isn't something your do in a day, or a week, or month, or year -- it is a journey -- enjoy the ride.
On 10 June 2018 at 00:27, David C. Rankin drankinatty@suddenlinkmail.com wrote: <snip>
Learning C is one of the best choices you can make. Nothing else (aside from assembly) provides you the complete control over hardware as C does.
<snip>
Learning C isn't something your do in a day, or a week, or month, or year -- it is a journey -- enjoy the ride.
David, Greatly appreciated, your recommendations on how to learn C. - R
On 2018-06-10 02:27:27 David C. Rankin wrote:
On 06/09/2018 10:16 PM, Leslie Turriff wrote:
I'm using the source code for the open-source Thompson-Davis Editor http://adoxa.altervista.org/tde/, "a simple, public domain, multi-file, multi-window binary and text file editor written for IBM PCs and close compatibles running DOS, Win32 (console) or Linux" to learn C and curses programming. You may have noticed its coincidental acronym :-) and yes, it stores it's configuration information in $TDEHOME. TDE is small but non-trivial, and I think it will be a good resource for someone like me, who is attempting to get a grip on programming in the *nix environment; it's not so big as to be overwhelming, yet not as useless as HelloWorld.c. Thoughts?
Leslie
Leslie,
If you truly want to learn C, and you are looking for editors, you have two basic classes of editors you can use (both more than capable). Your choices are either traditional text-console/curses based (e.g. vim, emacs and what sounds like Thompson-Davis is), or you have your ui-toolkit based editors like kate, kwrite, geany (https://github.com/geany/geany) or codeblocks (http://www.codeblocks.org/downloads).
Of the two, I prefer the ui-toolkit based editors, but I'm at home with vim as well. In the ui category -- you really cannot do better than kate/kwrite (and if you aren't smart enough to use TDE, then a geany or codeblocks work well).
For the text/curses based class, it's a preferences thing. vim, or emacs are both incredibly capable, though I find emacs a bit heavier than vim.
Since my background is in the green-screen environment of IBM's mainframe computers, I prefer editors that don't require me to stop typing and use the mouse to perform certain operations, and I'm used to having actual commands (as opposed to ctlrl or alt sequences. The editor I'm using today is Blair Thompson's X2, but it has some irritating bugs in the Unix version that haven't been addressed. The worst problem I have with it is that I can't override the font size in the X Windows version, and I need a microscope to read its text. Since Blair doesn't seem to be interested in fixing these minor issues, I've been looking for what I consider a suitable replacement for X2.
Learning C is one of the best choices you can make. Nothing else (aside from assembly) provides you the complete control over hardware as C does. However, working at the hardware level comes with great responsibility. You are responsible for memory management. One-byte too few and you walk off into the realm of Undefined Behavior. Leaning C, you learn to program and will be a better programmer as a result, regardless of which language you ultimately end up writing in.
I tend to agree. I started in the computer industry in the early '70s (long before PCs were thought of), so I know how to program, but not in C; my familiarity is with FORTRAN, COBOL and Rexx. Finding useful examples of C code that I can use to get a comprehensive feel for the language is difficult; Hello World is so trivial as to be useless, and finding something that actually does useful work while being small enough to get my head around has been difficult. Hopefully, with TDEditor I'll be able to kill two birds with one stone, learning to write C and producing a text editor that has the features I want.
The best advice anyone can give you in learning C is simply to slow-down. C is an exact language. Understand every declaration, the proper use of each library function and for God sake validate the return of every allocation and every I/O call. You don't digest the whole library at once. When you use a library function, open the man page -- read it -- pay careful attention to all parameter type, return types and the RETURN section of the page.
C has a certain reputation as a language that makes it very easy for a neophyte programmer to shoot himself in the foot; I intend to be very careful. :-)
(pay particular attention to the man page for the scanf family -- which provides no end of pitfall for the new C programmer who fails to learn the distinction between a *matching* and *input* failure and fails to understand that when either occur, no further characters are extracted from the input stream and are left unread -- just waiting to bite you on your next call)
When you are learning, forget an IDE, build your code on the command line so you actually learn what the compiler option are and how to correctly use them -- then you can properly use an IDE. Until you understand how to compile and link your code -- there is no way you can tell an IDE how to do it.
When I learned to program there was no such thing as an IDE, and I've never found them particularly useful. (When I started out, my IDE was an IBM 029 keypunch machine. The closest I got to an IDE on the mainframe was ISPF's PDF editor's ability to insert code snippets. :-) )
*Always* compile with *warnings enabled* and do not accept code until it compile cleanly, without warning. For gcc/clang that means adding -Wall -Wextra -pedantic (and I would add -Wshadow) to your command line. (clang also provides -Weverything). If you hop on a windoze box, the for VS (cl.exe) use /W3 (/Wall provides a great deal of non-code specific warnings that are a bit much).
Okay. I must note, though, that many of the packages that I've installed from source tarballs are liberally sprinkled with warnings, even though their authors presumably consider their code to be production quality. In TDEditor, for example, gcc complains about these two code snippets:
| if (token == "User" || | (parse_token( line, token ), stricmp( token, "User" )) == 0)
in config.c produces
| Compiling config.c | config.c: In function ‘process_menu’: | config.c:1988:23: warning: comparison with string literal results in unspecified behavior [-Waddress] | if (token == "User" || | ^
which makes some sense, though in the languages I'm familiar with such a construction's behaviour is well-defined; I would guess that defining "User" as a string constant would make the compiler happy? and
| static const char *fc, *fc2;
in pull.c produces | Compiling pull.c | pull.c: In function ‘make_menu’: | pull.c:835:25: warning: variable ‘fc2’ set but not used [-Wunused-but-set-variable] | static const char *fc, *fc2; | ^
which makes no sense at all, since
| fc2 = (frame < 3) ? fc : graphic_char[2];
certainly looks to me like it's being used. I can see where C got that reputation. :-)
Finally, go get an account on StackOverflow.com -- seriously. If you have a C question -- it has probably already be answered 50 times over, and the answer peer-reviewed. (the same applies for just about any language, it is a fantastic site) Before you post a question you are expected to have searched for a similar one and taken the http://stackoverflow.com/tour, visited http://stackoverflow.com/questions/how-to-ask and when posting always provide a http://stackoverflow.com/help/mcve (a minimal, complete and verifiable example -- meaning something those there can compile to verify your code behavior and help debug)
I've used StackOverflow many times, though I don't have an account there. What's the advantage of having an account?
Learning C isn't something you'll do in a day, or a week, or month, or year -- it is a journey -- enjoy the ride.
No kidding. :-)
Leslie