You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

43 lines
1.5 KiB

  1. #pragma once
  2. #include "terminal.h"
  3. #define SIXEL_MAX_COLORS 1024u
  4. void sixel_fini(struct terminal *term);
  5. void sixel_init(struct terminal *term);
  6. void sixel_put(struct terminal *term, uint8_t c);
  7. void sixel_unhook(struct terminal *term);
  8. void sixel_destroy(struct sixel *sixel);
  9. void sixel_destroy_all(struct terminal *term);
  10. void sixel_scroll_up(struct terminal *term, int rows);
  11. void sixel_scroll_down(struct terminal *term, int rows);
  12. void sixel_cell_size_changed(struct terminal *term);
  13. void sixel_reflow(struct terminal *term);
  14. /*
  15. * Remove sixel data from the specified location. Used when printing
  16. * or erasing characters, and when emitting new sixel images, to
  17. * remove sixel data that would otherwise be rendered on-top.
  18. *
  19. * Row numbers are relative to the current grid offset
  20. */
  21. void sixel_overwrite_by_rectangle(
  22. struct terminal *term, int row, int col, int height, int width);
  23. void sixel_overwrite_by_row(struct terminal *term, int row, int col, int width);
  24. void sixel_overwrite_at_cursor(struct terminal *term, int width);
  25. void sixel_colors_report_current(struct terminal *term);
  26. void sixel_colors_reset(struct terminal *term);
  27. void sixel_colors_set(struct terminal *term, unsigned count);
  28. void sixel_colors_report_max(struct terminal *term);
  29. void sixel_geometry_report_current(struct terminal *term);
  30. void sixel_geometry_reset(struct terminal *term);
  31. void sixel_geometry_set(struct terminal *term, unsigned width, unsigned height);
  32. void sixel_geometry_report_max(struct terminal *term);