annotate src/wsdebug.h @ 13292:c42fe898b578 v8.0.1520

patch 8.0.1520: cursor in wrong line when using a WinBar in Terminal window commit https://github.com/vim/vim/commit/181ca99e163b145cd1a4ec47a50cc25cf3994109 Author: Bram Moolenaar <Bram@vim.org> Date: Tue Feb 13 21:19:21 2018 +0100 patch 8.0.1520: cursor in wrong line when using a WinBar in Terminal window Problem: Cursor is in the wrong line when using a WinBar in a Terminal window. Solution: Adjust the row number. (Christian Brabandt, closes #2362)
author Christian Brabandt <cb@256bit.org>
date Tue, 13 Feb 2018 21:30:06 +0100
parents 4aead6a9b7a9
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
10042
4aead6a9b7a9 commit https://github.com/vim/vim/commit/edf3f97ae2af024708ebb4ac614227327033ca47
Christian Brabandt <cb@256bit.org>
parents: 7
diff changeset
1 /* vi:set ts=8 sw=8 noet:
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
2 *
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
3 * VIM - Vi IMproved by Bram Moolenaar
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
4 * Visual Workshop integration by Gordon Prieur
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
5 *
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
6 * Do ":help uganda" in Vim to read copying and usage conditions.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
7 * Do ":help credits" in Vim to see a list of people who contributed.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
8 */
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
9
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
10
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
11 #ifndef WSDEBUG_H
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
12 #define WSDEBUG_H
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
13
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
14 #ifdef WSDEBUG
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
15
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16 #ifndef ASSERT
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17 #define ASSERT(c) \
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
18 if (!(c)) { \
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
19 fprintf(stderr, "Assertion failed: line %d, file %s\n", \
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
20 __LINE__, __FILE__); \
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21 fflush(stderr); \
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22 abort(); \
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
23 }
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
24 #endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
25
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
26 #define WS_TRACE 0x00000001
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
27 #define WS_TRACE_VERBOSE 0x00000002
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
28 #define WS_TRACE_COLONCMD 0x00000004
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
29 #define WS_DEBUG_ALL 0xffffffff
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
30
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
31 #define WSDLEVEL(flags) (ws_debug != NULL && (ws_dlevel & (flags)))
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
32
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
33 #ifdef USE_WDDUMP
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
34 #include "wdump.h"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
35 #endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
36
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
37 #define WSDEBUG_TRACE 1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
38 //#define WSDEBUG_SENSE 2
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
39
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
40 typedef enum {
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
41 WT_ENV = 1, /* look for env var if set */
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
42 WT_WAIT, /* look for ~/.gvimwait if set */
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
43 WT_STOP /* look for ~/.gvimstop if set */
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
44 } WtWait;
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
45
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
46
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
47 void wsdebug(char *, ...);
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
48 void wstrace(char *, ...);
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
49
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
50
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
51 extern FILE *ws_debug;
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
52 extern u_int ws_dlevel; /* ws_debug verbosity level */
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
53
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
54 # else /* not WSDEBUG */
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
55
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
56 #ifndef ASSERT
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
57 # define ASSERT(c)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
58 #endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
59
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
60 /*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
61 * The following 2 stubs are needed because a macro cannot be used because of
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
62 * the variable number of arguments.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
63 */
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
64
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
65 void
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
66 wsdebug(
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
67 char *fmt,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
68 ...)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
69 {
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
70 }
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
71
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
72
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
73 void
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
74 wstrace(
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
75 char *fmt,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
76 ...)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
77 {
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
78 }
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
79
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
80 #endif /* WSDEBUG */
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
81 #endif /* WSDEBUG_H */