Commit Graph

  • 06b0c80678 wenclose(). William McBrine 2006-12-24 16:48:53 +00:00
  • 0654dab33b Explicitly disable click check when !SP->mouse_wait. (However, DOS will still report a click if it doesn't have to wait for it.) William McBrine 2006-12-24 06:07:25 +00:00
  • 7618f5544f Explanation of mouseinterval(). William McBrine 2006-12-24 04:49:53 +00:00
  • b364a9b615 napms() now returns immediately when called with 0. William McBrine 2006-12-24 04:33:29 +00:00
  • a6aa61e9fb mouseinterval(), from ncurses. I'd already implemented the mechanism, so why not make it adjustable? Unlike ncurses, the max is 1000. Also, comment formatting. William McBrine 2006-12-24 04:32:22 +00:00
  • b52bcb5e80 traceon() and traceoff() are found in some other implementations of curses; I hate octal. William McBrine 2006-12-23 17:54:13 +00:00
  • d95d47bc2b Typo. William McBrine 2006-12-22 14:47:26 +00:00
  • 308a1245ca init_color() and color_content() for OS/2. Works only in a full screen session. Compiles only with Watcom and EMX, since it's flaky and I don't have the others to test with. William McBrine 2006-12-22 14:46:54 +00:00
  • 2efedc66ab Description of default colors (could be better); another place for pair_content(). William McBrine 2006-12-20 03:52:43 +00:00
  • c09da0a9df Per the standard and per ncurses, 0 is a valid pair for pair_content(). William McBrine 2006-12-20 03:27:10 +00:00
  • 30148193d3 console_info.ScreenColors and .PopupColors actually want the attribute in a byte. William McBrine 2006-12-20 02:35:48 +00:00
  • ca0ecdbddc Added use_default_colors() and assume_default_colors(), after ncurses. William McBrine 2006-12-20 02:34:17 +00:00
  • 7eda6708d2 Comments -- wungetch() is long gone. William McBrine 2006-12-18 22:07:57 +00:00
  • 4234603525 mvinsrawch(), mvwinsrawch() -- same. William McBrine 2006-12-18 21:47:40 +00:00
  • 58a606af71 Comments; typo. William McBrine 2006-12-18 21:37:57 +00:00
  • 9265776bdb mvdeleteln(), mvwdeleteln() -- same. William McBrine 2006-12-18 21:34:40 +00:00
  • a1f702a0c6 mvinsertln() -- another function in PCcurses but not in PDCurses 2.x. No point having mvwinsertln() without this one... but not much point in having either of them, really. William McBrine 2006-12-18 21:21:06 +00:00
  • 8f0d359ac9 Added mvaddrawch() for completeness. This function actually existed in PCcurses 1.x, but was prototyped and never implemented (not even as a macro) in PDCurses 2.x. William McBrine 2006-12-18 21:06:35 +00:00
  • c4e0dde7bf WACS_BBSS, etc. William McBrine 2006-12-17 08:11:33 +00:00
  • 51dda026e9 pdc_wacs is no longer needed. William McBrine 2006-12-17 03:44:59 +00:00
  • 125eca59a3 Omit acs_map when using the short chtype. William McBrine 2006-12-16 21:53:18 +00:00
  • 71d91852a8 One more stab at acs_map[]. I think I've got it this time. Also, made addrawch() etc. into real functions (necessary for this implementation of acs_map[], but I was planning on it anyway), and finally got rid of PDC_putctty(). The downside of this implementation (apart from the wasted space and slightly reduced speed) is that A_ALTCHARSET is sort of doing double duty -- indicating passthrough for characters below space, plus delete, while actually mapping to an alternate character set for a-z and a few others. However, this is basically what ncurses does (did?), too. (And of course, the upside is that you no longer have to define PDC_WIDE to get proper ACS chars when linking against a library built with PDC_WIDE.) William McBrine 2006-12-16 17:14:54 +00:00
  • 680f4c126c Minor tightening. William McBrine 2006-12-15 10:08:39 +00:00
  • 9c12ec8350 Warning supression. Not ideal, but there seems no good way to reconcile addwstr(wchar_t *) with get_wstr(wint_t *). William McBrine 2006-12-14 01:57:23 +00:00
  • d6eb90ed46 Use a BIOS call to check for keyboard input, where possible. (Not on MS C or Watcom/386.) To Do: Make it possible for Watcom/386? William McBrine 2006-12-13 20:40:50 +00:00
  • 60663eef46 Another. William McBrine 2006-12-13 20:13:07 +00:00
  • 5af87e1dcd Need to tweak the definition/use of HAVE_WIDE. William McBrine 2006-12-13 07:33:44 +00:00
  • 3ad8de12bf Added wide character input test; minor tightening. William McBrine 2006-12-12 19:17:45 +00:00
  • 561b211ed9 AFAICT, there's no situation in which latin1kbd.h is useful -- these keycodes are handled fine by XLookupString(). The table was probably introduced to get around the sign extension error in old versions. ("key = (int)buffer[0]", where buffer was a char *.) William McBrine 2006-12-12 11:39:26 +00:00
  • 9e37853534 Added --enable-xim option for configure. To Do: Defaults? William McBrine 2006-12-12 10:09:46 +00:00
  • a663c0183c Moved the compose key tables to a file of their own, since they're not used in XIM mode, and are kind of annoying. William McBrine 2006-12-12 09:55:36 +00:00
  • 6d96f23c7e Changed my mind again -- the default compose key for the built-in method may as well be Multi_key, since it's now not even checked when PDCurses is built with XIM support. William McBrine 2006-12-12 09:35:23 +00:00
  • ee688f969e A more thorough exclusion of the built-in compose support in PDC_XIM mode. (Now the XIM version actually builds smaller than non-XIM.) William McBrine 2006-12-12 09:27:52 +00:00
  • dbb6e06860 XIM for real actually works now. Only tested with "U.S. International" keyboard... not sure if I want/need to take it any further right now. Disabled the built-in compose support when building with XIM; also, rearranged a few functions. William McBrine 2006-12-12 07:11:18 +00:00
  • 1037b94288 Back to having no default compose key. If I can ever get the XIM working, it will support Multi_key itself (it works in xev). William McBrine 2006-12-12 01:30:20 +00:00
  • 0c697185cf Backspace only once on high-bit characters. William McBrine 2006-12-11 20:41:30 +00:00
  • f99b5b8564 Define HAVE_CURSES_VERSION for ncurses. William McBrine 2006-12-11 04:34:48 +00:00
  • 96a657bafd Added curses_version(), after ncurses. Also gave a better description of resize_term()... I'm counting this as fulfilling the "document resizing" item in the TODO list, although perhaps more could be said. William McBrine 2006-12-11 04:24:24 +00:00
  • 04da172154 Get all tests from ncurses; allow building view in wide mode. William McBrine 2006-12-11 03:04:33 +00:00
  • 7a306ffe22 One more. William McBrine 2006-12-09 21:43:50 +00:00
  • d19d4918af A few more combos. William McBrine 2006-12-09 21:04:24 +00:00
  • 1c00cd66c5 Added a few more compose combos; changed source code file encoding from Latin-1 to UTF-8. William McBrine 2006-12-09 20:44:07 +00:00
  • 6ebc71e8af Make Multi_key PDCurses' default compose key. William McBrine 2006-12-09 19:10:07 +00:00
  • f9ec851c79 Ignore modifier key presses while in compose state. They were breaking out of compose state, making it impossible to type accented capitals, accent grave, etc. William McBrine 2006-12-09 17:59:55 +00:00
  • 2d032b6a3a Warnings. (Uneeded warning suppression attempt leads to actual warnings.. typical.) William McBrine 2006-12-09 09:14:46 +00:00
  • f41d93de14 Comments. Much more to do. William McBrine 2006-12-08 06:21:26 +00:00
  • d3bb168b56 Use begx and begy, as elsewhere, instead of begin_x and begin_y. William McBrine 2006-12-08 03:04:41 +00:00
  • 2c07afdeeb A resize_window() that can handle subwin/subpad. William McBrine 2006-12-08 02:44:53 +00:00
  • 41cd3fd3b2 Need stdlib.h here. William McBrine 2006-12-08 01:51:18 +00:00
  • 987aafe366 Comments. William McBrine 2006-12-08 01:28:01 +00:00
  • 400fb69369 Working putwin()/getwin()/scr_etc(). Could use more testing. William McBrine 2006-12-08 01:04:21 +00:00
  • 2f433c3d85 Now resize_window() copies the new struct to the old, freeing the old lines, etc., but not the old WINDOW struct itself. This allows me to add a non-macro wresize(). Also, resize_window() now rejects attempts to resize subwindows. Should this be handled in a different way? William McBrine 2006-12-07 22:09:42 +00:00
  • c8e2c6a37f Consolidated several pieces of redundant window initialization into PDC_makelines(); use malloc() instead of calloc() here, and call werase() instead where needed (i.e., not in dupwin()). Mostly this is preparatory to a working getwin(), but it's tighter in any case. William McBrine 2006-12-07 21:29:30 +00:00
  • 2663e37ece ...and this is that separate module. William McBrine 2006-12-07 18:39:31 +00:00
  • d3c3e06c5d keyname() is so huge that it deserves a separate module. William McBrine 2006-12-07 18:39:01 +00:00
  • 4231b74251 Tightening, along the same lines as OS/2. William McBrine 2006-12-05 23:46:46 +00:00
  • 343bb01c44 Comments. William McBrine 2006-12-05 23:11:43 +00:00
  • 6b8895e4e1 Tightening. William McBrine 2006-12-05 23:10:31 +00:00
  • def4340f13 Report the position from the last press/release event instead of the current position. Shouldn't make much difference, but anyway. William McBrine 2006-12-05 21:12:25 +00:00
  • 1bdccc17bd More like this, I think -- the other way returned BUTTON_CLICKED status for untouched buttons, although .changes was set correctly. No more double-click reporting. William McBrine 2006-12-05 20:51:56 +00:00
  • f4ba2c46fa A better mouse handler for DOS, based on events rather than current status (for press/release, though not for move or scroll). Reports clicks; theoretically even reports double clicks, but I haven't been able to evoke that yet, so I might take it out. William McBrine 2006-12-05 20:37:18 +00:00
  • 3e3a8fbdef Minor corrections. William McBrine 2006-12-05 19:55:16 +00:00
  • ccf7f8c3b7 Just to be sure. William McBrine 2006-12-05 10:04:22 +00:00
  • 43674801a3 The switch/case for KEY_SHOME etc. was bogus... but so was the old way. Here's a better one, if not a good one. Also, the whole second half of the key_table isn't needed. William McBrine 2006-12-05 09:56:59 +00:00
  • 958ea4b735 With the new keyboard code, the old method of checking for 0 is not needed, nor will it work. To Do: Do we want it to work? Or should 0 not be returned? William McBrine 2006-12-04 05:35:51 +00:00
  • a00f9e0323 Got rid of the shifting. This was basically the last remnant of the split between PDC_get_bios_key() and PDC_validchar(). William McBrine 2006-12-03 15:11:10 +00:00
  • aa31157966 Here's that single key_table with no searching needed. William McBrine 2006-12-01 23:22:42 +00:00
  • 545b1be869 Passing a dummy function to XtAddEventHandler(), instead of NULL, seems to be enough to make the XIM stuff work. (God knows why the sleep(20) was there.) But I haven't tested this with anything other than my en_us locale yet, so I'm still reluctant to make this the default for PDC_WIDE. I've also changed the ifdef from FOREIGN (ugh) to PDC_XIM, and added some unrelated comments. William McBrine 2006-12-01 22:10:02 +00:00
  • d8f1322769 These calls under ifdef FOREIGN in XCursesInitscr() are (or would be) already handled by XtSetLanguageProc() (if this whole thing worked). William McBrine 2006-12-01 07:56:03 +00:00
  • edefffdbca Minor tweaks. William McBrine 2006-12-01 02:20:27 +00:00
  • 79fa975027 Changed my mind again -- only the extern functions and the actions get the "XCurses" prefix. William McBrine 2006-12-01 01:27:12 +00:00
  • 45aa35cd7d Nonsense comment. William McBrine 2006-11-30 17:37:38 +00:00
  • 024e4d3f6b Ignore my earlier comments... I still think XCursesHandleString() is kind of useless, but it's needed for backwards compatibility with old resource files that might've used the "string" action. William McBrine 2006-11-30 17:12:51 +00:00
  • 4883247ec6 Up to date list of default translations. William McBrine 2006-11-30 16:47:24 +00:00
  • e131d15154 Typo. William McBrine 2006-11-30 16:42:16 +00:00
  • dd1d90fa83 There were four different types for booleans used here: "bool", "Bool", "Boolean", and "int". Standardized on curses' "bool", except where "Boolean" appears to be required by X functions (check this). William McBrine 2006-11-30 04:47:45 +00:00
  • fa9de62e94 Function names to the style used elsewhere, except for the "XCurses"-prefixed ones; comments. William McBrine 2006-11-30 03:44:14 +00:00
  • 6e6af17f4e AFAICT, XCursesHandleString() has never been used (maybe for debugging?), and is not useful. William McBrine 2006-11-30 02:16:43 +00:00
  • e6bf28564e Make sure the XtGetSelectionValue() calls bottom out, and call XtFree() when done. To Do: I'm getting lockups when attempting to paste really long selections... can't figure it out yet. (I don't think it's a new problem, though I hadn't seen it before; I just hadn't pasted such long test texts.) William McBrine 2006-11-30 02:11:11 +00:00
  • ce6de040ba Allow selection and paste with UTF-8 even when not built with PDC_WIDE. Mainly to remove messy ifdefs. William McBrine 2006-11-29 02:52:43 +00:00
  • 1efa16ca75 Allow pasting via XA_UTF8_STRING in X11. William McBrine 2006-11-29 02:36:15 +00:00
  • 56be2161dc Oops... in DOS and OS/2, modifier keys weren't being returned unless they followed a key with modifiers held, or another (or the same) modifier key. William McBrine 2006-11-28 20:50:07 +00:00
  • 52c5c42248 An even more compact representation. To Do: A single table with no lookup needed would be even better, but it's a pain to rearrange everything. William McBrine 2006-11-28 19:15:04 +00:00
  • c672e81cb4 Using unsigned shorts saves space here, too, on platforms with 32-bit ints. William McBrine 2006-11-27 21:08:23 +00:00
  • 9232c9c0b6 Fewer casts; more sensible representation of data; removed potential problems with high-bit chars (not tested). William McBrine 2006-11-27 17:37:34 +00:00
  • d46beb0e97 Properly handle pasting of high-bit chars. (It was doing an unwanted sign extension.) William McBrine 2006-11-27 17:14:43 +00:00
  • 5841fee966 With recent changes, keys like Enter could show up with SP->key_code incorrectly set TRUE. To Do: The way keypad() is used in PDCurses really isn't correct. Setting it to FALSE isn't intended to ignore these keys, just to return them as their individual components -- ESC [ A, for example. But this is meaningless in PDCurses. Should the distinction be eliminated? Should keypad at least default to TRUE? William McBrine 2006-11-27 17:06:00 +00:00
  • 9dceb7fa81 Use void prototypes for XC_{read,write}_socket(); no more (char *) casts in calls to these functions. William McBrine 2006-11-27 04:23:26 +00:00
  • ed9f116d56 Better description of the attributes. May need more work. William McBrine 2006-11-25 19:09:56 +00:00
  • 1ffb2d2eb5 Rearrangement; comments. William McBrine 2006-11-25 17:18:27 +00:00
  • 0ac4e2d5e6 Minor tweaks; comments. To Do: At one point while working on this, I seemed to get doubling of the arrow keys in testcurs; but I couldn't reproduce it. :-( William McBrine 2006-11-25 06:06:15 +00:00
  • 399436cdc4 Set key_code false only when actually returning ascii. William McBrine 2006-11-24 14:04:56 +00:00
  • 5d0bb2c7b4 Minor tightening; comments. William McBrine 2006-11-24 13:47:21 +00:00
  • f026d7aed8 In wgetch(), delay after a failed call to PDC_check_bios_key(), but recycle immediately after a bad result from PDC_get_bios_key(). This means no waiting when there are keys in the buffer that just aren't desired; it fixes the incredibly slow pasting I got with Unicode text in Win32. William McBrine 2006-11-24 05:05:40 +00:00
  • d2f7b9926b Moved ReadConsoleInput to PDC_get_bios_key(), where it belongs. Which allows me to do this... William McBrine 2006-11-24 05:02:17 +00:00
  • d112fee6cb Simplified. More to do. William McBrine 2006-11-24 04:43:04 +00:00
  • fdd76de153 Removed all references to AsciiChar in favor of UnicodeChar. It's a union, so the lower eight bits are the same even when not built for Unicode. William McBrine 2006-11-24 03:21:59 +00:00
  • d1a3626d75 OK, for whatever reason, the console paste mechanism simulates an ALT-keypad entry for (I think) keys outside the normally-typeable range. Here's the simple way to correctly handle both Unicode input AND ALT-keypad entry. To Do: Test that dead key stuff; simplify. William McBrine 2006-11-23 20:27:23 +00:00
  • f2a60f3fa1 Separate left/right modifier keys reported properly. (The attempt that was there, never worked; everything was reported as _R.) William McBrine 2006-11-21 22:46:46 +00:00
  • 02040f9ff4 Need a const on the ch parameter to waddch() -- silly X/Open. I also took this opportunity to ensure that any control characters with attributes have their attributes passed through when printed. William McBrine 2006-11-21 20:46:23 +00:00