Commit graph

146 commits

Author SHA1 Message Date
Charlie Gordon
2ce9cd8aab added styles string-q and number 2007-12-15 07:27:45 +00:00
Charlie Gordon
915a19edb2 added and improved some buffer functions:
renamed eb_get_str to eb_get_contents
fixed buffer size issues in eb_get_line
fixed utf-8 issues in eb_get_strline
added eb_prev_line
added eb_goto_bol2: computes number of code points skipped
added eb_goto_eol
2007-12-15 07:24:03 +00:00
Charlie Gordon
f9f6b42059 fixed subtle bug in qe_realloc: store NULL ptr upon realloc to size 0 2007-12-13 23:13:11 +00:00
Charlie Gordon
26ea3f69a0 added wrappers and utilities for safer memory allocation:
type *qe_malloc(type);
type *qe_mallocz(type);
type *qe_malloc_array(type, count);
type *qe_mallocz_array(type, count);
type *qe_malloc_hack(type, extra_bytes);
type *qe_mallocz_hack(type, extra_bytes);
void qe_free(&ptr);
void *qe_realloc(&ptr, new_size);
char *qe_strdup(const char *str);
void *qe_malloc_bytes(size_t size);
void *qe_mallocz_bytes(size_t size);
void *qe_malloc_dup(const void *src, size_t size);

