Commit graph

847 commits

Author SHA1 Message Date
Charlie Gordon
0f1d2244e7 basic: improve config file handling
- add `add-resource-path(string)` to add a new resource directory
- bind `load-file-from-path` on C-c C-f
2016-12-31 18:45:08 +00:00
Charlie Gordon
bfe0b5f528 dired: only output previewing message from filelist 2016-12-31 11:29:38 +00:00
Charlie Gordon
dee4908fe8 display: disable broken bidir display 2016-12-31 11:28:41 +00:00
Charlie Gordon
f4c1b633a9 search: improvements
- C-u C-s selects regex searching (not yet implemented)
- `do_isearch()` takes extra argument for argval
- cycle hex and unihex isearch modes on M-C-b instead of C-b and M-b
- toggle regex incremental searching on C-t and M-r
- C-j no longer needs quoting in isearch
- no longer keep lingering search matches after search exits
2016-12-31 11:25:25 +00:00
Charlie Gordon
94464bd939 dired: add filelist mode
- add `WF_FILELIST` window flag for preview-mode tests
- add `argval` argument to `do_dired()`
- `dired_view_file()` displays message and returns preview pane
- `dired` command with argument selects filelist mode with navigation pane
  bound to C-u C-x C-d
- add `filelist` command
2016-12-31 11:12:16 +00:00
Charlie Gordon
b28a387889 build: fix X11 rules on OpenBSD
- applied patch by Han Boetes
- scan standard places for X11 includes and libraries
- do not link with -ld on OpenBSD
2016-12-28 07:39:45 +00:00
Charlie Gordon
87a151fd95 comments 2016-12-27 12:31:36 +00:00
Charlie Gordon
f74938305c build: improvements
- generate libqhtml object files in target dependant directories
- make multiple targets coexist
- fix .cvsignore file
- fix clean and distclean targets
2016-12-27 11:40:40 +00:00
Charlie Gordon
6cd406d5e3 html2png: fixed compilation warning 2016-12-27 11:38:36 +00:00
Charlie Gordon
f41235695f display: some fixes, simplifiations
- add `gutter_width` in `DisplayState` for line number column
- add `int get_glyph_width(QEditScreen *screen,
                           EditState *s, int style_index, int c);`
  and `int get_line_height(QEditScreen *screen,
                           EditState *s, int style_index);`
  to compute font dimensions from style index and window
- compute borders more accurately in `display_window_borders()`
- clip text drawing, use window relative coordinates in `flush_line()`
- fix width computation for diagnostic status display in X11
- use QE_STYLE_DEFAULT and remove redundant e->default_style references
2016-12-27 10:13:46 +00:00
Charlie Gordon
5bc6133fb3 sorting: add support for dictionary order
- improved stability, works for reverse-sort
- simplified reverse sort handling
- select dictionary order via C-u 2 A-x sort-buffer
2016-12-26 15:01:58 +00:00
Charlie Gordon
8587dd62a2 display: improve handling of very long lines
- simplify the code
- fix display of continuation lines when line numbers are visible
2016-12-26 13:57:36 +00:00
Charlie Gordon
2d984bbbd5 display: improve handling of very long lines
- simplify the code
- fix display of continuation lines when line numbers are visible
2016-12-26 13:44:42 +00:00
Charlie Gordon
bd5086c85c build: remove c99 specific constructions 2016-12-26 09:28:36 +00:00
Charlie Gordon
433d6bec4f x11: add x11-list-fonts on C-h f 2016-12-25 23:39:30 +00:00
Charlie Gordon
7969fbb276 build: use separate object directory for x11 build
- configure no longer defines CONFIG_X11 in C
- generate modules.txt in each target directory
2016-12-25 23:32:48 +00:00
Charlie Gordon
862119faf3 use character width in graphics mode for dired layout 2016-12-25 11:31:16 +00:00
Charlie Gordon
be9f03731e basic: use our own version of qsort_r
- add `qe_qsort_r()` because some platforms do not provide `qsort_r()`
  it uses a median of 3 pivot selection and falls back to insert sort
  for small chunks.
