Page 1 of 1
My prefered enhancements
Posted: Sun Aug 01, 2004 6:32 am
by boon_kwee
Textpad has done well where many Microsoft platform-based editor could not, but a couple more features as follows should be considered :
1. enable opening textpad from Command Prompt. as notepad. I know this feature can be implemented by adding the "%programfiles%textpad 4" into environment path but it should be adding automatically during installation. It can also be integrated at the textpad configuration so that user can choose to disable this feature.
2. support C/C++ compilation. Beside the current Java compiling feature, the textpad should also consider adding C/C++ compiling feature to attract more users from the C programming arena.
Posted: Sun Aug 01, 2004 11:24 am
by MudGuard
Adding C/C++ support is a bit more difficult than adding Java.
There is only one really widespread Java compiler - the one from Sun.
Ok, it exists in different versions, but the exe for compiling is always called javac.
With C/C++, there are lots of different compilers with different names (like Borland, Gnu, Visual C++, Watcom to name just the few which I have used myself).
Which one should be integrated? And why that one and not one of the others?
Would you really like to have all of them integrated? Just because some people might use one of them?
My preferred enhancement
Posted: Mon Aug 02, 2004 3:11 am
by boon_kwee
I agree with you in that there are many compilers around. I for one was using turbo C++ but had to switch to DJGPP which is rather a common compiler used in Redhat Linux.
I suggest perhaps the one generally used by linux users (i.e. DJGPP C Compiler) can be considered an option, rather than sitting around waiting for a prominant compiler to arise, if textpad could just adopt one of the open-source (or even the free Borland C 5.5 Compiler from Borland Int'l). I think that it would be seemed as a greater attraction for the C/C++ community.
Generally, I don't find a 'economic' C IDE tool around since I last used Turbo C++ 3.0 compiler. (Pardon my ignorance or negligent, but do tell me about it if you can find one, I'll really appreciate it A LOT!!!) Textpad has proven a great help with its ability to display .cpp or .c file. But it would be even better with support to an existing compiler.
Moreover, users could simply edit the Tools instructions to use a separate set of compiler if they find one of their preference.
Posted: Mon Aug 02, 2004 8:39 am
by MudGuard
What I do not understand:
how can someone write programs in C or C++, if his skills are not sufficient for the simple task of setting up a tool in textpad?
Setting up the tool is not more than copy/paste + a little editing (copy the command you use from command line, paste it into the tool dialog, replace the file name by parameter macros).
Usually, C/C++ compilers are used with a "make" program which is even easier to set up ...
Posted: Sat Aug 07, 2004 7:39 pm
by Mark Rejhon
Usually, compiling a C program within TextPad is easy if you study yourself on how to make a custom tool in TextPad.
You can even make it a DOS batch file that automatically searches for a makefile in the same directory as the C program, and compile using that makefile. (A simple change to the DOS .BAT file can even back-search for a makefile in the directory below, if a makefile doesn't exist in the same directory as the file being edited)
So basically if you're editing a C program in the same directory as the makefile (or in a subdirectory above the makefile), it will automatically compile using that makefile when you select "Tool 1" from TextPad.
Or searching for a *.vcproj or a *.mak or a "MAKE.BAT" or whatever you do for your project and language.
About 10 lines for the batch file, something like:
--------BEGIN RUNMAKE.BAT <directory> ----
@echo off
REM Crude Windows XP Compatible Batch file
REM Scans for a makefile and then executes it
REM Supply directory as first command line argument
IF EXIST %1\Makefile.mak (COMPILER.EXE %1\Makefile.mak) ELSE (
IF EXIST ..\%1\Makefile.mak (COMPILER.EXE ..\%1\Makefile.mak) ELSE (
IF EXIST ..\..\%1\Makefile.mak (COMPILER.EXE ..\..\%1\Makefile.mak) ELSE (
echo No Makefile.bat found!
pause
)
)
)
----------END--------
Of course, modify to suit your programming language and format of makefile. The above backsearches for a makefile up to two levels below the current directory, in case you're editing source code in subdirectories above the makefile.
Configured as a TextPad User Tool.