pass pointer address to bmp_free()
2007-12-12 11:49:02 +00:00
Charlie Gordon
7817049123 cosmetics 2007-12-12 08:51:02 +00:00
Charlie Gordon
57c3461e0d simplified set_color API, made in inline
improved command parsing, refined argval handling, pass as optional arg
pass command arguments as an array of unions
use correct type in command dispatcher (upto 2 arguments)
merged do_goto_byte, do_goto_line, do_goto_char, extend syntax
fixed kill commands: kills are appended/prepended to kill buffer
added append_next_kill command
added do_kill_line (split from do_kill_region)
added do_kill_word (removed do_delete_word)
added do_kill_paragraph
pass argval to do_backspace and do_delete_char, fix kill behaviour
fixed kill-ring initial state bug
fixed do_yank: set mark and this_cmd_func
fixed do_yank_pop: test last_cmd_func, use eb_delete instead of do_undo
fixed do_yank_pop kill-ring bug
added clamp(int x, int min, int max);
added qs->this_cmd_func so commands can override qs->last_cmd_func
allow KEY_ESC + extended key as command binding
added do_c_forward_block, needs rewrite using colorization code
added do_c_kill_block
added insert-char command (argval repeats instead of forcing char value)
renamed delete-word to kill-word
renamed backward-delete-word to backward-kill-word
added kill-beginning-of-line
2007-12-12 02:51:05 +00:00
Charlie Gordon
83f3ec16c3 typo 2007-12-12 02:24:33 +00:00
Charlie Gordon
2eb5a83259 fixed some meta ctrl key combinations in x11 2007-12-12 02:21:45 +00:00
Charlie Gordon
0507ffacc3 fixed function key mapping issues in X11 and Wndz
fixed C lang colorizer for some multiline stuff, wide char/strings
use countof() macro
cosmetics
2007-12-10 13:28:07 +00:00
Charlie Gordon
855660ae1f added missing C keywords and types 2007-12-10 11:03:36 +00:00
Charlie Gordon
612fa09e79 updated TCVN.TXT from yudit 2.8.1 2007-12-10 10:22:10 +00:00
Charlie Gordon
ed5052c99b use yudit TCVN.TXT file 2007-12-10 10:12:11 +00:00
Charlie Gordon
3695abe5b6 added more Hebrew keymaps
support multiple output for input methods
colorize function calls in C mode
2007-12-09 23:31:38 +00:00
Charlie Gordon
2d86be74a1 fixed bug in kmap loader 2007-12-07 12:06:42 +00:00
Charlie Gordon
a064ff97a0 more ctype unsigned char fixes 2007-12-06 17:59:23 +00:00
Charlie Gordon
d286b27756 made more local variables static
fixed bug in cfb32_fill_rectangle
use c99 syntax for new style struct initializers instead of gcc specific
simplified tolower unsigned char hacks
fixed various sparse warnings
2007-12-06 17:43:47 +00:00
Charlie Gordon
0446a52d21 added more charsets
simplified charset alias system
reorganized charset functions
groomed completion functions
2007-12-06 15:28:29 +00:00
Charlie Gordon
83dc067f86 imported mapping files from Unicode and other sources
removed redundant cp files
fixed charsets (8859-7 version 2003)
improved cptoqe.c
added index file cpdata.txt
2007-12-06 09:50:03 +00:00
Charlie Gordon
0f01d80609 reordered charsets 2007-12-05 10:32:11 +00:00
Charlie Gordon
b82cea744d small simplifications, remarks
small fixes and extra info in code page files
2007-12-05 08:49:38 +00:00
Charlie Gordon
71f55ca730 handle extra kmaps
fixed numerous bugs in kmaptoqe.c: handle \ syntax and report errors.
disable HebrewIsraeli.kmap and Kana.kmap because of partial support
2007-12-04 23:08:46 +00:00
Charlie Gordon
500161856e imported kmap files from yudit 1.6 2007-12-04 09:22:50 +00:00
Charlie Gordon
36567230e2 added charsetjis.c and charsetjis.def
moved code from charsetmore.c to charset.c and charsetjis.c
separate JIS table generation into jistoqe.c, make it generate charsetjis.def
2007-12-03 16:16:24 +00:00
Charlie Gordon
134ced6963 removed charset_table.c
added charsetjis.c and charsetjis.def
moved code from charsetmore.c to charset.c and charsetjis.c
improved cp parser cptoqe.c, make it generate charsetmore.c
small changes in QECharset structure: added eol_char and made aliases const
removed redundant QECharset declarations from qe.h
separate JIS table generation into jistoqe.c, make it generate charsetjis.def
updated Makefile, .cvsignore
improved fbftoqe.c
improved kmaptoqe.c, added --dump option
added argc, argv to QEmacsState
improved set_user_option: put runtime and user directories in front of res_path
added some missing file headings
2007-12-03 16:15:01 +00:00
Charlie Gordon
4937be13b6 cosmetics 2007-12-03 16:12:40 +00:00
Charlie Gordon
6c65411200 added missing headings, cosmetics 2007-12-03 16:10:38 +00:00
Charlie Gordon
c150f0a9a7 Added missing headings
Cosmetics
Fixed Makefile details
2007-12-03 10:40:21 +00:00
Charlie Gordon
9fdbca2c87 Imported original code page and keyboard map files
Fixed Makefile
Fixed .cvsignore
2007-12-03 10:18:33 +00:00
Charlie Gordon
0e1cfa053a report correct column number in terminal emulation, fixed crash bug on TAB in process buffer non interactive mode 2007-02-07 23:28:36 +00:00
Charlie Gordon
4dee871155 delayed terminal utf8 capability detection so qe no longer leaves 2 weird character on terminal upon leaving 2007-02-07 23:27:33 +00:00
Charlie Gordon
a0bfcd45bd fixed unsigned char issues
added TODOs
bumped version to 0.4.0dev
mention chqrlie in --version
cosmetics: reindented Makefile
2007-02-06 17:41:16 +00:00
Charlie Gordon
eb3afbb862 renamed do_less_quit() to do_less_exit() for consistency with command name
fixed crash in do_less_exit() when invoking "less-exit" with A-x
fixed c auto-indenter to not move point unless within the indent space
fixed the electric-c mode
2007-01-12 15:06:16 +00:00
Charlie Gordon
494e9f7866 include cflags.mk for extra gcc warnings if present
utf8_encode now returns the number of characters copied,
  simplified code accordingly
made local functions static
tagged unused function arguments
fixed shadowing issues
added support for GCC attributes for unused arguments and format strings
use snprintf() instead of sprintf()
moved scattered declarations to qe.h
removed duplicate declarations in header files
eb_write() payload argument is now const
fixed crash bug: reset trace_buffer upon deletion
improved trace_buffer readability: trace all pseudo tty streams separately
added missing structure initializers
removed buffered string handling from cutils.h
added new buffered string API for statically allocated buffers (should unify)
small improvements in X11 initialization
improved consistency in tty.c (function names...)
  added STDIN and STDOUT streams in QEditScreen to stop using stdin and stdout
  use unlocked stream I/O if available (faster)
  changed and documented terminal setup and exit sequences
  improved charset handling