- use `qe_qsort_r()` in dired, remove `state` field in `DirEntry`
- use `qe_qsort_r()` in sort-buffer commands
- make buffer sorting algorithm stable
2016-12-25 10:51:14 +00:00
Charlie Gordon
f9ebd10d55 display: simplifications and comments
- add remarks about tricky display internal states
- display `x_disp[]` on mode-line
2016-12-23 22:51:47 +00:00
Charlie Gordon
4e1cb3cf37 display: improvements
- pass `cursor_func` and `cursor_opaque` to `display_init()`
- add dummy `display_close()`
- add `DISP_NONE` display mode
- fix timing message display, trim *messages* buffer
2016-12-23 20:28:56 +00:00
Charlie Gordon
ef3974ecdd buffer: improvements
- fixed `do_forward_block()` to handle very long lines gracefully
- simplified `to_transpose()`
- add `do_describe_window()` for `describe-window` command on C-h w
2016-12-23 20:12:05 +00:00
Charlie Gordon
79bf90c8d6 basic: simplifications
- remove `eb_nextc_style()`
- `eb_nextc()` does not modify `b->cur_style`
- add `eb_get_style()` to retrieve style for given offset in full-style buffers
- add `eb_next()` and `eb_prev()` to skip chars
- pass `offset` to `eb_get_line()` and `generic_get_colorized_line()`...
- use `eb_skip_chars()` in `do_delete_char()` and `text_write_char()`
- replaced `eb_get_strline()` with `eb_fgets()` with similar semantics
  except return value is number of bytes before the newline or end of line
- no longer pass end offset to `isearch_colorize_matches()`
- just pass number of code points to `combine_static_colorized_line()`
- no longer call `isearch_colorize_matches` from `generic_get_colorized_line`
2016-12-23 19:51:48 +00:00
Charlie Gordon
374b514528 display: small improvements
- rename method dispatcher `text_display` as `display_line`
  rename corresponding mode based handlers as `xxx_display_name`
- rename method dispatcher `text_backward_offset` as `backward_offset`
- add default text handlers for `move_bof` and `move_eof` in
  hex, binary and unihex modes
- handle utf-8 in window prompt (ex: default buffer name for C-x b)
- add various TODOs
2016-12-23 15:51:51 +00:00
Charlie Gordon
9c99730239 display: cursor handling
- merge do_center_cursor and do_center_cursor_maybe:
  do_center_cursor takes an `int force` argument
- add set-window-style command to change `e->default_style`
- change argument sign for do_scroll_left_right() for consistency
  scroll window by increments of space_width
  toggle WRAP_LINE, WRAP_WORD and WRAP_TRUNCATE in do_scroll_left_right()
- do not force WRAP_TRUNCATE in dired view pane to avoid problems on files
  with extremely long lines
2016-12-23 13:00:55 +00:00
Charlie Gordon
e479e31c1d modes: small improvements
- prevent ini_mode to match JSON files
- add ".Sql" extension for sql_mode
- add `protected`, `$this`, `as`, `null` and builtin functions as PHP keywords
2016-12-23 12:21:46 +00:00
Charlie Gordon
e4dbd08a7f clang: prevent auto indentation on electric keys if auto-indent is disabled 2016-12-23 12:05:22 +00:00
Charlie Gordon
e23ca54413 latex: simplified do_tex_insert_quote() 2016-12-23 09:51:40 +00:00
Charlie Gordon
02222297bd simplified buf_write() and buf_putc_utf8() 2016-12-23 09:47:11 +00:00
Charlie Gordon
71ab83a208 display: optimize low level buffer content read functions
- remove style handling from eb_nextc()
- add eb_nextc_style()
2016-12-13 17:20:51 +00:00
Charlie Gordon
8124c44bc9 extras: added sorting commands:
- sort-buffer, reverse-sort-buffer, sort-region, reverse-sort-region
2016-12-13 13:29:31 +00:00
Charlie Gordon
7397760c8e fixed crash bug in do_forward_block for very long lines 2016-12-13 13:26:16 +00:00
Charlie Gordon
f28acb6b4c added js specific colorizer for speed on large json files 2016-12-13 09:10:47 +00:00
Charlie Gordon
214d02c67b improve current directory handling for shell mode
- get_default_path() takes buffer and offset instead of window
- mode specific handler returns NULL is current directory cannot be determined
- set EditBuffer->default_mode upon creating buffer_mode_data
- add ShellState->curpath to hold shell buffer current directory
- add shell_get_curpath to parse shell output for current directory
  in shell prompt, check if dir actually exists.
