Skip to content

Commit

Permalink
Unnecessary type-cast
Browse files Browse the repository at this point in the history
  • Loading branch information
jan.nijtmans committed Nov 6, 2024
1 parent ffff731 commit 7c22fb2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions macosx/tkMacOSXFont.c
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ struct SystemFontMapEntry {

#define ThemeFont(n, ...) { kTheme##n##Font, "system" #n "Font", ##__VA_ARGS__ }
static const struct SystemFontMapEntry systemFontMap[] = {
ThemeFont(System, "TkDefaultFont", "TkIconFont"),
ThemeFont(System, "TkDefaultFont", "TkIconFont"),
ThemeFont(EmphasizedSystem, "TkCaptionFont", NULL),
ThemeFont(SmallSystem, "TkHeadingFont", "TkTooltipFont"),
ThemeFont(SmallEmphasizedSystem, NULL, NULL),
Expand Down Expand Up @@ -470,7 +470,7 @@ startOfClusterObjCmd(
/* The string contains codepoints > \uFFFF. Determine UTF-16 index */
Tcl_Size newIdx = 0;
for (Tcl_Size i = 0; i < idx; i++) {
newIdx += 1 + (((newIdx < (Tcl_Size)len-1) && ([S characterAtIndex:newIdx]&0xFC00) == 0xD800) && (([S characterAtIndex:newIdx+1]&0xFC00) == 0xDC00));
newIdx += 1 + (((newIdx < len-1) && ([S characterAtIndex:newIdx]&0xFC00) == 0xD800) && (([S characterAtIndex:newIdx+1]&0xFC00) == 0xDC00));
}
idx = newIdx;
}
Expand Down Expand Up @@ -903,7 +903,7 @@ void
TkpGetFontAttrsForChar(
TCL_UNUSED(Tk_Window), /* Window on the font's display */
Tk_Font tkfont, /* Font to query */
int c, /* Character of interest */
int c, /* Character of interest */
TkFontAttributes* faPtr) /* Output: Font attributes */
{
MacFont *fontPtr = (MacFont *) tkfont;
Expand Down

0 comments on commit 7c22fb2

Please sign in to comment.