mode_line functions now return the character count (like snprintf)
2006-12-31 19:34:00 +00:00
Charlie Gordon
45636730b0 include cflags.mk for extra gcc warnings if present
utf8_encode now returns the number of characters copied
simplified code accordingly
made local functions static
fixed shadowing issues
added __attr_printf() attributes for gcc to check printf arguments
use snprintf() instead of sprintf()
2006-12-28 11:27:30 +00:00
Charlie Gordon
b47f7998df allocate tty screen and shadow buffer in the same block
use various simple techniques to reduce tty refresh traffic
2006-12-12 01:03:03 +00:00
Charlie Gordon
714157c255 added TTY_STATE_STRING state to ignore escape string sequences
improved tty_goto_xy() [renamed from tty_gotoxy()] x and y can be specified
   as relative independently
fixed bug on relative y argument: caused bogus display
fixed another bug in tty_goto_xy() : caused last non blank character on row
   to be missing sometimes.
factorized code
added comments about many more colors and escape sequences
made ^H erase the character on the left (back_color_erase capability)
simplified CSI escape sequence parsing, default argument values to 1
added support for alt_charset_mode with 32 char kludge
ignore set-window-title xterm command: \E]0xxxxxxx\007
added \E[xG (goto_column_address) and \E[xd (goto y)
implement \E[xX erase n characters
document \E[y;xr change_scroll_region, still unimplemented
2006-12-11 23:35:45 +00:00
Charlie Gordon
0fe70595b6 simplified bogus utf-8 terminal test
fixed bogus tty_resize() : used to fill screen buffer attribute slots with
  invalid values, causing spurious ????? output on ^L
simplified tracing of tty input
improved term_flush(), further improvements pending.
2006-12-11 23:24:59 +00:00
Charlie Gordon
1c91b22914 moved charset_complete() to charset.c
added do_set_trace()
added mode_completion()
simplified command_completion()
simplified style_completion()
simplified buffer_completion()
fixed bogus terminal display for character ^? (DEL or 127)
2006-12-11 23:21:04 +00:00
Charlie Gordon
3fa9f0ab84 moved charset_complete() to charset.c
made charset names case insensitive (also ignore spaces, dashes, underscores)
2006-12-11 23:17:03 +00:00
Charlie Gordon
cc82df1fa4 moves basic types to top of declarations
added missing prototypes
added eb_find_window()
added eb_trace_bytes() trace_buffer_state and EB_TRACE_TTY, EB_TRACE_SHELL
  for trace buffer management.
2006-12-11 23:15:42 +00:00
Charlie Gordon
685d35964f added set-trace command 2006-12-11 23:11:31 +00:00
Charlie Gordon
fac6bd9acf added eb_find_window()
added eb_trace_bytes()
improved eb_printf(): removed potential buffer overflow
2006-12-11 23:10:33 +00:00
Charlie Gordon
7128c65b41 use 20% of width for dired/bufed modes 2006-12-11 23:08:50 +00:00
Charlie Gordon
e120f926a6 simplified completion enumerators 2006-12-11 23:07:58 +00:00
Charlie Gordon
4f5fc748c6 more TODOs about colors and tty emulation 2006-12-11 23:05:01 +00:00
Charlie Gordon
e549c9ae96 made color names case insensitive, simplified color_completion 2006-12-11 23:04:21 +00:00
Charlie Gordon
20c9993c3d changed stristart to ignore space, - and _
addded stricmp: same as strcasecmp, and ignore , - and _
2006-12-11 23:03:21 +00:00
Charlie Gordon
d447798717 added missing licence header
fixed typos
added constness
comments about potential problems
identified 64 bit portability problem
fixed small issue in get_default_path()
allow signed numbers in config file
added comments about old code for reference (tty.c, shell.c)
2006-12-09 19:47:20 +00:00
Charlie Gordon
c402c17a7a fixed typos, added comments about potential problems 2006-12-09 19:04:15 +00:00
Charlie Gordon
3551c36226 fixed typos, comments 2006-12-09 19:02:07 +00:00