selection.h 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. /*
  3. * selection.h
  4. *
  5. * Interface between console.c, tty_io.c, vt.c, vc_screen.c and selection.c
  6. */
  7. #ifndef _LINUX_SELECTION_H_
  8. #define _LINUX_SELECTION_H_
  9. #include <linux/tiocl.h>
  10. #include <linux/vt_buffer.h>
  11. struct tty_struct;
  12. struct vc_data;
  13. extern void clear_selection(void);
  14. extern int set_selection_user(const struct tiocl_selection __user *sel,
  15. struct tty_struct *tty);
  16. extern int set_selection_kernel(struct tiocl_selection *v,
  17. struct tty_struct *tty);
  18. extern int paste_selection(struct tty_struct *tty);
  19. extern int sel_loadlut(char __user *p);
  20. extern int mouse_reporting(void);
  21. extern void mouse_report(struct tty_struct * tty, int butt, int mrx, int mry);
  22. bool vc_is_sel(struct vc_data *vc);
  23. extern int console_blanked;
  24. extern const unsigned char color_table[];
  25. extern unsigned char default_red[];
  26. extern unsigned char default_grn[];
  27. extern unsigned char default_blu[];
  28. extern unsigned short *screen_pos(const struct vc_data *vc, int w_offset,
  29. bool viewed);
  30. extern u16 screen_glyph(const struct vc_data *vc, int offset);
  31. extern u32 screen_glyph_unicode(const struct vc_data *vc, int offset);
  32. extern void complement_pos(struct vc_data *vc, int offset);
  33. extern void invert_screen(struct vc_data *vc, int offset, int count, bool viewed);
  34. extern void getconsxy(const struct vc_data *vc, unsigned char xy[static 2]);
  35. extern void putconsxy(struct vc_data *vc, unsigned char xy[static const 2]);
  36. extern u16 vcs_scr_readw(const struct vc_data *vc, const u16 *org);
  37. extern void vcs_scr_writew(struct vc_data *vc, u16 val, u16 *org);
  38. extern void vcs_scr_updated(struct vc_data *vc);
  39. extern int vc_uniscr_check(struct vc_data *vc);
  40. extern void vc_uniscr_copy_line(const struct vc_data *vc, void *dest,
  41. bool viewed,
  42. unsigned int row, unsigned int col,
  43. unsigned int nr);
  44. #endif