Skip to content

Termal v2.0.0

Choose a tag to compare

@BonnyAD9 BonnyAD9 released this 28 Jan 14:48
· 283 commits to master since this release

New features

  • New methods for Terminal: has_input, wait_for_input,
    read_ambiguous_timeout, read_timeout, read_raw, read_raw_timeout,
    read_raw_single_timeout and read_byte_timeout.
  • Add texels - drawing images using charactes.
  • Add option for nearest when scaling image.
  • Add new codes.
  • Parse mouse events (classic, SGR, UTF-8, URXVT).
  • Parse focus events.
  • Parse cursor position responses.
  • Parse terminal name response.
  • Parse terminal window parameters responses.
  • Add code for setting the scroll region.
  • Add codes to insert and delete lines, chars and columns.
  • Add option for universal terminal reset and to regiester panic hook with that
    reset.
  • Reader can now edit text.
  • Reader can have prompt.
  • More methods on reader.
  • Add best effort readline functions: prompt_to, prompt, read_line_to and
    read_line.
  • Add new codes: DONT_LIMIT_PRINT_TO_SCROLL_REGION and
    LIMIT_PRINT_TO_SCROLL_REGION.
  • Add new methods to Terminal to make it work as generic.
  • Add WaitForIn trait.
  • Add IoProvider trait.
  • Add StdioProvider trait.
  • Add ValueOrMut to make IoProvider possible.
  • Add SS3 code.
  • Add code OVERLINE, also add to print macros as overline/ol. (also add
    reset codes)
  • Add codes to enable and disable inverse color in whole terminal.
  • Add option to enable bracketed paste mode (pasted text is verbatim).
  • Support bracketed paste mode in terminal.
  • Add codes to set and reset the underline color (rgb an 256) and their codes
    to format macros (uc/ucolor, #RGBu, _uc/_ucolor).
  • Add codes to change the character size for current line (
    DUBLE_CHAR_HEIGHT_DOWN, DOUBLE_CHAR_HEIGHT_UP, DOUBLE_CHAR_WIDTH,
    RESET_CHAR_SIZE)
  • Add generic code macros: graphic, osc, enable and disable.
  • Add osc codes: request_color_code!, reset_color_code!,
    define_color_code, set_default_fg_color, set_default_bg_color,
    set_cursor_color, RESET_ALL_COLOR_CODES, RESET_DEFAULT_FG_COLOR,
    RESET_DEFAULT_BG_COLOR, RESET_CURSOR_COLOR, REQUEST_DEFAULT_FG_COLOR,
    REQUEST_DEFAULT_BG_COLOR, REQUEST_CURSOR_COLOR, REQUEST_SELECTION,
    request_selection and set_selection. Also parse their respective
    responses.
  • Reader now supports paste with Ctrl+v.

Breaking changes

  • Move around some logic around sixels.
  • Refactor readers.
  • Split into features.
  • Windows support (untested).
  • Make Terminal generic.
  • Make TermRead more generic.
  • Implement Eq for AmbigousEvent and all sub structs.
  • Support control characters in TermRead.
  • Use the rgb type for gradient.
  • Implement new methods for rgb.

Fixes

  • Fix publicity of macro codes::move_up.
  • Macros in codes now evaluate their arguments only once. (also fixes
    affected codes in color macros)
  • Fix move_to and mt in color marcros.
  • Fix delete_lines, insert_columns, set_down and set_up codes.
  • Recognize amiguity with Ctrl+Delete and Alt+d.
  • Fix name of codes::OSC.
  • Fix codes ENABLE_MOUSE_XY_ALL_TRACKING and DISABLE_MOUSE_XY_ALL_TRACKING.
  • Fix panic when terminal would send some invalid URXVT sequences.

Other

  • Add unit tests.