summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2019-06-21 13:23:24 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2019-06-21 13:23:24 (GMT)
commit779f43bf68b8ce10b9356a7ac83916707c4a780b (patch)
treea7101ed91dc87cbd995b59884dbce023bb66e386 /generic
parentf8f745fe34d10d25ff1fe4e0935e042b5347004c (diff)
downloadtk-779f43bf68b8ce10b9356a7ac83916707c4a780b.zip
tk-779f43bf68b8ce10b9356a7ac83916707c4a780b.tar.gz
tk-779f43bf68b8ce10b9356a7ac83916707c4a780b.tar.bz2
Make better use of full range for string lengths, if Tk is compiled with Tcl 9.0 headers.
Diffstat (limited to 'generic')
-rw-r--r--generic/tkImgSVGnano.c16
-rw-r--r--generic/tkObj.c2
2 files changed, 9 insertions, 9 deletions
diff --git a/generic/tkImgSVGnano.c b/generic/tkImgSVGnano.c
index 32391ef..d64ae5b 100644
--- a/generic/tkImgSVGnano.c
+++ b/generic/tkImgSVGnano.c
@@ -62,7 +62,7 @@ static int StringReadSVG(Tcl_Interp *interp, Tcl_Obj *dataObj,
int destX, int destY, int width, int height,
int srcX, int srcY);
static NSVGimage * ParseSVGWithOptions(Tcl_Interp *interp,
- const char *input, size_t length, Tcl_Obj *format,
+ const char *input, TkSizeT length, Tcl_Obj *format,
RastOpts *ropts);
static int RasterizeSVG(Tcl_Interp *interp,
Tk_PhotoHandle imageHandle, NSVGimage *nsvgImage,
@@ -118,7 +118,7 @@ FileMatchSVG(
int *widthPtr, int *heightPtr,
Tcl_Interp *interp)
{
- int length;
+ TkSizeT length;
Tcl_Obj *dataObj = Tcl_NewObj();
const char *data;
RastOpts ropts;
@@ -178,7 +178,7 @@ FileReadSVG(
int width, int height,
int srcX, int srcY)
{
- int length;
+ TkSizeT length;
const char *data;
RastOpts ropts;
NSVGimage *nsvgImage = GetCachedSVG(interp, chan, formatObj, &ropts);
@@ -230,7 +230,7 @@ StringMatchSVG(
int *widthPtr, int *heightPtr,
Tcl_Interp *interp)
{
- int length;
+ TkSizeT length;
const char *data;
RastOpts ropts;
NSVGimage *nsvgImage;
@@ -281,7 +281,7 @@ StringReadSVG(
int width, int height,
int srcX, int srcY)
{
- int length;
+ TkSizeT length;
const char *data;
RastOpts ropts;
NSVGimage *nsvgImage = GetCachedSVG(interp, dataObj, formatObj, &ropts);
@@ -317,7 +317,7 @@ static NSVGimage *
ParseSVGWithOptions(
Tcl_Interp *interp,
const char *input,
- size_t length,
+ TkSizeT length,
Tcl_Obj *formatObj,
RastOpts *ropts)
{
@@ -576,7 +576,7 @@ CacheSVG(
NSVGimage *nsvgImage,
RastOpts *ropts)
{
- int length;
+ TkSizeT length;
const char *data;
NSVGcache *cachePtr = GetCachePtr(interp);
@@ -616,7 +616,7 @@ GetCachedSVG(
Tcl_Obj *formatObj,
RastOpts *ropts)
{
- int length;
+ TkSizeT length;
const char *data;
NSVGcache *cachePtr = GetCachePtr(interp);
NSVGimage *nsvgImage = NULL;
diff --git a/generic/tkObj.c b/generic/tkObj.c
index b857d98..419a144 100644
--- a/generic/tkObj.c
+++ b/generic/tkObj.c
@@ -672,7 +672,7 @@ UpdateStringOfMM(
{
MMRep *mmPtr;
char buffer[TCL_DOUBLE_SPACE];
- size_t len;
+ TkSizeT len;
mmPtr = objPtr->internalRep.twoPtrValue.ptr1;
/* assert( mmPtr->units == -1 && objPtr->bytes == NULL ); */