diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2018-12-31 15:36:56 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2018-12-31 15:36:56 (GMT) |
commit | f2b5a87d6dc6d3468828d48929583d950690a40b (patch) | |
tree | 22ec58572e255d6081163199ca2f2d60365c7b6c /generic/tkText.c | |
parent | b68e469c6fcec04a86935ae2e8853197213f40db (diff) | |
download | tk-f2b5a87d6dc6d3468828d48929583d950690a40b.zip tk-f2b5a87d6dc6d3468828d48929583d950690a40b.tar.gz tk-f2b5a87d6dc6d3468828d48929583d950690a40b.tar.bz2 |
As requested by Christian Werner/François Vogel and others: Undo many None -> 0 changes, in order to reduce the probability of merge conflicts with other branches.
Remark: Many usages of "None" in Tk are wrong, "NULL" should be used in many places where pointers are referenced in stead of XID's. Those places are corrected.
Diffstat (limited to 'generic/tkText.c')
-rw-r--r-- | generic/tkText.c | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/generic/tkText.c b/generic/tkText.c index 425687f..004bcaf 100644 --- a/generic/tkText.c +++ b/generic/tkText.c @@ -568,7 +568,7 @@ CreateWidget( textPtr->state = TK_TEXT_STATE_NORMAL; textPtr->relief = TK_RELIEF_FLAT; - textPtr->cursor = 0; + textPtr->cursor = NULL; textPtr->charWidth = 1; textPtr->charHeight = 10; textPtr->wrapMode = TEXT_WRAPMODE_CHAR; @@ -2186,28 +2186,28 @@ ConfigureText( textPtr->selTagPtr->fgColor = textPtr->selFgColorPtr; textPtr->selTagPtr->affectsDisplay = 0; textPtr->selTagPtr->affectsDisplayGeometry = 0; - if (textPtr->selTagPtr->elideString - || textPtr->selTagPtr->tkfont - || textPtr->selTagPtr->justifyString - || textPtr->selTagPtr->lMargin1String - || textPtr->selTagPtr->lMargin2String - || textPtr->selTagPtr->offsetString - || textPtr->selTagPtr->rMarginString - || textPtr->selTagPtr->spacing1String - || textPtr->selTagPtr->spacing2String - || textPtr->selTagPtr->spacing3String - || textPtr->selTagPtr->tabStringPtr + if ((textPtr->selTagPtr->elideString != NULL) + || (textPtr->selTagPtr->tkfont != None) + || (textPtr->selTagPtr->justifyString != NULL) + || (textPtr->selTagPtr->lMargin1String != NULL) + || (textPtr->selTagPtr->lMargin2String != NULL) + || (textPtr->selTagPtr->offsetString != NULL) + || (textPtr->selTagPtr->rMarginString != NULL) + || (textPtr->selTagPtr->spacing1String != NULL) + || (textPtr->selTagPtr->spacing2String != NULL) + || (textPtr->selTagPtr->spacing3String != NULL) + || (textPtr->selTagPtr->tabStringPtr != NULL) || (textPtr->selTagPtr->wrapMode != TEXT_WRAPMODE_NULL)) { textPtr->selTagPtr->affectsDisplay = 1; textPtr->selTagPtr->affectsDisplayGeometry = 1; } - if (textPtr->selTagPtr->border - || textPtr->selTagPtr->reliefString - || textPtr->selTagPtr->bgStipple - || textPtr->selTagPtr->fgColor - || textPtr->selTagPtr->fgStipple - || textPtr->selTagPtr->overstrikeString - || textPtr->selTagPtr->underlineString) { + if ((textPtr->selTagPtr->border != NULL) + || (textPtr->selTagPtr->reliefString != NULL) + || (textPtr->selTagPtr->bgStipple != None) + || (textPtr->selTagPtr->fgColor != NULL) + || (textPtr->selTagPtr->fgStipple != None) + || (textPtr->selTagPtr->overstrikeString != NULL) + || (textPtr->selTagPtr->underlineString != NULL)) { textPtr->selTagPtr->affectsDisplay = 1; } TkTextRedrawTag(NULL, textPtr, NULL, NULL, textPtr->selTagPtr, 1); |