- update shell directory upon enter key.
  should instead keep a list with validity ranges
2016-11-26 11:30:29 +00:00
Charlie Gordon
04ea9124ad update lua keywords 2016-11-26 11:12:27 +00:00
Charlie Gordon
6bd3766a70 update TODO list 2016-11-26 11:10:12 +00:00
Charlie Gordon
18c5c1c088 add virgil language colorizer 2016-11-26 11:08:38 +00:00
Charlie Gordon
aa437115f8 add virgil language colorizer 2016-11-26 11:01:55 +00:00
Charlie Gordon
f9783afdc6 add virgil language colorizer 2016-11-26 11:00:42 +00:00
Charlie Gordon
e0961c3a4e completion: improve popup window handling
- fix completion popup current selection display
- TAB toggles completion popup open/close if there are matches
- SPC opens the completion popup and pages down through matches
- add non ambiguous completion as highlighted region in mini-nbuffer
- adding more characters with popup active rescans and filters list
- remove completion popup as more typing occurs without a match
2016-07-29 11:20:08 +00:00
Charlie Gordon
cb3f1a1f61 edit: delete or kill the highlighted region automatically
- typing now first deletes the highlighted region
- delete-char and backward-delete-char delete the highlighted region if any.
- kill-line kills the highlighted region if any.
- yank first deletes the highlighted region
2016-07-29 11:04:31 +00:00
Charlie Gordon
e87bac0f37 x11: fix compilation without Xshm
- patches by Francois Revol to allow compilation in some
  X11 environments without Xshm support.
2016-07-26 09:43:14 +00:00
Charlie Gordon
9f693f5aa3 clang: prevent crash bug if tab-width is set to 0 2016-07-15 14:49:03 +00:00
Charlie Gordon
92f31a2ce3 use new style parser for pascal colorizer 2016-07-12 07:50:19 +00:00
Charlie Gordon
a4247a878f dired: improve current directory support
- pass EditPane to canonicalize_absolute_path() to make current directory
  context based.
- use shell buffer context based directory for next-error.  Should actually
  use more context such as current position to compute current directory.
- move canonicalize_absolute_path() and is_abs_path() from util.c to qe.c
2016-06-26 08:35:25 +00:00
Charlie Gordon
8bd15ce4aa dired: support file patterns, improve current directory support
- add `is_filepattern` utility function to check for wildcards
- add `get_default_path` public function to retrieve the context specific
  current directory associated with a window.
- explore directories and file patterns in dired window
- compare-files determines parent file from current directory
- accept file patterns for dired listing
2016-06-13 17:12:35 +00:00
Charlie Gordon
fd49b712a2 x11 patches
- merged patches by Clemmit Sigler
- handle shifted keys in x11 mode
- install xqe if CONFIG_X11
2016-06-11 15:55:46 +00:00
Charlie Gordon
d5e10dfe77 update copyrights, TODO list 2016-06-09 16:24:10 +00:00
Charlie Gordon
9faeebcfdd build: fix warnings in linux 2016-06-08 00:35:04 +00:00
Charlie Gordon
31f4362ce2 shell: improve shell editing, yank kill buffer at shell prompt
- add mode specific `delete_bytes()` method
- reorder `write_char()` and `mouse_goto()` mode methods
- pass `keep` argument to `do_kill()`
- pass `argval` to `do_kill_line()`
- add `do_kill_beginning_of_line()` command
- allow kill commands in read-only buffers, copies contents to kill-ring and
  moves point.
- change `do_kill_line()` semantics when invoked with numeric argument
- add `cur_prompt` and `last_char` in ShellState to track start of
  shell input line
- C-a moves to start of shell input, exits interactive mode if there already
- force interactive mode on shell-end-of-line and shell-end-of-buffer
- simplify shell_write_char(), remove hard coded dispatcher
- add `shell_delete_bytes()` to delete contents in shell input line
- change shell-kill-word and shell-kill-line to not rely on mode specific
  cursor movement commands because of asynchronous behavior.  This is also
  a problem for macros
- make shell-yank insert data via shell input.
- pause for 1ms after each CR sent to the process
2016-06-07 08:56:39 +00:00
Charlie Gordon
4e653889ab dired: load directories in dired pane 2016-06-07 06:50:44 +00:00