root/src/haikuselect.h

/* [<][>][^][v][top][bottom][index][help] */

INCLUDED FROM


     1 /* Haiku window system selection support. Hey Emacs, this is -*- C++ -*-
     2    Copyright (C) 2021-2023 Free Software Foundation, Inc.
     3 
     4 This file is part of GNU Emacs.
     5 
     6 GNU Emacs is free software: you can redistribute it and/or modify
     7 it under the terms of the GNU General Public License as published by
     8 the Free Software Foundation, either version 3 of the License, or (at
     9 your option) any later version.
    10 
    11 GNU Emacs is distributed in the hope that it will be useful,
    12 but WITHOUT ANY WARRANTY; without even the implied warranty of
    13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    14 GNU General Public License for more details.
    15 
    16 You should have received a copy of the GNU General Public License
    17 along with GNU Emacs.  If not, see <https://www.gnu.org/licenses/>.  */
    18 
    19 #ifndef _HAIKU_SELECT_H_
    20 #define _HAIKU_SELECT_H_
    21 
    22 #ifdef __cplusplus
    23 #include <cstdio>
    24 #else
    25 #include <stdio.h>
    26 #endif
    27 
    28 #include <SupportDefs.h>
    29 
    30 enum haiku_clipboard
    31   {
    32     CLIPBOARD_PRIMARY,
    33     CLIPBOARD_SECONDARY,
    34     CLIPBOARD_CLIPBOARD
    35   };
    36 
    37 #ifdef __cplusplus
    38 extern "C"
    39 {
    40 #endif
    41 /* Defined in haikuselect.c.  */
    42 extern void haiku_selection_disowned (enum haiku_clipboard, int64);
    43 
    44 /* Defined in haiku_select.cc.  */
    45 extern void be_clipboard_init (void);
    46 extern char *be_find_clipboard_data (enum haiku_clipboard, const char *, ssize_t *);
    47 extern void be_set_clipboard_data (enum haiku_clipboard, const char *, const char *,
    48                                    ssize_t, bool);
    49 extern bool be_clipboard_owner_p (enum haiku_clipboard);
    50 extern void be_update_clipboard_count (enum haiku_clipboard);
    51 
    52 extern int be_enum_message (void *, int32 *, int32, int32 *, const char **);
    53 extern int be_get_message_data (void *, const char *, int32, int32,
    54                                 const void **, ssize_t *);
    55 extern int be_get_refs_data (void *, const char *, int32, char **);
    56 extern int be_get_point_data (void *, const char *, int32, float *, float *);
    57 extern uint32 be_get_message_type (void *);
    58 extern void be_set_message_type (void *, uint32);
    59 extern void *be_get_message_message (void *, const char *, int32);
    60 extern void *be_create_simple_message (void);
    61 extern int be_add_message_data (void *, const char *, int32, const void *, ssize_t);
    62 extern int be_add_refs_data (void *, const char *, const char *);
    63 extern int be_add_point_data (void *, const char *, float, float);
    64 extern int be_add_message_message (void *, const char *, void *);
    65 extern int be_lock_clipboard_message (enum haiku_clipboard, void **, bool);
    66 extern void be_unlock_clipboard (enum haiku_clipboard, bool);
    67 extern void be_handle_clipboard_changed_message (void);
    68 extern void be_start_watching_selection (enum haiku_clipboard);
    69 extern bool be_selection_outdated_p (enum haiku_clipboard, int64);
    70 extern int64 be_get_clipboard_count (enum haiku_clipboard);
    71 
    72 #ifdef __cplusplus
    73 };
    74 #endif
    75 #endif /* _HAIKU_SELECT_H_ */
    76 
    77 // Local Variables:
    78 // eval: (setf (alist-get 'inextern-lang c-offsets-alist) 0)
    79 // End:

/* [<][>][^][v][top][bottom][index][help] */