summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTor Andersson <tor.andersson@artifex.com>2011-03-30 20:01:31 +0200
committerTor Andersson <tor.andersson@artifex.com>2011-03-30 20:01:31 +0200
commit4f484b32f3cf8682180ccb9e36f929edff175498 (patch)
treed19f3958f408c0b28ee795d497e2ddb19eaa3fa0
parent60a940e170eb1b3e00e28b76f1b9a86741ef9a25 (diff)
downloadmupdf-4f484b32f3cf8682180ccb9e36f929edff175498.tar.xz
xps: s/could not/cannot/ in error messages
-rw-r--r--xps/xpsglyphs.c2
-rw-r--r--xps/xpsgradient.c4
-rw-r--r--xps/xpsimage.c8
-rw-r--r--xps/xpstiff.c14
-rw-r--r--xps/xpsxml.c2
5 files changed, 15 insertions, 15 deletions
diff --git a/xps/xpsglyphs.c b/xps/xpsglyphs.c
index 834a55f5..d30f016b 100644
--- a/xps/xpsglyphs.c
+++ b/xps/xpsglyphs.c
@@ -82,7 +82,7 @@ xps_select_best_font_encoding(fz_font *font)
}
}
- fz_warn("could not find a suitable cmap");
+ fz_warn("cannot find a suitable cmap");
}
/*
diff --git a/xps/xpsgradient.c b/xps/xpsgradient.c
index 17881d6c..54516e72 100644
--- a/xps/xpsgradient.c
+++ b/xps/xpsgradient.c
@@ -583,11 +583,11 @@ xps_parse_gradient_brush(xps_context *ctx, fz_matrix ctm,
/*
color_func = xps_create_gradient_stop_function(ctx, stop_list, stop_count, 0);
if (!color_func)
- return fz_rethrow(-1, "could not create color gradient function");
+ return fz_rethrow(-1, "cannot create color gradient function");
opacity_func = xps_create_gradient_stop_function(ctx, stop_list, stop_count, 1);
if (!opacity_func)
- return fz_rethrow(-1, "could not create opacity gradient function");
+ return fz_rethrow(-1, "cannot create opacity gradient function");
*/
has_opacity = xps_gradient_has_transparent_colors(stop_list, stop_count);
diff --git a/xps/xpsimage.c b/xps/xpsimage.c
index a4305734..7dcb54aa 100644
--- a/xps/xpsimage.c
+++ b/xps/xpsimage.c
@@ -17,25 +17,25 @@ xps_decode_image(xps_context *ctx, xps_part *part, xps_image *image)
{
error = xps_decode_jpeg(ctx, buf, len, image);
if (error)
- return fz_rethrow(error, "could not decode jpeg image");
+ return fz_rethrow(error, "cannot decode jpeg image");
}
else if (memcmp(buf, "\211PNG\r\n\032\n", 8) == 0)
{
error = xps_decode_png(ctx, buf, len, image);
if (error)
- return fz_rethrow(error, "could not decode png image");
+ return fz_rethrow(error, "cannot decode png image");
}
else if (memcmp(buf, "II", 2) == 0 && buf[2] == 0xBC)
{
error = xps_decode_jpegxr(ctx, buf, len, image);
if (error)
- return fz_rethrow(error, "could not decode JPEG-XR image");
+ return fz_rethrow(error, "cannot decode JPEG-XR image");
}
else if (memcmp(buf, "MM", 2) == 0 || memcmp(buf, "II", 2) == 0)
{
error = xps_decode_tiff(ctx, buf, len, image);
if (error)
- return fz_rethrow(error, "could not decode TIFF image");
+ return fz_rethrow(error, "cannot decode TIFF image");
}
else
return fz_throw("unknown image file format");
diff --git a/xps/xpstiff.c b/xps/xpstiff.c
index 562f1747..30150a93 100644
--- a/xps/xpstiff.c
+++ b/xps/xpstiff.c
@@ -505,7 +505,7 @@ xps_decode_tiff_strips(xps_context *ctx, xps_tiff *tiff, xps_image *image)
fz_close(stm);
if (error)
- return fz_rethrow(error, "could not decode strip %d", row / tiff->rowsperstrip);
+ return fz_rethrow(error, "cannot decode strip %d", row / tiff->rowsperstrip);
/* scramble the bits back into original order */
if (tiff->fillorder == 2)
@@ -532,7 +532,7 @@ xps_decode_tiff_strips(xps_context *ctx, xps_tiff *tiff, xps_image *image)
{
error = xps_expand_colormap(ctx, tiff, image);
if (error)
- return fz_rethrow(error, "could not expand colormap");
+ return fz_rethrow(error, "cannot expand colormap");
}
/* WhiteIsZero .. invert */
@@ -716,21 +716,21 @@ xps_read_tiff_tag(xps_context *ctx, xps_tiff *tiff, unsigned offset)
case StripOffsets:
tiff->stripoffsets = (unsigned*) fz_malloc(count * sizeof(unsigned));
if (!tiff->stripoffsets)
- return fz_throw("could not allocate strip offsets");
+ return fz_throw("cannot allocate strip offsets");
xps_read_tiff_tag_value(tiff->stripoffsets, tiff, type, value, count);
break;
case StripByteCounts:
tiff->stripbytecounts = (unsigned*) fz_malloc(count * sizeof(unsigned));
if (!tiff->stripbytecounts)
- return fz_throw("could not allocate strip byte counts");
+ return fz_throw("cannot allocate strip byte counts");
xps_read_tiff_tag_value(tiff->stripbytecounts, tiff, type, value, count);
break;
case ColorMap:
tiff->colormap = (unsigned*) fz_malloc(count * sizeof(unsigned));
if (!tiff->colormap)
- return fz_throw("could not allocate color map");
+ return fz_throw("cannot allocate color map");
xps_read_tiff_tag_value(tiff->colormap, tiff, type, value, count);
break;
@@ -819,7 +819,7 @@ xps_decode_tiff_header(xps_context *ctx, xps_tiff *tiff, byte *buf, int len)
{
error = xps_read_tiff_tag(ctx, tiff, offset);
if (error)
- return fz_rethrow(error, "could not read TIFF header tag");
+ return fz_rethrow(error, "cannot read TIFF header tag");
offset += 12;
}
@@ -846,7 +846,7 @@ xps_decode_tiff(xps_context *ctx, byte *buf, int len, xps_image *image)
error = xps_decode_tiff_strips(ctx, tiff, image);
if (error)
- return fz_rethrow(error, "could not decode image data");
+ return fz_rethrow(error, "cannot decode image data");
/*
* Byte swap 16-bit images to big endian if necessary.
diff --git a/xps/xpsxml.c b/xps/xpsxml.c
index 63d9af36..c6f41123 100644
--- a/xps/xpsxml.c
+++ b/xps/xpsxml.c
@@ -220,7 +220,7 @@ xps_parse_xml(xps_context *ctx, byte *buf, int len)
xp = XML_ParserCreateNS(NULL, ' ');
if (!xp)
{
- fz_throw("xml error: could not create expat parser");
+ fz_throw("xml error: cannot create expat parser");
return NULL;
}