mirror of
https://github.com/vim/vim.git
synced 2025-10-04 05:25:06 -04:00
patch 8.2.4273: the EBCDIC support is outdated
Problem: The EBCDIC support is outdated. Solution: Remove the EBCDIC support.
This commit is contained in:
@@ -1419,9 +1419,6 @@ prt_write_file(char_u *buffer)
|
||||
static void
|
||||
prt_write_file_len(char_u *buffer, int bytes)
|
||||
{
|
||||
#ifdef EBCDIC
|
||||
ebcdic2ascii(buffer, bytes);
|
||||
#endif
|
||||
prt_write_file_raw_len(buffer, bytes);
|
||||
}
|
||||
|
||||
@@ -1626,8 +1623,6 @@ prt_flush_buffer(void)
|
||||
prt_write_string("ul\n");
|
||||
}
|
||||
// Draw the text
|
||||
// Note: we write text out raw - EBCDIC conversion is handled in the
|
||||
// PostScript world via the font encoding vector.
|
||||
if (prt_out_mbyte)
|
||||
prt_write_string("<");
|
||||
else
|
||||
@@ -3119,7 +3114,7 @@ mch_print_end(prt_settings_T *psettings)
|
||||
|
||||
// Write CTRL-D to close serial communication link if used.
|
||||
// NOTHING MUST BE WRITTEN AFTER THIS!
|
||||
prt_write_file((char_u *)IF_EB("\004", "\067"));
|
||||
prt_write_file((char_u *)"\004");
|
||||
|
||||
if (!prt_file_error && psettings->outfile == NULL
|
||||
&& !got_int && !psettings->user_abort)
|
||||
@@ -3379,26 +3374,21 @@ mch_print_text_out(char_u *textp, int len UNUSED)
|
||||
{
|
||||
// Convert non-printing characters to either their escape or octal
|
||||
// sequence, ensures PS sent over a serial line does not interfere
|
||||
// with the comms protocol. Note: For EBCDIC we need to write out
|
||||
// the escape sequences as ASCII codes!
|
||||
// Note 2: Char codes < 32 are identical in EBCDIC and ASCII AFAIK!
|
||||
ga_append(&prt_ps_buffer, IF_EB('\\', 0134));
|
||||
// with the comms protocol.
|
||||
ga_append(&prt_ps_buffer, '\\');
|
||||
switch (ch)
|
||||
{
|
||||
case BS: ga_append(&prt_ps_buffer, IF_EB('b', 0142)); break;
|
||||
case TAB: ga_append(&prt_ps_buffer, IF_EB('t', 0164)); break;
|
||||
case NL: ga_append(&prt_ps_buffer, IF_EB('n', 0156)); break;
|
||||
case FF: ga_append(&prt_ps_buffer, IF_EB('f', 0146)); break;
|
||||
case CAR: ga_append(&prt_ps_buffer, IF_EB('r', 0162)); break;
|
||||
case '(': ga_append(&prt_ps_buffer, IF_EB('(', 0050)); break;
|
||||
case ')': ga_append(&prt_ps_buffer, IF_EB(')', 0051)); break;
|
||||
case '\\': ga_append(&prt_ps_buffer, IF_EB('\\', 0134)); break;
|
||||
case BS: ga_append(&prt_ps_buffer, 'b'); break;
|
||||
case TAB: ga_append(&prt_ps_buffer, 't'); break;
|
||||
case NL: ga_append(&prt_ps_buffer, 'n'); break;
|
||||
case FF: ga_append(&prt_ps_buffer, 'f'); break;
|
||||
case CAR: ga_append(&prt_ps_buffer, 'r'); break;
|
||||
case '(': ga_append(&prt_ps_buffer, '('); break;
|
||||
case ')': ga_append(&prt_ps_buffer, ')'); break;
|
||||
case '\\': ga_append(&prt_ps_buffer, '\\'); break;
|
||||
|
||||
default:
|
||||
sprintf((char *)ch_buff, "%03o", (unsigned int)ch);
|
||||
#ifdef EBCDIC
|
||||
ebcdic2ascii(ch_buff, 3);
|
||||
#endif
|
||||
ga_append(&prt_ps_buffer, ch_buff[0]);
|
||||
ga_append(&prt_ps_buffer, ch_buff[1]);
|
||||
ga_append(&prt_ps_buffer, ch_buff[2]);
|
||||
|
Reference in New Issue
Block a user