sequences. Conversion for first/second half double tilde + first/second half
ligature was changed. Conversion should now perform:
6f ef b8 a0 --> eb 6f, 6f ef b8 a1 --> ec 6f,
6f ef b8 a2 --> fa 6f, 6f ef b8 a3 --> fb 6f.
* Copyright (C) 1995-2006, Index Data ApS
* See the file LICENSE for details.
*
* Copyright (C) 1995-2006, Index Data ApS
* See the file LICENSE for details.
*
- * $Id: siconv.c,v 1.30 2006-12-19 22:41:28 adam Exp $
+ * $Id: siconv.c,v 1.31 2006-12-21 20:50:56 adam Exp $
unsigned long write_marc8_comb_ch[8];
size_t write_marc8_comb_no;
unsigned long write_marc8_comb_ch[8];
size_t write_marc8_comb_no;
+ unsigned write_marc8_second_half_char;
unsigned long write_marc8_last;
const char *write_marc8_page_chr;
};
unsigned long write_marc8_last;
const char *write_marc8_page_chr;
};
char **outbuf, size_t *outbytesleft)
{
unsigned long y = cd->write_marc8_last;
char **outbuf, size_t *outbytesleft)
{
unsigned long y = cd->write_marc8_last;
- unsigned char byte, second_half = 0;
char out_buf[10];
size_t i, out_no = 0;
char out_buf[10];
size_t i, out_no = 0;
{
/* all MARC-8 combined characters are simple bytes */
byte = (unsigned char )(cd->write_marc8_comb_ch[i]);
{
/* all MARC-8 combined characters are simple bytes */
byte = (unsigned char )(cd->write_marc8_comb_ch[i]);
- if (byte == 0xEB)
- second_half = 0xEC;
- else if (byte == 0xFA)
- second_half = 0xFB;
-
*(*outbuf)++ = byte;
(*outbytesleft)--;
}
memcpy(*outbuf, out_buf, out_no);
*outbuf += out_no;
(*outbytesleft) -= out_no;
*(*outbuf)++ = byte;
(*outbytesleft)--;
}
memcpy(*outbuf, out_buf, out_no);
*outbuf += out_no;
(*outbytesleft) -= out_no;
+ if (cd->write_marc8_second_half_char)
- *(*outbuf)++ = second_half;
+ *(*outbuf)++ = cd->write_marc8_second_half_char;
(*outbytesleft)--;
}
cd->write_marc8_last = 0;
cd->write_marc8_comb_no = 0;
(*outbytesleft)--;
}
cd->write_marc8_last = 0;
cd->write_marc8_comb_no = 0;
+ cd->write_marc8_second_half_char = 0;
+ if (x == 0x0361)
+ cd->write_marc8_second_half_char = 0xEC;
+ else if (x == 0x0360)
+ cd->write_marc8_second_half_char = 0xFB;
+
if (cd->write_marc8_comb_no < 6)
cd->write_marc8_comb_ch[cd->write_marc8_comb_no++] = y;
}
if (cd->write_marc8_comb_no < 6)
cd->write_marc8_comb_ch[cd->write_marc8_comb_no++] = y;
}
cd->compose_char = 0;
cd->write_marc8_comb_no = 0;
cd->compose_char = 0;
cd->write_marc8_comb_no = 0;
+ cd->write_marc8_second_half_char = 0;
cd->write_marc8_last = 0;
cd->write_marc8_page_chr = "\033(B";
cd->write_marc8_last = 0;
cd->write_marc8_page_chr = "\033(B";
-03093cam a2200337 i 4500
+03091cam a2200337 i 4500
001 12683849
005 20051218154744.0
008 981008b2001 ilu 000 0 eng
001 12683849
005 20051218154744.0
008 981008b2001 ilu 000 0 eng