Skip to content

Commit

Permalink
snapshot of project "xterm", label xterm-362d
Browse files Browse the repository at this point in the history
  • Loading branch information
ThomasDickey committed Dec 26, 2020
1 parent e578f45 commit 1283a4c
Show file tree
Hide file tree
Showing 8 changed files with 143 additions and 253 deletions.
2 changes: 1 addition & 1 deletion MANIFEST
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
MANIFEST for xterm, version xterm-362c
MANIFEST for xterm, version xterm-362d
--------------------------------------------------------------------------------
MANIFEST this file
256colres.h resource-definitions for 256-color mode
Expand Down
25 changes: 2 additions & 23 deletions button.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* $XTermId: button.c,v 1.627 2020/12/17 00:35:37 tom Exp $ */
/* $XTermId: button.c,v 1.629 2020/12/20 17:02:30 tom Exp $ */

/*
* Copyright 1999-2019,2020 by Thomas E. Dickey
Expand Down Expand Up @@ -2537,28 +2537,7 @@ removeControls(XtermWidget xw, char *value)

if (ch < 32) {
ReplacePaste(epC0);
switch (ch) {
case ANSI_BS:
ReplacePaste(epBS);
break;
case ANSI_CR:
ReplacePaste(epCR);
break;
case ANSI_ESC:
ReplacePaste(epESC);
break;
case ANSI_FF:
ReplacePaste(epFF);
break;
case ANSI_HT:
ReplacePaste(epHT);
break;
case ANSI_LF:
ReplacePaste(epNL);
break;
default:
continue;
}
ReplacePaste(ch);
++dst;
} else if (ch == ANSI_DEL) {
ReplacePaste(epDEL);
Expand Down
59 changes: 47 additions & 12 deletions charproc.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* $XTermId: charproc.c,v 1.1803 2020/12/16 16:10:25 tom Exp $ */
/* $XTermId: charproc.c,v 1.1807 2020/12/19 00:16:05 tom Exp $ */

/*
* Copyright 1999-2019,2020 by Thomas E. Dickey
Expand Down Expand Up @@ -8672,9 +8672,14 @@ set_flags_from_list(char *target,
while (!IsEmpty(source)) {
char *next = ParseList(&source);
Boolean found = False;
char flag = 1;

if (next == 0)
break;
if (*next == '~') {
flag = 0;
next++;
}
if (isdigit(CharOf(*next))) {
char *temp;
int value = (int) strtol(next, &temp, 0);
Expand All @@ -8683,7 +8688,7 @@ set_flags_from_list(char *target,
} else {
for (n = 0; list[n].name != 0; ++n) {
if (list[n].code == value) {
target[value] = 1;
target[value] = flag;
found = True;
TRACE(("...found %s (%d)\n", list[n].name, value));
break;
Expand All @@ -8694,7 +8699,7 @@ set_flags_from_list(char *target,
for (n = 0; list[n].name != 0; ++n) {
if (!x_wildstrcmp(next, list[n].name)) {
int value = list[n].code;
target[value] = 1;
target[value] = flag;
found = True;
TRACE(("...found %s (%d)\n", list[n].name, value));
}
Expand Down Expand Up @@ -8928,19 +8933,49 @@ VTInitialize(Widget wrequest,
#undef DATA

#define DATA(name) { #name, ep##name }
#define DATA2(alias,name) { #alias, ep##name }
static const FlagList tblPasteControls[] =
{
DATA(C0)
DATA(NUL)
,DATA(SOH)
,DATA(STX)
,DATA(ETX)
,DATA(EOT)
,DATA(ENQ)
,DATA(ACK)
,DATA(BEL)
,DATA(BS)
,DATA(HT)
,DATA(LF)
,DATA(VT)
,DATA(FF)
,DATA(CR)
,DATA(DEL)
,DATA(SO)
,DATA(SI)
,DATA(DLE)
,DATA(DC1)
,DATA(DC2)
,DATA(DC3)
,DATA(DC4)
,DATA(NAK)
,DATA(SYN)
,DATA(ETB)
,DATA(CAN)
,DATA(EM)
,DATA(SUB)
,DATA(ESC)
,DATA(FF)
,DATA(HT)
,DATA(NL)
,DATA(FS)
,DATA(GS)
,DATA(RS)
,DATA(US)
/* aliases */
,DATA2(NL, LF)
,DATA(C0)
,DATA(DEL)
,DATA_END
};
#undef DATA
#undef DATA2

