mirror of
https://github.com/zint/zint
synced 2024-11-16 20:57:25 +13:00
Removal of some ghosts
Removal of some more old Codablock-F code and some depreciated functions from the API.
This commit is contained in:
parent
81b4902c95
commit
e32561cb34
@ -741,11 +741,6 @@ int ZBarcode_Buffer(struct zint_symbol *symbol, int rotate_angle)
|
||||
return error_number;
|
||||
}
|
||||
|
||||
int ZBarcode_Print_Rotated(struct zint_symbol *symbol, int rotate_angle) {
|
||||
/* Depreciated - will be removed in later version */
|
||||
return ZBarcode_Print(symbol, rotate_angle);
|
||||
}
|
||||
|
||||
int ZBarcode_Encode_and_Print(struct zint_symbol *symbol, unsigned char *input, int length, int rotate_angle)
|
||||
{
|
||||
int error_number;
|
||||
@ -776,11 +771,6 @@ int ZBarcode_Encode_and_Buffer(struct zint_symbol *symbol, unsigned char *input,
|
||||
return error_number;
|
||||
}
|
||||
|
||||
int ZBarcode_Encode_and_Print_Rotated(struct zint_symbol *symbol, unsigned char *input, int rotate_angle) {
|
||||
/* Depreciated - will be removed in later version */
|
||||
return ZBarcode_Encode_and_Print(symbol, input, rotate_angle, strlen((char *)input));
|
||||
}
|
||||
|
||||
int ZBarcode_Encode_File(struct zint_symbol *symbol, char *filename)
|
||||
{
|
||||
FILE *file;
|
||||
|
@ -1066,19 +1066,6 @@ int png_plot(struct zint_symbol *symbol, int rotate_angle, int data_type)
|
||||
|
||||
/* Put boundary bars or box around symbol */
|
||||
if(((symbol->output_options & BARCODE_BOX) != 0) || ((symbol->output_options & BARCODE_BIND) != 0)) {
|
||||
if((symbol->symbology != BARCODE_CODABLOCKF) && (symbol->symbology != BARCODE_HIBC_BLOCKF)) {
|
||||
/* boundary bars */
|
||||
draw_bar(pixelbuf, 0, (symbol->width + xoffset + xoffset) * 2, textoffset * 2, symbol->border_width * 2, image_width, image_height);
|
||||
draw_bar(pixelbuf, 0, (symbol->width + xoffset + xoffset) * 2, (textoffset + symbol->height + symbol->border_width) * 2, symbol->border_width * 2, image_width, image_height);
|
||||
if((symbol->output_options & BARCODE_BIND) != 0) {
|
||||
if((symbol->rows > 1) && (is_stackable(symbol->symbology) == 1)) {
|
||||
/* row binding */
|
||||
for(r = 1; r < symbol->rows; r++) {
|
||||
draw_bar(pixelbuf, xoffset * 2, symbol->width * 2, ((r * row_height) + textoffset + yoffset - 1) * 2, 2 * 2, image_width, image_height);
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
/* boundary bars */
|
||||
draw_bar(pixelbuf, xoffset * 2, symbol->width * 2, textoffset * 2, symbol->border_width * 2, image_width, image_height);
|
||||
draw_bar(pixelbuf, xoffset * 2, symbol->width * 2, (textoffset + symbol->height + symbol->border_width) * 2, symbol->border_width * 2, image_width, image_height);
|
||||
@ -1089,7 +1076,6 @@ int png_plot(struct zint_symbol *symbol, int rotate_angle, int data_type)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if((symbol->output_options & BARCODE_BOX) != 0) {
|
||||
/* side bars */
|
||||
|
15
backend/ps.c
15
backend/ps.c
@ -706,21 +706,6 @@ int ps_plot(struct zint_symbol *symbol)
|
||||
xoffset -= comp_offset;
|
||||
|
||||
switch(symbol->symbology) {
|
||||
case BARCODE_CODABLOCKF:
|
||||
case BARCODE_HIBC_BLOCKF:
|
||||
fprintf(feps, "TE\n");
|
||||
fprintf(feps, "%.2f %.2f %.2f setrgbcolor\n", red_ink, green_ink, blue_ink);
|
||||
fprintf(feps, "%.2f %.2f TB %.2f %.2f TR\n", symbol->border_width * scaler, textoffset * scaler, xoffset * scaler, symbol->width * scaler);
|
||||
fprintf(feps, "%.2f %.2f TB %.2f %.2f TR\n", symbol->border_width * scaler, (textoffset + symbol->height + symbol->border_width) * scaler, xoffset * scaler, symbol->width * scaler);
|
||||
if(symbol->rows > 1) {
|
||||
/* row binding */
|
||||
fprintf(feps, "TE\n");
|
||||
fprintf(feps, "%.2f %.2f %.2f setrgbcolor\n", red_ink, green_ink, blue_ink);
|
||||
for(r = 1; r < symbol->rows; r++) {
|
||||
fprintf(feps, "%.2f %.2f TB %.2f %.2f TR\n", 2.0 * scaler, ((r * row_height) + textoffset + yoffset - 1) * scaler, (xoffset + 11) * scaler, (symbol->width - 24) * scaler);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case BARCODE_MAXICODE:
|
||||
/* Do nothing! (It's already been done) */
|
||||
break;
|
||||
|
@ -569,17 +569,6 @@ int svg_plot(struct zint_symbol *symbol)
|
||||
xoffset -= comp_offset;
|
||||
|
||||
switch(symbol->symbology) {
|
||||
case BARCODE_CODABLOCKF:
|
||||
case BARCODE_HIBC_BLOCKF:
|
||||
fprintf(fsvg, " <rect x=\"%.2f\" y=\"%.2f\" width=\"%.2f\" height=\"%.2f\" />\n", xoffset * scaler, 0.0, symbol->width * scaler, symbol->border_width * scaler);
|
||||
fprintf(fsvg, " <rect x=\"%.2f\" y=\"%.2f\" width=\"%.2f\" height=\"%.2f\" />\n", xoffset * scaler, (symbol->height + symbol->border_width) * scaler, symbol->width * scaler, symbol->border_width * scaler);
|
||||
if(symbol->rows > 1) {
|
||||
/* row binding */
|
||||
for(r = 1; r < symbol->rows; r++) {
|
||||
fprintf(fsvg, " <rect x=\"%.2f\" y=\"%.2f\" width=\"%.2f\" height=\"%.2f\" />\n", (xoffset + 11) * scaler, ((r * row_height) + yoffset - 1) * scaler, (symbol->width - 24) * scaler, 2.0 * scaler);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case BARCODE_MAXICODE:
|
||||
/* Do nothing! (It's already been done) */
|
||||
break;
|
||||
|
@ -217,10 +217,6 @@ ZINT_EXTERN int ZBarcode_Encode_File_and_Buffer(struct zint_symbol *symbol, char
|
||||
|
||||
ZINT_EXTERN int ZBarcode_ValidID(int symbol_id);
|
||||
|
||||
/* Depreciated */
|
||||
ZINT_EXTERN int ZBarcode_Print_Rotated(struct zint_symbol *symbol, int rotate_angle);
|
||||
ZINT_EXTERN int ZBarcode_Encode_and_Print_Rotated(struct zint_symbol *symbol, unsigned char *input, int rotate_angle);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
|
Loading…
Reference in New Issue
Block a user