Commit Graph

66 Commits

Author SHA1 Message Date
Mark Hammond fe51c6d66e Excise DL_EXPORT/DL_IMPORT from Modules/*. Required adding a prototype
for Py_Main().

Thanks to Kalle Svensson and Skip Montanaro for the patches.
2002-08-02 02:27:13 +00:00
Michael W. Hudson 67fb0c3705 I think this fixes
[ #510644 ] test_curses segfaults

If we use the *object* *allocator*, we should use the *object* *deallocator*,
not the *raw memory* deallocator (confused yet?).

I think this was what caused segfaults when pymalloc was enabled.

Even if it wasn't the cause, it's still wrong.

2.2.1 candidate.
2002-01-30 15:39:28 +00:00
Martin v. Löwis c0e1671c71 Patch #477752: Drop old-style getargs from curses. 2002-01-17 23:08:27 +00:00
Michael W. Hudson 8f5146088a Change some spaces to tabs. I don't *think* that was me, but it
might have been...
2002-01-16 15:18:09 +00:00
Michael W. Hudson f24281251f Fix for
[ #504284 ] Last build problems on AIX

I'm ignoring the suggestion that this should be an autoconf test in the
interests of having a fix today.  Feel free to quibble.
2002-01-16 15:14:49 +00:00
Guido van Rossum 146483964e Patch supplied by Burton Radons for his own SF bug #487390: Modifying
type.__module__ behavior.

This adds the module name and a dot in front of the type name in every
type object initializer, except for built-in types (and those that
already had this).  Note that it touches lots of Mac modules -- I have
no way to test these but the changes look right.  Apologies if they're
not.  This also touches the weakref docs, which contains a sample type
object initializer.  It also touches the mmap test output, because the
mmap type's repr is included in that output.  It touches object.h to
put the correct description in a comment.
2001-12-08 18:02:58 +00:00
Martin v. Löwis 43f2dc6251 Limit string size on one-character-strings. Fixes #480384. 2001-11-11 14:49:15 +00:00
Martin v. Löwis 00ff10cae4 Patch in bug report #477700: Fix memory leaks in gdbm & curses. 2001-11-11 14:24:05 +00:00
Martin v. Löwis eb9b103296 Check for HP/UX curses problems. Define _XOPEN_SOURCE_EXTENDED and
STRICT_SYSV_CURSES when compiling curses module on HP/UX. Generalize
access to _flags on systems where WINDOW is opaque. Fixes bugs
#432497, #422265, and the curses parts of #467145 and #473150.
2001-10-24 17:10:49 +00:00
Andrew M. Kuchling 16e65a023e Add two forgotten 'break' statements
Allow passing strings to the .border() method
Correct some error messages ("1 or 4" -> "1 to 4")
Bump version number
Tweak code formatting
Update my e-mail address
2001-10-20 16:05:52 +00:00
Martin v. Löwis 1c07b4b4fb Test for __sun instead of __sun__, since SUNWspro only defines the latter;
gcc defines both.
2001-10-13 09:00:42 +00:00
Andrew M. Kuchling 4a596e3bee [Bug #457654] bkgd() used a hard-coded A_NORMAL attribute, when it should
have used the attribute argument provided as a parameter
2001-09-04 19:34:32 +00:00
Fred Drake 0368bc44e8 Remove warnings from the SGI compiler.
This is part of SF patch #434992.
2001-07-19 20:48:32 +00:00
Andrew M. Kuchling 5a76c44181 Fix bug #417212: "curses.newwin can return pads" by changing the Python
newwin() wrapper to always return a window, and never a pad.  This makes
   the code match the documentation.
2001-07-14 20:38:30 +00:00
Martin v. Löwis bfdf4ecad0 Properly use &&. Closes bug #434988. 2001-06-23 19:58:46 +00:00
Guido van Rossum 858ca0f229 Include py_curses.h *after* defining _XOPEN_SOURCE_EXTENDED.
Michael Hudson suggested this fox for the Tru64 problem (SF bug
232597).  It looks reasonable, it works on Tru64, and it doesn't beak
anything on Linux, so I say go for it.
2001-04-10 19:53:37 +00:00
Andrew M. Kuchling 2d339f9369 Patch #103485 from Donn Cave: patches to make the module compile on AIX and
NetBSD
2001-01-29 20:47:59 +00:00
Andrew M. Kuchling e1c4352f98 Rename 'lines' variable to 'nlines' to avoid conflict with a macro defined
in term.h
2001-01-29 20:31:29 +00:00
Andrew M. Kuchling 399b8af563 Bug #130117: add a prototype required to compile cleanly on IRIX
(contributed by Paul Jackson)
2001-01-28 18:10:23 +00:00
Guido van Rossum 6915c4d0a8 Support building this as a DLL under Cygwin. 2001-01-19 00:28:08 +00:00
Andrew M. Kuchling caefb37ee1 Add the curses constants ERR and OK to the module at TG's suggestion 2000-12-26 15:57:01 +00:00
Andrew M. Kuchling 3255268777 Export C API from this module.
Remove several macros and #includes; py_curses.h contains them now.
2000-12-22 21:52:27 +00:00
Andrew M. Kuchling 9de6ffa314 Another patch from Thomas Gellekum: add .overlay() and .overwrite()
window methods
2000-12-21 16:22:22 +00:00
Andrew M. Kuchling 2824d7f6b1 Wrapper for napms() function, contributed by Thomas Gellekum <tg@FreeBSD.org> 2000-12-15 00:44:02 +00:00
Andrew M. Kuchling 26cc66fe6a Patch #102412 from mwh: Add support for the setupterm() function, to
initialize the terminal without necessarily calling initscr()
2000-11-18 17:45:59 +00:00
Andrew M. Kuchling f16e0ed76c Patch #102278: add tparm() function to _curses module 2000-11-07 03:35:24 +00:00
Andrew M. Kuchling e7d3616409 Patch from Randall Hopper to fix PR #116172, "curses module fails to
build on SGI":
* Check for 'sgi' preprocessor symbol, not '__sgi__'
* Surround individual character macros with #ifdef's, instead of making them
  all rely on STRICT_SYSV_CURSES
2000-11-01 19:59:12 +00:00
Jeremy Hylton 51ee09b995 Don't call Py_FatalError in module initialization
(leaving the rest of the modules for Barry)
2000-09-01 03:46:16 +00:00
Andrew M. Kuchling a98e92bc13 Add alias for old function name -- removing it broke Alexei Gilchrist's cfm 2000-08-20 23:37:02 +00:00
Andrew M. Kuchling fb6bbf51a6 Added list of missing functions as a comment 2000-07-27 11:58:01 +00:00
Andrew M. Kuchling 8353f623d6 Comment out a debugging print (spotted by Michael Deegan) 2000-07-26 18:36:27 +00:00
Andrew M. Kuchling 70e89c11fe Added wrappers for tiget{flag,num,str}, for querying terminfo capabilities 2000-07-26 02:57:20 +00:00
Andrew M. Kuchling bf680266da Modified version of patch #100963 from Mark Favas: has_key() is an
ncurses extension, so it's made conditional depending on STRICT_SYSV_CURSES
2000-07-25 12:37:41 +00:00
Andrew M. Kuchling 4463acbc32 Bug report and partial patch from Michael Deegan <michael@ucc.gu.uwa.edu.au>:
reversed tests resulted in an exception when you supplied the correct number
of arguments
2000-07-24 23:54:49 +00:00
Thomas Wouters f3f33dcf03 Bunch of minor ANSIfications: 'void initfunc()' -> 'void initfunc(void)',
and a couple of functions that were missed in the previous batches. Not
terribly tested, but very carefully scrutinized, three times.

All these were found by the little findkrc.py that I posted to python-dev,
which means there might be more lurking. Cases such as this:

long
func(a, b)
	long a;
	long b; /* flagword */
{

and other cases where the last ; in the argument list isn't followed by a
newline and an opening curly bracket. Regexps to catch all are welcome, of
course ;)
2000-07-21 06:00:07 +00:00
Andrew M. Kuchling ad9b1f8533 Patch from Peter Schneider-Kamp: convert curses module to ANSI prototypes,
and substitute the conventional "args" instead of "arg".
2000-07-09 14:35:00 +00:00
Fred Drake 589c35bcc7 Python 2.0 is not supposed to use string exceptions in the standard library
& extensions, so create exceptions in extension modules using the
PyErr_NewException() API.
2000-07-06 19:38:49 +00:00
Andrew M. Kuchling 1a10400692 Removed unused variables.
Added two functions that were left out of the method definition table.
2000-07-06 18:14:03 +00:00
Andrew M. Kuchling a1e4b05ac4 Fixes for compiling on Tru64.
Define a STRICT_SYSV_CURSES macro on SGI, Sun, and Tru64, to mark systems
that don't support some features.
2000-06-27 21:49:47 +00:00
Andrew M. Kuchling b6e468796a Fix two typos (, instead of ;) 2000-06-27 15:01:10 +00:00
Andrew M. Kuchling 8e9d23b250 Added support for mouse functions: mousemask(), mouseinterval(),
getmouse(), ungetmouse(), and window.enclose().  wmouse_trafo() seems
of marginal importance at the moment.
2000-06-27 03:10:38 +00:00
Andrew M. Kuchling f419572708 Release the global interpreter lock around the most important
functions that might block or pause
2000-06-23 01:36:21 +00:00
Andrew M. Kuchling 97311bbb0e Added .timeout() method and .typeahead() function 2000-06-21 01:41:48 +00:00
Andrew M. Kuchling b7f198e01a Renamed the C extension for ncurses support from 'curses' to '_curses'.
(The SourceForge admins have been asked to rename the ,v file.)
2000-06-10 23:12:32 +00:00
Andrew M. Kuchling 03e644b851 Changes by AMK: Use HAVE_NCURSES_H to include correct header file
Lots of typo fixes (a bit too much cut-and-paste in this module)
Aliases removed: attr_on, attr_off, attr_set
Lowercased the names COLOR_PAIR and PAIR_NUMBER
#ifdef's for compiling on Solaris added (need to understand SYSV curses
    versions better and generalize this)
Bumped version number bumped to 1.6
2000-05-23 16:24:54 +00:00
Andrew M. Kuchling 22b88ce6bf Oliver Andrich's ncurses-specific curses module, version 1.5b1 2000-05-23 16:18:03 +00:00
Guido van Rossum b18618dab7 Vladimir Marangozov's long-awaited malloc restructuring.
For more comments, read the patches@python.org archives.
For documentation read the comments in mymalloc.h and objimpl.h.

(This is not exactly what Vladimir posted to the patches list; I've
made a few changes, and Vladimir sent me a fix in private email for a
problem that only occurs in debug mode.  I'm also holding back on his
change to main.c, which seems unnecessary to me.)
2000-05-03 23:44:39 +00:00
Guido van Rossum 716a89c606 Patch by Charles Waldman to implement an optional nlines argument to
w.scroll().  (It then calls wscrl(win, nlines) instead of scoll(win).)
1999-01-05 17:16:46 +00:00
Guido van Rossum 11847896ed Chris Herborth discovered a typo in the arrow key symbols. 1998-12-23 04:45:04 +00:00
Guido van Rossum 3886bb6997 Add DL_EXPORT() to all modules that could possibly be used
on BeOS or Windows.
1998-12-04 18:50:17 +00:00