Commit Graph

73 Commits

Author SHA1 Message Date
Michael Jennings 5d475d0105 src/*.c, Eterm.spec: Various build fixes
Several changes here to make it build on RHEL/CentOS 8:
 - Replace outdated MEMSET() macro with (g)libc memset()
 - Update Release field to use `git describe` just like LibAST
 - Fix `make distcheck` by adding an uninstall-hook for src/gdb.scr
 - At long last, remove the ancient RPM %changelog content
 - Fix incompatibility with my traditional choices for CFLAGS
   (-O0 -g3) and modern RHEL security/hardening goop which, due to
   being implemented in the GCC optimizer, is rendered non-functional
   by building with -O0!
 - Rename backgrounds tarball so that it doesn't have the Eterm
   version in its name since, shockingly, it never changes based on
   the version of Eterm!
2020-02-28 17:06:54 -07:00
Lucas De Marchi 369e95c1df Revert and re-apply badnull patch
Revert previous patch generated by badnull.cocci script, and apply the new one.
The main difference is that assert and assert-like functions are not touched
anymore.




SVN revision: 51650
2010-08-26 01:34:13 +00:00
Michael Jennings d3bb74d029 Revert coccinelle changes.
Using !! instead of != NULL results in significantly and unacceptably
less readable code, and I refuse to accept those changes.
Unfortunately, since they were all done at once, I have to revert the
whole thing.  Oh well. :(


SVN revision: 51583
2010-08-23 17:55:09 +00:00
Lucas De Marchi 3f375e63e2 Convert (hopefully) all comparisons to NULL
Apply badzero.cocci, badnull.coci and badnull2.cocci

This should convert all cases where there's a comparison to NULL to simpler
forms. This patch applies the following transformations:

code before patch               ||code after patch
===============================================================

return a == NULL;                 return !a;

return a != NULL;                 return !!a;

func(a == NULL);                  func(!a);

func(a != NULL);                  func(!!a);

b = a == NULL;                    b = !a;

b = a != NULL;                    b = !!a;

b = a == NULL ? c : d;            b = !a ? c : d;

b = a != NULL ? c : d;            b = a ? c : d;


other cases:

a == NULL                         !a
a != NULL                         a




SVN revision: 51487
2010-08-21 13:52:25 +00:00
Michael Jennings f5e3dbacf6 Tue Jan 6 01:08:47 2009 Michael Jennings (mej)
Update copyright dates and fix a bad license.
----------------------------------------------------------------------


SVN revision: 38480
2009-01-06 09:08:48 +00:00
Michael Jennings c7a352b0c0 Wed May 14 14:54:16 2008 Michael Jennings (mej)
Modified patch from hsim@gmx.li to allow setting of the "Urgent" hint
on beep.
----------------------------------------------------------------------


SVN revision: 34572
2008-05-14 21:54:45 +00:00
Michael Jennings 7537403997 Mon Feb 13 14:51:56 2006 Michael Jennings (mej)
Update to libast 0.6+ API.
----------------------------------------------------------------------


SVN revision: 20440
2006-02-13 19:52:45 +00:00
Michael Jennings b8cf59b892 Wed Jan 4 04:22:13 2006 Michael Jennings (mej)
Update copyright dates.
----------------------------------------------------------------------


SVN revision: 19522
2006-01-04 09:22:41 +00:00
Michael Jennings 6657911db3 Mon Apr 18 21:49:08 2005 Michael Jennings (mej)
Re-indent code.
----------------------------------------------------------------------


SVN revision: 14229
2005-04-19 01:57:24 +00:00
Michael Jennings 7db420d474 Wed Nov 3 18:17:52 2004 Michael Jennings (mej)
Small patch for building against libast 0.6.1.

Fixed compile error when enabling OFFIX_DND support pointed out by JG
Miller <miller@yoyo.org>.
----------------------------------------------------------------------


SVN revision: 12140
2004-11-03 23:18:45 +00:00
Michael Jennings d883466f6e Fri Jun 25 17:48:24 2004 Michael Jennings (mej)
Chris Schoeneman <crs23@bigfoot.com> pointed out that Eterm didn't get
keypresses if another app (like synergy) decided to listen for its
events.  This should correct that behavior.
----------------------------------------------------------------------


SVN revision: 10583
2004-06-25 21:52:00 +00:00
Michael Jennings 8e26d97824 Sun Jan 11 17:09:07 2004 Michael Jennings (mej)
It's too bad you can't just say, "Copyright 1997-2999."


SVN revision: 8349
2004-01-11 22:10:29 +00:00
Michael Jennings 243e65e5a2 Sun Aug 24 11:07:54 2003 Michael Jennings (mej)
I redid the options variables and constants to try and make things
more standardized, and to make room for future toggles as well.  This
should make David Lloyd a bit happier, 'cause now we can get his patch
in here. :)

Hopefully I didn't break anything....


SVN revision: 7370
2003-08-24 15:09:32 +00:00
Michael Jennings 0784d8336b Thu Aug 21 23:51:12 2003 Michael Jennings (mej)
Oops, that wasn't *quite* what I had in mind....


SVN revision: 7362
2003-08-22 03:52:02 +00:00
Michael Jennings 6b43700de1 Thu Aug 21 23:18:23 2003 Michael Jennings (mej)
A few cosmetic changes to the source code, and a fix for Debian Bug
#176274 reported by Gerhard Tonn <GerhardTonn@gammatau.de>.


SVN revision: 7361
2003-08-22 03:19:43 +00:00
Michael Jennings 15ad73f445 Wed Feb 19 16:17:00 2003 Michael Jennings (mej)
Updated copyright statements for 2003.


SVN revision: 6698
2003-02-19 21:18:10 +00:00
Michael Jennings 4547d54583 Wed Feb 19 11:41:00 2003 Michael Jennings (mej)
Patch from Paul Brannan <pbrannan@atdesk.com> to fix a conflict
between twin's non-standard mouse drag reporting and vim when twin
support is not enabled.


SVN revision: 6696
2003-02-19 16:42:27 +00:00
Michael Jennings a74ae94c5a Sun Oct 13 00:57:37 2002 Michael Jennings (mej)
Moved "Escreen" menu to the new Escreen theme so it's no longer
hard-coded.

Added interactive prompting to search() script routine.

Changed dialog() routine to exec_dialog() and added editing of its
command line.

Added msgbox() script routine to display a message and wait for a
keypress.

Fixed a memory leak in the menu_dialog() function.  Also cleaned up
its event handling.

Added comments to the script routines that were missing them.

Make sure we exit cleanly if our window is destroyed.

Fixed the missing menus in the Escreen theme.  You'll still get an
error message when it loads, but I'm not that worried about it.


SVN revision: 6421
2002-10-13 05:03:47 +00:00
Michael Jennings 6b461d5434 Fri Oct 4 21:17:42 2002 Michael Jennings (mej)
LibAST 0.5 is now required to build Eterm.  Hope everyone updated.  By
the way, this fixes that old font-starts-with-a-hyphen bug along with
some compiler warnings the resulted from a change in the way the
ASSERT() macro worked.


SVN revision: 6407
2002-10-05 01:19:41 +00:00
Michael Jennings b8c1785c39 Sat Jun 8 12:46:44 2002 Michael Jennings (mej)
My own Escreen updates, primarily for devoting a dedicated buttonbar
to Escreen's use.  This keeps Escreen from trodding on your existing
buttonbar, if you have one.  It's hard-coded to bottom-dock right
now; we'll look at configuration later. :-)


SVN revision: 6308
2002-06-08 16:50:38 +00:00
Michael Jennings 981b29c895 Sun Jun 2 20:23:07 2002 Michael Jennings (mej)
Latest Escreen patch along with twin support from Azundris.


SVN revision: 6297
2002-06-03 00:24:22 +00:00
Michael Jennings 92ca20bcba Sat May 4 10:23:38 2002 Michael Jennings (mej)
Ran reformat-code on the tree.

Also merged in Azundris' Escreen patch.  It's disabled by default for
the moment pending further testing, but you can enable it manually by
defining ESCREEN.


SVN revision: 6202
2002-05-04 14:25:30 +00:00
Michael Jennings 1ece1388ff Sun Feb 3 15:51:38 2002 Michael Jennings (mej)
Apparently I forgot to commit these copyright date changes. :(


SVN revision: 5895
2002-02-03 20:53:07 +00:00
Michael Jennings bfec337701 Mon Dec 31 16:28:46 2001 Michael Jennings (mej)
Minor debugging enhancements.


SVN revision: 5795
2001-12-31 21:29:30 +00:00
Michael Jennings b8e17e5de4 Sun Oct 21 06:15:13 2001 Michael Jennings (mej)
Fixed a couple remaining bugs in 0.9.1, including that really
annoying problem people keeping whining about where Eterm won't build
without Imlib2.  It will now. :P


SVN revision: 5543
2001-10-21 13:21:05 +00:00
Michael Jennings 5fb6ac13f9 Wed Sep 26 23:19:37 2001 Michael Jennings (mej)
Oops.  Let's get rid of that useless code. :P


SVN revision: 5378
2001-09-27 06:21:28 +00:00
Michael Jennings cd4595128b Sun Aug 5 16:15:34 2001 Michael Jennings (mej)
fvwm color thingie patch from Eric West <ericwest@asicaction.com>.


SVN revision: 5047
2001-08-05 23:18:48 +00:00
Michael Jennings 3a471bb33e Wed Jun 13 21:13:51 PDT 2001 Michael Jennings <mej@eterm.org>
There is now a new mechanism for dealing with the background image
	collection, including a new update script.  Please read the newly-
	rewritten bg/README.backgrounds for details.

	Also, I'm trying to flesh out the Contributors list in that file, but
	my memory isn't cooperating.  So if you contributed one of the
	backgrounds, or know someone who did, please let me know.


SVN revision: 4810
2001-06-14 05:31:09 +00:00
Michael Jennings c3f775c1b5 Mon Jun 11 17:49:55 PDT 2001 Michael Jennings <mej@eterm.org>
Okay, first off, I removed 3 scaled backgrounds.  See www.kainx.org or
	my post to enlightenment-devel for details.

	Second, I redid the default bindings for the mouse wheel.  Basically,
	the wheel alone will scroll by pages.  Ctrl+wheel will scroll by pages
	in groups of 5.  Shift+wheel will scroll by a single line.  If you
	hold down the Alt key, the same combinations will work the same way,
	but instead of scrolling within Eterm, they'll scroll the application
	in the terminal (by sending PgUp/PgDn and up/down arrows).  This works
	in less, bash, and any other application which groks those keys.

	I also added a --without-mousewheel option to configure that will turn
	off the default scrollwheel bindings.  Of course, you can always use
	action bindings in the config file to bind/rebind these any way you
	like.

	While I was at it, I found and fixed a bug in the handling of the
	Alt and Meta keys.

	I added a scroll() function to the script stuff which allows you to
	bind keys/buttons to scroll up and down.  While I was at it, I added
	comments to script.c for each function you can use.

	And finally, the config file parser was moved to libast.


SVN revision: 4806
2001-06-12 01:04:45 +00:00
Michael Jennings d6cf164837 Thu May 24 00:14:54 PDT 2001 Michael Jennings <mej@eterm.org>
Finally got the selection stuff cleaned up.  Hopefully this will be
	the last time I have to deal with it for awhile.  While I was at it,
	I implemented incremental selection transfers.  Unfortunately, it
	doesn't seem like too many people support it.  kedit doesn't, and it's
	broken in Emacs (*grumble*).  Works in gvim though.


SVN revision: 4784
2001-05-24 07:17:03 +00:00
Michael Jennings bd1ed42760 This is work in progress, cleaning up the selection stuff. Still more to
do, though.


SVN revision: 4777
2001-05-19 06:56:45 +00:00
Michael Jennings 9e8120cb88 Thu Nov 9 19:22:18 PST 2000 Michael Jennings <mej@eterm.org>
Fixed the error message bug I noticed.  There's also a big5 fix from
	Chung-Yen Chang <candyz@cle.linux.org.tw>, and I got rid of some
	tiny memory leaks in the X data, the first of which was noticed by
	zed@linuxpower.org.


SVN revision: 3844
2000-11-10 03:26:04 +00:00
Michael Jennings c567ebcf33 Fri Sep 1 21:03:53 PDT 2000 Michael Jennings <mej@eterm.org>
I'm working on some deallocators now.  The idea is that when Eterm
	exits and memory debugging is on, several routines get called to free
	the in-use memory (menus, font cache, etc.) that we still know about.
	Anything left after that would be either unavoidable leaks (like
	environment variables...read the putenv() man page sometime...sigh)
	or genuine memory leaks that need fixing.  I'm down to about 4.5K of
	leftover malloc'd memory now.  Making progress....


SVN revision: 3295
2000-09-02 04:12:16 +00:00
Michael Jennings 9a6507f458 Wed Aug 30 22:58:18 PDT 2000 Michael Jennings <mej@eterm.org>
Massive reorganization/rewrite to libmej.  It should now be 100%
	independent of Eterm.  There still may be some gremlins in the memory
	debugging code, so don't use too high a number with --debug....


SVN revision: 3282
2000-08-31 05:41:44 +00:00
Michael Jennings 47e8788bc8 Wed May 31 22:34:12 PDT 2000 Michael Jennings <mej@eterm.org>
Okay, first off I need to thank Marius Gedminas <mgedmin@takas.lt>.
	Not only did he point out several issues, he was even willing to send
	a patch. :-)

	This commit includes Marius' patch which keeps MappingNotify events
	from overriding users' modifier settings.  It also includes a fix to
	a seg fault that he pointed out when menus were loaded without the
	menu imageclass having been defined.

	He also pointed out that --pause tends to sit and spin, taking up 100%
	of the CPU time.  Funny how E-Cpu never seemed to get too bent out of
	shape over it, but he was indeed correct.

	Thus I have fixed it, and while doing so, I have changed the way it
	works.  It no longer waits for a keypress per se.  Actually, it just
	ignores the fact that its child went away and keeps right on taking
	X events.  There are a few exceptions though.  Either ESC or Ctrl-C
	will exit a paused Eterm.  Any other input that doesn't have special
	meaning to Eterm will be ignored.  (Shift-PgUp and Shift-PgDn still
	work however, as do any action bindings you may have.)


SVN revision: 2739
2000-06-01 05:24:47 +00:00
Michael Jennings dda8ccf31f Thu May 4 00:32:45 PDT 2000 Michael Jennings <mej@eterm.org>
Added new shade/tint routines, including some done in MMX assembly, by
	Willem Monsuwe <willem@stack.nl>.  Thanks Willem!  These should prove
	to be faster than the old stuff, probably by quite a bit.


SVN revision: 2595
2000-05-04 07:22:07 +00:00
Michael Jennings e6facd5833 Wed May 3 21:04:37 PDT 2000 Michael Jennings <mej@eterm.org>
Fixed a bug in the handling of resize events thanks to a tip from
	Teodor Zlatanov <tzz@iglou.com>.  While I was at it, I also fixed a
	couple remaining issues with the popup menu system.  You shouldn't
	get any more cases where items remain selected after you've moved your
	mouse off of the menu, or where a submenu would stay up even though
	another menuitem is selected.


SVN revision: 2594
2000-05-04 03:54:28 +00:00
Michael Jennings 4bb04764b3 Tue May 2 16:56:47 PDT 2000 Michael Jennings <mej@eterm.org>
After getting sick of hearing people whining about the obscure error
	messages that resulted from trying to build without pixmap support, I
	hacked it until it at least built without it.  I also added warnings
	to configure.in so that people would know if that happened.

	It's still not very happy running that way, which is something I need
	to fix.  But hopefully it will stop the whining.

	Yeah, right. =P


SVN revision: 2590
2000-05-02 23:46:08 +00:00
Michael Jennings 1e9bf450c4 Mon Apr 17 22:25:27 PDT 2000 Michael Jennings <mej@eterm.org>
I fixed the problem reported by Joakim Bodin <bodin@dreamhosted.com>
	with spawned processes.  Also fixed Esetroot as reported by Wayne
	Johnson <bigman1@alltel.net>.

	Support for buttons higher than 5 was also added to the action
	bindings code for those (like me) with IntelliMouse Explorers and
	XFree86 4.0. :-)


SVN revision: 2494
2000-04-18 05:16:00 +00:00
Michael Jennings 94f00a7923 Thu Mar 30 20:34:10 PST 2000 Michael Jennings <mej@eterm.org>
Quick little option -q/--no-input.  It keeps Eterm from accepting
	keyboard input, and keeps the window manager from focusing it.  Useful
	for log tailers and such, maybe.  This feature was requested by
	Peter Ward <than@ilm.com>.  I will be adding an escape sequence to
	toggle this.


SVN revision: 2398
2000-03-31 04:38:01 +00:00
Michael Jennings 22160247e4 Fri Mar 17 18:27:51 PST 2000 Michael Jennings <mej@eterm.org>
I added accelerated scrollwheel support.  I also added a #define in
	src/feature.h for specifying the number of lines of context to keep
	when paging up or down.

	Also, we're back to the old behavior where home on input won't be
	triggered unless the key pressed has an associated string value.  I
	went back on this because Shift causing a jump to the bottom was
	really annoying when trying to Shift-PgUp or Shift-PgDown.  Sorry,
	Darren, but you lose.


SVN revision: 2270
2000-03-18 04:55:14 +00:00
Michael Jennings f54c3eeb6e Rats.
SVN revision: 2236
2000-03-15 03:20:30 +00:00
Michael Jennings 4d1fd23d7e Tue Mar 14 19:11:26 PST 2000 Michael Jennings <mej@eterm.org>
Some further fixes for inline functions, 2 new winop actions, brand
	new and improved profiling macros, some miscellaneous fixes for SGI
	from Kimball Thurston <kimball@sgrail.com>, and more robust checking
	in the pasting code.


SVN revision: 2235
2000-03-15 03:17:45 +00:00
Michael Jennings af082c9a22 Tue Feb 15 19:31:04 PST 2000 Michael Jennings <mej@eterm.org>
The buttonbar can now be toggled on and off both in the config file
	and via an escape sequence.  The themes in CVS use Ctrl-Shift-Button3.
	You can also specify in the config file whether to dock the buttonbar
	at the top or the bottom of the Eterm window.  You can't move it on
	the fly yet, but that will come.

	I also fixed resizing so that the term window didn't redraw itself
	unnecessarily.  Hopefully I didn't break anything in the process.  :-)

	Plus, I fixed poor handling of X-generated ConfigureNotify events, and
	the terminfo stuff is now done at install time instead of build time.


SVN revision: 2077
2000-02-16 03:37:34 +00:00
Michael Jennings 42fde9c99d Thu Feb 10 15:10:01 PST 2000 Michael Jennings <mej@eterm.org>
This is the first public availability of the work thus far on Eterm
	0.9.1.  There's quite a bit of new stuff here.

	* Added scrollbar thumb support.

	* Completely redid the terminfo/termcap stuff.  The terminfo file is
	now compiled (by tic) and installed by default (unless you specify
	--without-terminfo).  The config files still say xterm, though,
	because some programs (like SLang and GNU mc) use the silly algorithm
	of "Is $TERM set to xterm?" to detect mouse reporting support in a
	terminal. =P  But if you don't ever use xterm, you can use Eterm's
	termcap and just name it "xterm" instead.  Thanks to Marius Gedminas
	<mgedmin@takas.lt> for his patch that started this whole revamp.

	* Added the kEsetroot script for KDE users from Dax Games
	<dgames@isoc.net>.

	* You can now configure the Home and End emulation via --with-home=
	and --with-end= options to configure.  The --with-terminfo option is
	also new, and --enable-xim is now the default.

	* Added a new image state, disabled, for when Eterm loses focus.  This
	is supported by all widgets (well, all those that could possibly be
	on screen when Eterm lost focus), even the background image.  So you
	could actually have all your images darken on focus out and restore
	to normal on focus in.

	* Widget colors formerly dealt with as colors (menu text color,
	scrollbar color, etc.) are now handled by the imageclasses.  Each
	image state can have a foreground and background color defined.  The
	current exception is the background image; I hope to add that later.
	The foreground is the text color and the background is the object
	color (for solid color mode).  So menu text color is set by the menu
	imageclass.  And again, for unfocused colors, use the disabled state
	of the imageclass.

	* Proportionally-spaced fonts are now handled much better.  They are
	still forced into evenly-spaced columns (it's a terminal for crying
	out loud!) but at least you don't end up with Eterm's wider than your
	screen. :-)

	* Home on refresh is gone, as is home on echo.  It's now much simpler.
	There are two options:  home on output, and home on input, the former
	being a combination of echo and refresh.  Also, keypresses that don't
	necessarily have corresonding output can trigger a home on input,
	like Ctrl-End or whatever...ones that don't have special meaning.
	Credit to Darren Stuart Embry <dse@louisville.edu> for pointing out
	this issue and the one with "m-" in font names.

	* I finally got around to re-merging the new parser stuff from my
	work on the Not Game.  Closed up some old potential behavior quirks
	with theme parsing.

	* Added a new escape sequence to fork-and-exec a program.  Also added
	a scrollback search capability to highlight all occurances of a string
	in your scrollback buffer.  Use the new "Etsearch" utility to access
	it.  "Etsearch string" to search for a string, then "Etsearch" by
	itself to reset the highlighting.

	* And of course, the biggie.  Eterm now supports a completely-
	customizeable buttonbar.  Not a menubar, a buttonbar.  It can have an
	arbitrary number of buttons, and each button can perform an action,
	just like a menuitem.  So a button could bring up a menu (like a
	menubar) or launch a program (like a launchbar) or perform an
	operation (like a toolbar).  Each button can have an icon, text, or
	both.  And you can have buttons left- or right-justified in the
	buttonbar.  You will eventually be able to have an arbitrary number
	of buttonbars, but I'm still working on that.

	As with any change this big, things could very easily be broken.  So
	beware. :-)  I have tested this myself, and everything seems to work,
	but I can't test every possibility.  Let me know if you find anything
	that's broken, and enjoy!


SVN revision: 2048
2000-02-11 00:25:07 +00:00
Michael Jennings 0c66bab547 Wed Jan 5 21:23:56 PST 2000 Michael Jennings <mej@eterm.org>
Copyright date updates.


SVN revision: 1860
2000-01-05 17:34:32 +00:00
Michael Jennings 7830619d07 Tue Jan 4 14:13:48 PST 2000 Michael Jennings <mej@eterm.org>
Some minor optimizations I did while looking into a bug report.


SVN revision: 1842
2000-01-04 10:46:47 +00:00
Michael Jennings ea41c7f739 Mon Jan 3 12:47:59 PST 2000 Michael Jennings <mej@eterm.org>
Fixed the bug with a solid scrollbar not updating colors when the
	focus changed.  Pointed out by cirin <stevenr@houston.rr.com>.


SVN revision: 1824
2000-01-03 09:40:14 +00:00
Michael Jennings d9251f002d Mon Dec 20 19:38:40 PST 1999 Michael Jennings <mej@eterm.org>
I fixed a bunch of double-buffering stuff here.  I'm going to use it
	by default on my own Eterms for awhile, and if I don't hit any snags,
	I'll make it the default in the themes.


SVN revision: 1708
1999-12-20 19:52:10 +00:00
Michael Jennings 1b605f362f Mon Dec 20 18:51:10 PST 1999 Michael Jennings <mej@eterm.org>
Son of a Gnea.  How did I ever get away with having *these* frikkin'
	bugs in there?! =P


SVN revision: 1704
1999-12-20 19:08:00 +00:00