From 8af92a82ec9b2a28d3de7125d9591a5657f605b0 Mon Sep 17 00:00:00 2001 From: fvogel Date: Sun, 29 Sep 2019 08:04:01 +0000 Subject: Fix Tk_Offset() -> offsetof(). Tk_Offset() was inherited by merging chavez-canvas branch that originally targeted core-8-6-branch. --- generic/tkCanvArc.c | 2 +- generic/tkCanvBmap.c | 2 +- generic/tkCanvLine.c | 2 +- generic/tkCanvPoly.c | 4 ++-- generic/tkCanvText.c | 2 +- generic/tkRectOval.c | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/generic/tkCanvArc.c b/generic/tkCanvArc.c index f7eef8c..b41dc64 100644 --- a/generic/tkCanvArc.c +++ b/generic/tkCanvArc.c @@ -155,7 +155,7 @@ static const Tk_ConfigSpec configSpecs[] = { "0,0", offsetof(ArcItem, tsoffset), TK_CONFIG_DONT_SET_DEFAULT, &offsetOption}, {TK_CONFIG_COLOR, "-outline", NULL, NULL, - DEF_CANVITEM_OUTLINE, Tk_Offset(ArcItem, outline.color), TK_CONFIG_NULL_OK, NULL}, + DEF_CANVITEM_OUTLINE, offsetof(ArcItem, outline.color), TK_CONFIG_NULL_OK, NULL}, {TK_CONFIG_CUSTOM, "-outlineoffset", NULL, NULL, "0,0", offsetof(ArcItem, outline.tsoffset), TK_CONFIG_DONT_SET_DEFAULT, &offsetOption}, diff --git a/generic/tkCanvBmap.c b/generic/tkCanvBmap.c index 0a7a47a..e7b19ae 100644 --- a/generic/tkCanvBmap.c +++ b/generic/tkCanvBmap.c @@ -71,7 +71,7 @@ static const Tk_ConfigSpec configSpecs[] = { NULL, offsetof(BitmapItem, disabledFgColor), TK_CONFIG_NULL_OK, NULL}, {TK_CONFIG_COLOR, "-foreground", NULL, NULL, - DEF_CANVBMAP_FG, Tk_Offset(BitmapItem, fgColor), 0, NULL}, + DEF_CANVBMAP_FG, offsetof(BitmapItem, fgColor), 0, NULL}, {TK_CONFIG_CUSTOM, "-state", NULL, NULL, NULL, offsetof(Tk_Item, state), TK_CONFIG_NULL_OK, &stateOption}, diff --git a/generic/tkCanvLine.c b/generic/tkCanvLine.c index cea9dc3..8623b7e 100644 --- a/generic/tkCanvLine.c +++ b/generic/tkCanvLine.c @@ -178,7 +178,7 @@ static const Tk_ConfigSpec configSpecs[] = { {TK_CONFIG_CAP_STYLE, "-capstyle", NULL, NULL, "butt", offsetof(LineItem, capStyle), TK_CONFIG_DONT_SET_DEFAULT, NULL}, {TK_CONFIG_COLOR, "-fill", NULL, NULL, - DEF_CANVLINE_FILL, Tk_Offset(LineItem, outline.color), TK_CONFIG_NULL_OK, NULL}, + DEF_CANVLINE_FILL, offsetof(LineItem, outline.color), TK_CONFIG_NULL_OK, NULL}, {TK_CONFIG_CUSTOM, "-dash", NULL, NULL, NULL, offsetof(LineItem, outline.dash), TK_CONFIG_NULL_OK, &dashOption}, diff --git a/generic/tkCanvPoly.c b/generic/tkCanvPoly.c index f3b20c3..d68e8ad 100644 --- a/generic/tkCanvPoly.c +++ b/generic/tkCanvPoly.c @@ -113,14 +113,14 @@ static const Tk_ConfigSpec configSpecs[] = { {TK_CONFIG_CUSTOM, "-disabledwidth", NULL, NULL, "0.0", offsetof(PolygonItem, outline.disabledWidth), TK_CONFIG_DONT_SET_DEFAULT, &pixelOption}, - {TK_CONFIG_COLOR, "-fill", NULL, NULL, Tk_Offset(PolygonItem, fillColor), TK_CONFIG_NULL_OK, NULL}, + {TK_CONFIG_COLOR, "-fill", NULL, NULL, offsetof(PolygonItem, fillColor), TK_CONFIG_NULL_OK, NULL}, {TK_CONFIG_JOIN_STYLE, "-joinstyle", NULL, NULL, "round", offsetof(PolygonItem, joinStyle), TK_CONFIG_DONT_SET_DEFAULT, NULL}, {TK_CONFIG_CUSTOM, "-offset", NULL, NULL, "0,0", offsetof(PolygonItem, tsoffset), TK_CONFIG_NULL_OK, &offsetOption}, {TK_CONFIG_COLOR, "-outline", NULL, NULL, - DEF_CANVITEM_OUTLINE, Tk_Offset(PolygonItem, outline.color), TK_CONFIG_NULL_OK, NULL}, + DEF_CANVITEM_OUTLINE, offsetof(PolygonItem, outline.color), TK_CONFIG_NULL_OK, NULL}, {TK_CONFIG_CUSTOM, "-outlineoffset", NULL, NULL, "0,0", offsetof(PolygonItem, outline.tsoffset), TK_CONFIG_NULL_OK, &offsetOption}, diff --git a/generic/tkCanvText.c b/generic/tkCanvText.c index 042444e..b498b1c 100644 --- a/generic/tkCanvText.c +++ b/generic/tkCanvText.c @@ -107,7 +107,7 @@ static const Tk_ConfigSpec configSpecs[] = { {TK_CONFIG_BITMAP, "-disabledstipple", NULL, NULL, NULL, offsetof(TextItem, disabledStipple), TK_CONFIG_NULL_OK, NULL}, {TK_CONFIG_COLOR, "-fill", NULL, NULL, - DEF_CANVTEXT_FILL, Tk_Offset(TextItem, color), TK_CONFIG_NULL_OK, NULL}, + DEF_CANVTEXT_FILL, offsetof(TextItem, color), TK_CONFIG_NULL_OK, NULL}, {TK_CONFIG_FONT, "-font", NULL, NULL, DEF_CANVTEXT_FONT, offsetof(TextItem, tkfont), 0, NULL}, {TK_CONFIG_JUSTIFY, "-justify", NULL, NULL, diff --git a/generic/tkRectOval.c b/generic/tkRectOval.c index 9beef32..6b679f8 100644 --- a/generic/tkRectOval.c +++ b/generic/tkRectOval.c @@ -103,7 +103,7 @@ static const Tk_ConfigSpec configSpecs[] = { "0,0", offsetof(RectOvalItem, tsoffset), TK_CONFIG_DONT_SET_DEFAULT, &offsetOption}, {TK_CONFIG_COLOR, "-outline", NULL, NULL, - DEF_CANVITEM_OUTLINE, Tk_Offset(RectOvalItem, outline.color), TK_CONFIG_NULL_OK, NULL}, + DEF_CANVITEM_OUTLINE, offsetof(RectOvalItem, outline.color), TK_CONFIG_NULL_OK, NULL}, {TK_CONFIG_CUSTOM, "-outlineoffset", NULL, NULL, "0,0", offsetof(RectOvalItem, outline.tsoffset), TK_CONFIG_DONT_SET_DEFAULT, &offsetOption}, -- cgit v0.12