annotate liboctave/wrappers/signal-wrappers.h @ 33636:3ec6fcce7715 default tip @

gui: Avoid using HAVE_QSCINTILLA in more header files. * gui-settings.h, settings-dialog.h: Don't include QScintilla header. Forward-declare QSciLexer class instead if necessary. Declare all member functions unconditionally. * gui-settings.cc (gui_settings::get_valid_lexer_styles, gui_settings::read_lexer_settings), settings-dialog.cc (settings_dialog::update_lexer, settings_dialog::get_lexer_settings, settings_dialog::write_lexer_settings): Define functions unconditionally. * gui-preferences-ed.h: Don't include QScintilla header. Remove definition of local variable os_eol_mode from header. * gui-preferences-ed.cc (os_eol_mode): Move definition of local variable here.
author Markus Mützel <markus.muetzel@gmx.de>
date Tue, 28 May 2024 14:54:58 +0200
parents 7274354d68bf
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
27923
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
1 ////////////////////////////////////////////////////////////////////////
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
2 //
32632
2e484f9f1f18 maint: update Octave Project Developers copyright for the new year
John W. Eaton <jwe@octave.org>
parents: 31793
diff changeset
3 // Copyright (C) 2016-2024 The Octave Project Developers
27923
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
4 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
5 // See the file COPYRIGHT.md in the top-level directory of this
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
6 // distribution or <https://octave.org/copyright/>.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
7 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
8 // This file is part of Octave.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
9 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
10 // Octave is free software: you can redistribute it and/or modify it
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
11 // under the terms of the GNU General Public License as published by
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
12 // the Free Software Foundation, either version 3 of the License, or
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
13 // (at your option) any later version.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
14 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
15 // Octave is distributed in the hope that it will be useful, but
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
16 // WITHOUT ANY WARRANTY; without even the implied warranty of
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
17 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
18 // GNU General Public License for more details.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
19 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
20 // You should have received a copy of the GNU General Public License
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
21 // along with Octave; see the file COPYING. If not, see
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
22 // <https://www.gnu.org/licenses/>.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
23 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
24 ////////////////////////////////////////////////////////////////////////
21938
da9b960b1b2d use gnulib strsignal module
John W. Eaton <jwe@octave.org>
parents:
diff changeset
25
da9b960b1b2d use gnulib strsignal module
John W. Eaton <jwe@octave.org>
parents:
diff changeset
26 #if ! defined (octave_signal_wrappers_h)
da9b960b1b2d use gnulib strsignal module
John W. Eaton <jwe@octave.org>
parents:
diff changeset
27 #define octave_signal_wrappers_h 1
da9b960b1b2d use gnulib strsignal module
John W. Eaton <jwe@octave.org>
parents:
diff changeset
28
21940
70824a0dd009 provide wrapper for kill
John W. Eaton <jwe@octave.org>
parents: 21938
diff changeset
29 #if ! defined (__cplusplus)
70824a0dd009 provide wrapper for kill
John W. Eaton <jwe@octave.org>
parents: 21938
diff changeset
30 # include <stdbool.h>
70824a0dd009 provide wrapper for kill
John W. Eaton <jwe@octave.org>
parents: 21938
diff changeset
31 #endif
70824a0dd009 provide wrapper for kill
John W. Eaton <jwe@octave.org>
parents: 21938
diff changeset
32
24104
0d96215c6e7d add standard system includes needed in wrapper headers
Mike Miller <mtmiller@octave.org>
parents: 23446
diff changeset
33 #include <sys/types.h>
0d96215c6e7d add standard system includes needed in wrapper headers
Mike Miller <mtmiller@octave.org>
parents: 23446
diff changeset
34
33166
7274354d68bf for consistent coding style, use #if defined (X) instead of if defined X
John W. Eaton <jwe@octave.org>
parents: 32632
diff changeset
35 #if defined (__cplusplus)
21938
da9b960b1b2d use gnulib strsignal module
John W. Eaton <jwe@octave.org>
parents:
diff changeset
36 extern "C" {
da9b960b1b2d use gnulib strsignal module
John W. Eaton <jwe@octave.org>
parents:
diff changeset
37 #endif
da9b960b1b2d use gnulib strsignal module
John W. Eaton <jwe@octave.org>
parents:
diff changeset
38
21941
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
39 typedef void octave_sig_handler (int);
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
40
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
41 extern OCTAVE_API int octave_kill_wrapper (pid_t pid, int signum);
21940
70824a0dd009 provide wrapper for kill
John W. Eaton <jwe@octave.org>
parents: 21938
diff changeset
42
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
43 extern OCTAVE_API char * octave_strsignal_wrapper (int signum);
21938
da9b960b1b2d use gnulib strsignal module
John W. Eaton <jwe@octave.org>
parents:
diff changeset
44
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
45 extern OCTAVE_API bool octave_have_kill (void);
21992
03c692adf563 maint: strip trailing whitespace from files.
John W. Eaton <jwe@octave.org>
parents: 21941
diff changeset
46
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
47 extern OCTAVE_API bool octave_get_sig_number (const char *signame, int *signum);
21941
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
48
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
49 extern OCTAVE_API octave_sig_handler *
24520
c5c11b07598a refactor signal handling (bug #52757)
John W. Eaton <jwe@octave.org>
parents: 24104
diff changeset
50 octave_set_signal_handler_internal (int sig, octave_sig_handler *handler,
c5c11b07598a refactor signal handling (bug #52757)
John W. Eaton <jwe@octave.org>
parents: 24104
diff changeset
51 bool restart_syscalls);
c5c11b07598a refactor signal handling (bug #52757)
John W. Eaton <jwe@octave.org>
parents: 24104
diff changeset
52
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
53 extern OCTAVE_API octave_sig_handler *
21941
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
54 octave_set_signal_handler_by_name (const char *signame,
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
55 octave_sig_handler *handler,
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
56 bool restart_syscalls);
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
57
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
58 extern OCTAVE_API octave_sig_handler *
24520
c5c11b07598a refactor signal handling (bug #52757)
John W. Eaton <jwe@octave.org>
parents: 24104
diff changeset
59 octave_set_default_signal_handler (int sig);
c5c11b07598a refactor signal handling (bug #52757)
John W. Eaton <jwe@octave.org>
parents: 24104
diff changeset
60
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
61 extern OCTAVE_API octave_sig_handler *
24520
c5c11b07598a refactor signal handling (bug #52757)
John W. Eaton <jwe@octave.org>
parents: 24104
diff changeset
62 octave_set_default_signal_handler_by_name (const char *signame);
21941
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
63
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
64 extern OCTAVE_API int octave_num_signals (void);
21941
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
65
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
66 extern OCTAVE_API void * octave_block_child (void);
21941
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
67
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
68 extern OCTAVE_API void octave_unblock_child (void *context);
21941
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
69
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
70 extern OCTAVE_API void octave_block_interrupt_signal (void);
21941
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
71
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
72 extern OCTAVE_API void octave_unblock_interrupt_signal (void);
21941
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
73
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
74 extern OCTAVE_API void octave_block_signal_by_name (const char *signame);
24520
c5c11b07598a refactor signal handling (bug #52757)
John W. Eaton <jwe@octave.org>
parents: 24104
diff changeset
75
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
76 extern OCTAVE_API void octave_unblock_signal_by_name (const char *signame);
24520
c5c11b07598a refactor signal handling (bug #52757)
John W. Eaton <jwe@octave.org>
parents: 24104
diff changeset
77
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
78 extern OCTAVE_API void octave_save_signal_mask (void);
21941
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
79
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
80 extern OCTAVE_API void octave_restore_signal_mask (void);
21941
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
81
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
82 extern OCTAVE_API void * octave_alloc_signal_mask (void);
25284
78fb24bdd8bb unblock async signals before executing subprocess (bug #53635)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
83
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
84 extern OCTAVE_API void octave_free_signal_mask (void *mask);
25284
78fb24bdd8bb unblock async signals before executing subprocess (bug #53635)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
85
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
86 extern OCTAVE_API void octave_get_signal_mask (void *mask);
25284
78fb24bdd8bb unblock async signals before executing subprocess (bug #53635)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
87
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
88 extern OCTAVE_API void octave_set_signal_mask (void *mask);
25284
78fb24bdd8bb unblock async signals before executing subprocess (bug #53635)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
89
31792
30b6a8be7128 attempt to avoid race condition when initializing list of async signals
John W. Eaton <jwe@octave.org>
parents: 31706
diff changeset
90 extern OCTAVE_API int octave_raise_wrapper (int signum);
30b6a8be7128 attempt to avoid race condition when initializing list of async signals
John W. Eaton <jwe@octave.org>
parents: 31706
diff changeset
91
30b6a8be7128 attempt to avoid race condition when initializing list of async signals
John W. Eaton <jwe@octave.org>
parents: 31706
diff changeset
92 // This function can be useful for debugging.
24520
c5c11b07598a refactor signal handling (bug #52757)
John W. Eaton <jwe@octave.org>
parents: 24104
diff changeset
93
31792
30b6a8be7128 attempt to avoid race condition when initializing list of async signals
John W. Eaton <jwe@octave.org>
parents: 31706
diff changeset
94 extern OCTAVE_API void octave_show_sigmask (const char *);
24520
c5c11b07598a refactor signal handling (bug #52757)
John W. Eaton <jwe@octave.org>
parents: 24104
diff changeset
95
31792
30b6a8be7128 attempt to avoid race condition when initializing list of async signals
John W. Eaton <jwe@octave.org>
parents: 31706
diff changeset
96 // The next three functions are defined in cxx-signal-helpers.cc.
21941
1d23b75cbcd1 hide signal.h from C++ sources
John W. Eaton <jwe@octave.org>
parents: 21940
diff changeset
97
29231
4e196fbb28a5 Set API tags in files in liboctave/wrappers (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents: 27923
diff changeset
98 extern OCTAVE_API void
24520
c5c11b07598a refactor signal handling (bug #52757)
John W. Eaton <jwe@octave.org>
parents: 24104
diff changeset
99 octave_create_interrupt_watcher_thread (octave_sig_handler *handler);
c5c11b07598a refactor signal handling (bug #52757)
John W. Eaton <jwe@octave.org>
parents: 24104
diff changeset
100
31792
30b6a8be7128 attempt to avoid race condition when initializing list of async signals
John W. Eaton <jwe@octave.org>
parents: 31706
diff changeset
101 extern OCTAVE_API void octave_block_async_signals (void);
30b6a8be7128 attempt to avoid race condition when initializing list of async signals
John W. Eaton <jwe@octave.org>
parents: 31706
diff changeset
102
30b6a8be7128 attempt to avoid race condition when initializing list of async signals
John W. Eaton <jwe@octave.org>
parents: 31706
diff changeset
103 extern OCTAVE_API void octave_unblock_async_signals (void);
24520
c5c11b07598a refactor signal handling (bug #52757)
John W. Eaton <jwe@octave.org>
parents: 24104
diff changeset
104
33166
7274354d68bf for consistent coding style, use #if defined (X) instead of if defined X
John W. Eaton <jwe@octave.org>
parents: 32632
diff changeset
105 #if defined (__cplusplus)
21938
da9b960b1b2d use gnulib strsignal module
John W. Eaton <jwe@octave.org>
parents:
diff changeset
106 }
da9b960b1b2d use gnulib strsignal module
John W. Eaton <jwe@octave.org>
parents:
diff changeset
107 #endif
da9b960b1b2d use gnulib strsignal module
John W. Eaton <jwe@octave.org>
parents:
diff changeset
108
da9b960b1b2d use gnulib strsignal module
John W. Eaton <jwe@octave.org>
parents:
diff changeset
109 #endif