aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main.cpp
AgeCommit message (Collapse)AuthorFilesLines
2014-02-15updated Copyright to year 2014Robin Haberkorn1-1/+1
2014-02-15all interface classes define the same type InterfaceCurrent, simplifying the ↵Robin Haberkorn1-5/+1
interface object definition * they still define their own classes (e.g. InterfaceNCurses), InterfaceCurrent is a typedef
2014-02-15added State::StdError class for constructing errors from std::exception objectsRobin Haberkorn1-1/+1
2014-02-15use GLib's GError information to yield errorsRobin Haberkorn1-2/+5
* results in better error messages, e.g. when opening files * the case that a file to be opened (EB) exists but is not readably is handled for the first time
2014-02-15glib allocation functions throw std::bad_alloc exceptions now; catch all ↵Robin Haberkorn1-0/+58
bad_allocs and convert them to State::Error * will allow some degree of OOM handling * currently does not work since the exception specifications prevent bad_allocs from propagating. exception specification usage must be completely revised
2014-02-15String::get_coord() calculates line and column of a string positionRobin Haberkorn1-0/+23
* use to get line and column into a stack frame
2014-02-15added support for TECO stack tracingRobin Haberkorn1-15/+22
* when an error is thrown, stack frames are collected on clean up, up to the toplevel macro * the toplevel macro decides how to display the error * now errors in interactive and batch mode are displayed differently * in batch mode, a backtrace is displayed as a sequence of messages * Execute::file() forwards errors correctly * the correct error in the file is displayed in interactive mode * necessary to build the stack trace
2013-03-18remove all unused-attributes for parametersRobin Haberkorn1-2/+2
* compiler does not warn by default: this actually makes sense * so we don't need any unused-attributes * less GCC-extension based * on older GCCs I think -Wunused-parameters was enabled by -Wall we should add -Wno-unused-parameters if that's the case
2013-03-18declare all global inter-dependant objects in main.cpp and get rid of ↵Robin Haberkorn1-0/+20
init_priority attribute * we cannot use weak symbols in MinGW, so we avoid init_priority for symbol initialization by compiling the empty definitions into sciteco-minimal but the real ones into sciteco (had to add new file symbols-minimal.cpp) * this fixes compilation/linking on LLVM Clang AND Dragonegg since their init_priority attribute is broken! this will likely be fixed in the near future but broken versions will be around for some time
2013-03-18make sure a (void*)0 is used as sentinelsRobin Haberkorn1-2/+2
since including glib.h on LLVM-Clang (32-bit) results in NULL being redefined to 0 and compiler warnings being emitted when NULL is used as sentinels
2013-03-18prefer $HOME over passdb when looking for .teco_iniRobin Haberkorn1-1/+1
* fixes sudo sciteco: will still use the real user's .teco_ini * when run with real user as root, will look in root's home dir * use g_get_home_dir() as a fallback
2013-02-22use typedef for SciTECO integers and make it configurable at configure timeRobin Haberkorn1-1/+1
* storage size should always be 64 (gint64) to aid macro portability * however, for performance reasons users compiling from source might explicitly compile with 32 bit integers
2013-02-22fixed global object initialization order issueRobin Haberkorn1-3/+3
* Scintilla is now initialized from main() using Interface::main() * Scintilla initialization depends on initialization of objects in the global namespace (otherwise the Lexer catalogue may not be filled properly and lexing may not work). Lexer modules were initialized after SciTECO interface initialization * merged Scintilla initialization (Interface::main()) with interface option parsing
2013-02-22fixed margin configuration with GTK+ interfaceRobin Haberkorn1-1/+3
* line-number style must be explicitly set, even after CLEARALLSTYLES * margin widhts are in pixels (except in Scinterm), so we must determine the pixels requiered by a number of digits (e.g. 5 digits)
2013-02-22Windows (MinGW) compatibility fixes: suspending impossible and environment ↵Robin Haberkorn1-8/+7
initialization revised * g_get_environ() appears to be broken, at least in Wine and Win2k
2013-02-22clean up QRegisterTable::insert|initialize usageRobin Haberkorn1-5/+4
* distinction no longer useful since string part of register is now never pre-initialized
2013-02-15install standard macros into special standard library path (pkgdatadir/lib)Robin Haberkorn1-1/+5
* SCITECOPATH environment variable defaults to this directory * manpage updated * default teco.ini updated: no need to generate it anymore
2013-02-14initialize global Q-Registers (beginning with $) with environment variablesRobin Haberkorn1-0/+23
e.g. G{$HOME} will insert the HOME environment variable
2013-02-08use special Q-Register $ (<ESC>) to hold the replacement commandlineRobin Haberkorn1-0/+3
* allows us to switch between buffers/registers when editing the commandline
2013-02-01fixed buffer Ring initializationRobin Haberkorn1-2/+0
* there was a dependency on interface initialization. it did not cause issues because destruction order was by chance. * introduced INIT_PRIO and PRIO_* macros to easy initialization order declaration (using a PRIO_* formula makes code self-documenting) * also used this to clean up QRegisterTable initialization (we do not need the explicit initialize() method) * also used to clean up symbols initialization
2013-01-23added --eval commandline option allowing code to be executed on the commandlineRobin Haberkorn1-1/+19
useful, e.g. in Makefiles
2013-01-23implemented special save last commandline command ("*" at beginning of ↵Robin Haberkorn1-0/+1
commandline macro) * only works as part of commandline macro, * at the beginning of other macros, it is treated like an arithmetic asterisk * variables defined in cmdline.cpp are now declared by new cmdline.h
2013-01-19updated copyright (2012-2013)Robin Haberkorn1-1/+1
2013-01-19allow <CTRL/C> to be typed; aborts last typed charRobin Haberkorn1-0/+19
* CTRL/C will be a command so it is important to be able to type it directly * aborting character processing is important because it allows aborting infinite loops * since the loop interruption currently relies on SIGINT handling, there is only limited support for XCurses and GTK - CTRL/C has to be typed in the terminal window. later support for input queue polling might be added
2012-12-05windows compatibility changesRobin Haberkorn1-21/+7
* respect executable extensions * do not use weak symbols which appear to be broken on MinGW. Instead, the generated symbol constants contain constructor functions initializing the corresponding objects. Constructor priorities are used to ensure that the initialization takes place after the dummy (NULL) initialization. * do not change the working dir (causes trouble when sciteco gets passed relative paths but the exe is not in the current dir) instead look for teco.ini in program's directory
2012-12-04added copyright notice to every source fileRobin Haberkorn1-0/+17
2012-12-04first working version of autotools based build-systemRobin Haberkorn1-0/+4
2012-12-04autoconf preparation: move everything into src/ subdirRobin Haberkorn1-0/+208