#define DATA(name) { #name, et##name }
static const FlagList tblTcapOps[] =
Expand Down Expand Up @@ -9970,8 +10005,8 @@ VTInitialize(Widget wrequest,
if (!x_strcasecmp(screen->graphics_regis_screensize, "auto")) {
TRACE(("setting default ReGIS screensize based on graphics_id %d\n",
GraphicsTermId(screen)));
screen->graphics_regis_def_high = (Dimension) native_w;
screen->graphics_regis_def_wide = (Dimension) native_h;
screen->graphics_regis_def_high = (Dimension) native_h;
screen->graphics_regis_def_wide = (Dimension) native_w;
} else {
int conf_high;
int conf_wide;
Expand Down Expand Up @@ -10007,8 +10042,8 @@ VTInitialize(Widget wrequest,
if (!x_strcasecmp(screen->graphics_max_size, "auto")) {
TRACE(("setting max graphics screensize based on graphics_id %d\n",
GraphicsTermId(screen)));
screen->graphics_max_high = (Dimension) native_w;
screen->graphics_max_wide = (Dimension) native_h;
screen->graphics_max_high = (Dimension) native_h;
screen->graphics_max_wide = (Dimension) native_w;
} else {
int conf_high;
int conf_wide;
Expand Down
4 changes: 2 additions & 2 deletions main.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* $XTermId: main.h,v 1.73 2020/10/27 00:10:16 tom Exp $ */
/* $XTermId: main.h,v 1.74 2020/12/19 00:19:51 tom Exp $ */

/*
* Copyright 2000-2019,2020 by Thomas E. Dickey
Expand Down Expand Up @@ -132,7 +132,7 @@
#endif

#ifndef DEF_DISALLOWED_PASTE_CONTROLS
#define DEF_DISALLOWED_PASTE_CONTROLS "BS,HT,DEL,ESC"
#define DEF_DISALLOWED_PASTE_CONTROLS "BS,DEL,ENQ,EOT,ESC,NUL"
#endif

#ifndef DEF_DISALLOWED_TCAP
Expand Down
47 changes: 38 additions & 9 deletions ptyx.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* $XTermId: ptyx.h,v 1.1020 2020/12/15 21:43:50 tom Exp $ */
/* $XTermId: ptyx.h,v 1.1023 2020/12/18 23:37:35 tom Exp $ */

/*
* Copyright 1999-2019,2020 by Thomas E. Dickey
Expand Down Expand Up @@ -1262,14 +1262,43 @@ typedef enum {
} MouseOps;

typedef enum {
epC0 = 1
, epBS
, epCR
, epDEL
, epESC
, epFF
, epHT
, epNL
#define DATA(name) ep##name
DATA(NUL) = 0
, DATA(SOH) = 1
, DATA(STX) = 2
, DATA(ETX) = 3
, DATA(EOT) = 4
, DATA(ENQ) = 5
, DATA(ACK) = 6
, DATA(BEL) = 7
, DATA(BS) = 8
, DATA(HT) = 9
, DATA(LF) = 10
, DATA(VT) = 11
, DATA(FF) = 12
, DATA(CR) = 13
, DATA(SO) = 14
, DATA(SI) = 15
, DATA(DLE) = 16
, DATA(DC1) = 17
, DATA(DC2) = 18
, DATA(DC3) = 19
, DATA(DC4) = 20
, DATA(NAK) = 21
, DATA(SYN) = 22
, DATA(ETB) = 23
, DATA(CAN) = 24
, DATA(EM) = 25
, DATA(SUB) = 26
, DATA(ESC) = 27
, DATA(FS) = 28
, DATA(GS) = 29
, DATA(RS) = 30
, DATA(US) = 31
/* aliases */
, DATA(C0)
, DATA(DEL)
#undef DATA
, epLAST
} PasteControls;

Expand Down
9 changes: 7 additions & 2 deletions trace.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* $XTermId: trace.c,v 1.226 2020/12/17 00:36:39 tom Exp $ */
/* $XTermId: trace.c,v 1.227 2020/12/20 16:23:05 tom Exp $ */

/*
* Copyright 1997-2019,2020 by Thomas E. Dickey
Expand Down Expand Up @@ -122,7 +122,7 @@ TraceOpen(void)
exit(EXIT_FAILURE);
}
(void) umask(oldmask);
free (name);
free(name);
}
return trace_fp;
}
Expand Down Expand Up @@ -910,6 +910,11 @@ TraceEvent(const char *tag, XEvent *ev, String *params, Cardinal *num_params)
ev->xnoexpose.major_code,
ev->xnoexpose.minor_code));
break;
case SelectionClear:
TRACE((" selection:%s",
TraceAtomName(ev->xselectionclear.display,
ev->xselectionclear.selection)));
break;
case SelectionRequest:
TRACE((" owner:%#lx requestor:%#lx",
ev->xselectionrequest.owner,
Expand Down
Loading

0 comments on commit 1283a4c

Please sign in to comment.