Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | Merged core-8-5-branch |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | tip-438 |
Files: | files | file ages | folders |
SHA1: |
ff1b18fe04cf7352426eeb6bc8cac27d |
User & Date: | fvogel 2015-11-28 21:39:01.563 |
Original Comment: | Merged core-8-5branch |
Context
2015-11-28
| ||
22:18 | Fixed indentation check-in: ec3ea7f7 user: fvogel tags: tip-438 | |
21:39 | Merged core-8-5-branch check-in: ff1b18fe user: fvogel tags: tip-438 | |
21:38 | Text widget documentation updated according to TIP #438 check-in: 1e6f4294 user: fvogel tags: tip-438 | |
2015-11-26
| ||
13:55 | On cygwin, install libtk8.5.dll.a in the {prefix}/lib directory. check-in: 4300e28b user: jan.nijtmans tags: core-8-5-branch | |
Changes
Changes to generic/tkImgPhoto.c.
︙ | |||
2450 2451 2452 2453 2454 2455 2456 | 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 | + - + + + + | case GrayScale: case StaticGray: nRed = 1 << visInfoPtr->depth; break; } XFree((char *) visInfoPtr); if (mono) { |
︙ |
Changes to macosx/tkMacOSXDialog.c.
1 2 3 4 5 6 7 8 9 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 | - - - + + + + + + + + + + + + + - + - + - + - + - + - + - + - + - - - + + + | /* * tkMacOSXDialog.c -- * * Contains the Mac implementation of the common dialog boxes. * * Copyright (c) 1996-1997 Sun Microsystems, Inc. * Copyright 2001-2009, Apple Inc. * Copyright (c) 2006-2009 Daniel A. Steffen <[email protected]> * |
︙ | |||
130 131 132 133 134 135 136 137 138 139 | 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 | + + + + + + + + + + + + + + + + + - + - - + + + + + - + - + - + | [TYPE_OK] = {3, 0, 0}, [TYPE_OKCANCEL] = {3, 4, 0}, [TYPE_RETRYCANCEL] = {1, 4, 0}, [TYPE_YESNO] = {5, 6, 0}, [TYPE_YESNOCANCEL] = {5, 6, 4}, }; /* * Construct a file URL from directory and filename. Either may * be nil. If both are nil, returns nil. */ #if MAC_OS_X_VERSION_MIN_REQUIRED > 1050 static NSURL *getFileURL(NSString *directory, NSString *filename) { NSURL *url = nil; if (directory) { url = [NSURL fileURLWithPath:directory]; } if (filename) { url = [NSURL URLWithString:filename relativeToURL:url]; } return url; } #endif #pragma mark TKApplication(TKDialog) @interface NSColorPanel(TKDialog) |
︙ | |||
175 176 177 178 179 180 181 | 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 | - + - + | Tcl_ResetResult(callbackInfo->interp); } if (panel == [NSApp modalWindow]) { [NSApp stopModalWithCode:returnCode]; } if (callbackInfo->cmdObj) { Tcl_DecrRefCount(callbackInfo->cmdObj); |
︙ | |||
207 208 209 210 211 212 213 | 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 | - + | } } if ([alert window] == [NSApp modalWindow]) { [NSApp stopModalWithCode:returnCode]; } if (callbackInfo->cmdObj) { Tcl_DecrRefCount(callbackInfo->cmdObj); |
︙ | |||
248 249 250 251 252 253 254 | 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 | - + - - + + + - + - - + - - + + - - - - - - - - - - - - - - + + + + + + + + + + + + + + - - - - + + + - - + + | int i; NSColor *color = nil, *initialColor = nil; NSColorPanel *colorPanel; NSInteger returnCode, numberOfComponents = 0; for (i = 1; i < objc; i += 2) { int index; |
︙ | |||
361 362 363 364 365 366 367 | 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 | - + - - + + + - - + + | FilePanelCallbackInfo callbackInfoStruct; FilePanelCallbackInfo *callbackInfo = &callbackInfoStruct; NSString *directory = nil, *filename = nil; NSString *message, *title, *type; NSWindow *parent; NSMutableArray *fileTypes = nil; NSOpenPanel *panel = [NSOpenPanel openPanel]; |
︙ | |||
430 431 432 433 434 435 436 437 438 439 440 441 442 443 | 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 | + | typeVariablePtr = objv[i + 1]; break; case OPEN_COMMAND: cmdObj = objv[i+1]; break; } } [panel setAllowsMultipleSelection:multiple]; if (fl.filters) { fileTypes = [NSMutableArray array]; for (FileFilter *filterPtr = fl.filters; filterPtr; filterPtr = filterPtr->next) { for (FileFilterClause *clausePtr = filterPtr->clauses; clausePtr; clausePtr = clausePtr->next) { for (GlobPattern *globPtr = clausePtr->patterns; globPtr; |
︙ | |||
462 463 464 465 466 467 468 | 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 | - + - + - + - - - - - - + + + + + + + + + + + + + + + + + + + - - - + + + + + + + - + - - + + + - + | [fileTypes addObject:type]; } } } } } } |
︙ | |||
539 540 541 542 543 544 545 | 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 | - + - - + + + - + - - + | FilePanelCallbackInfo callbackInfoStruct; FilePanelCallbackInfo *callbackInfo = &callbackInfoStruct; NSString *directory = nil, *filename = nil, *defaultType = nil; NSString *message, *title, *type; NSWindow *parent; NSMutableArray *fileTypes = nil; NSSavePanel *panel = [NSSavePanel savePanel]; |
︙ | |||
610 611 612 613 614 615 616 | 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 | - + | case SAVE_TYPEVARIABLE: break; case SAVE_COMMAND: cmdObj = objv[i+1]; break; case SAVE_CONFIRMOW: if (Tcl_GetBooleanFromObj(interp, objv[i + 1], |
︙ | |||
645 646 647 648 649 650 651 | 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 | - + - + - - - - - - + + + + + + + + + + + + + + + + + - - + + + + + + - - + + + | } [panel setAllowedFileTypes:fileTypes]; [panel setAllowsOtherFileTypes:YES]; } [panel setCanSelectHiddenExtension:YES]; [panel setExtensionHidden:NO]; if (cmdObj) { |
︙ | |||
710 711 712 713 714 715 716 | 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 | - + - - + + + - - + + | Tcl_Obj *cmdObj = NULL; FilePanelCallbackInfo callbackInfoStruct; FilePanelCallbackInfo *callbackInfo = &callbackInfoStruct; NSString *directory = nil, *filename = nil; NSString *message, *title; NSWindow *parent; NSOpenPanel *panel = [NSOpenPanel openPanel]; |
︙ | |||
766 767 768 769 770 771 772 | 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 | - + - + - - - + + + + + + + + + + - - + + + + + - - + + + + + + - - + + + | } } [panel setPrompt:@"Choose"]; [panel setCanChooseFiles:NO]; [panel setCanChooseDirectories:YES]; [panel setCanCreateDirectories:!mustexist]; if (cmdObj) { |
︙ | |||
814 815 816 817 818 819 820 | 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 | - + + + + + + + - - + + + + + - + - - - - - - + + + + + + | *---------------------------------------------------------------------- */ void TkAboutDlg(void) { NSImage *image; |
︙ | |||
880 881 882 883 884 885 886 | 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 | - + | int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ { if (objc > 1) { Tcl_WrongNumArgs(interp, 1, objv, NULL); return TCL_ERROR; } |
︙ | |||
918 919 920 921 922 923 924 | 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 | - + - - + + + - - + + - - + + | int defaultNativeButtonIndex = 1; /* 1, 2, 3: right to left */ Tcl_Obj *cmdObj = NULL; AlertCallbackInfo callbackInfoStruct, *callbackInfo = &callbackInfoStruct; NSString *message, *title; NSWindow *parent; NSArray *buttons; NSAlert *alert = [NSAlert new]; |
︙ | |||
980 981 982 983 984 985 986 | 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 | - - + + - - + + - - + + - + + + - - + + - + + - - - - - + + + + + + + + + + + + + - - + + - - + + | title = [[NSString alloc] initWithUTF8String: Tcl_GetString(objv[i + 1])]; [[alert window] setTitle:title]; [title release]; break; case ALERT_TYPE: |
︙ |
Changes to macosx/tkMacOSXDraw.c.
︙ | |||
671 672 673 674 675 676 677 | 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 | - + | kCGBitmapByteOrderDefault; #endif char *data; CGRect bounds = CGRectMake(0, 0, macDraw->size.width, macDraw->size.height); if (macDraw->flags & TK_IS_BW_PIXMAP) { bitsPerPixel = 8; |
︙ |
Changes to macosx/tkMacOSXFont.c.
︙ | |||
11 12 13 14 15 16 17 18 19 20 21 22 23 24 | 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | + + + + + + + + + + + + + | * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. */ #include "tkMacOSXPrivate.h" #include "tkMacOSXFont.h" #if MAC_OS_X_VERSION_MIN_REQUIRED < 1080 #define defaultOrientation kCTFontDefaultOrientation #define verticalOrientation kCTFontVerticalOrientation #else #define defaultOrientation kCTFontOrientationDefault #define verticalOrientation kCTFontOrientationVertical #endif #if MAC_OS_X_VERSION_MIN_REQUIRED < 101100 #define fixedPitch kCTFontUserFixedPitchFontType #else #define fixedPitch kCTFontUIFontUserFixedPitch #endif /* #ifdef TK_MAC_DEBUG #define TK_MAC_DEBUG_FONTS #endif */ /* |
︙ | |||
266 267 268 269 270 271 272 | 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 | - + | */ bounds = [nsFont boundingRectForFont]; if (CTFontGetGlyphsForCharacters((CTFontRef) nsFont, ch, glyphs, nCh)) { fmPtr->fixed = [nsFont advancementForGlyph:glyphs[0]].width == [nsFont advancementForGlyph:glyphs[1]].width; bounds = NSRectFromCGRect(CTFontGetBoundingRectsForGlyphs((CTFontRef) |
︙ | |||
378 379 380 381 382 383 384 | 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 | - + - | CreateNamedSystemFont(interp, tkwin, systemFont->tkName1, &fa); } CFRelease(nsFont); } systemFont++; } TkInitFontAttributes(&fa); |
︙ |
Changes to macosx/tkMacOSXHLEvents.c.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 | + + + - - - - + + + + - - - - - - - - - - - - + + - + - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - + + - + - + - - - - + - - + - - + - - - + + + - - - + + + - - - + + + - - - + + + - - - + + + - - - - + + + - - - + - + - - - + - - - - - - - - - - - - - - - - + - - - - - - - - - + - - - - - - - - - + - - - - + - - - - - + - - - - - - - - - - - - - - - - + - - - - - - - - - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - - - - - - - - - - - - - - - - - + + - - - - - - - - - + - - - - - - - - - - + - - - - - - - - - - - - - - - - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + - - - - - - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - - - - - - - - - - - - - - - + + + + - - - - - - - + - - - - - + - - - - - - - - - - - - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | /* * tkMacOSXHLEvents.c -- * * Implements high level event support for the Macintosh. Currently, the * only event that really does anything is the Quit event. * * Copyright (c) 1995-1997 Sun Microsystems, Inc. * Copyright 2001-2009, Apple Inc. * Copyright (c) 2006-2009 Daniel A. Steffen <[email protected]> * Copyright (c) 2015 Marc Culler * * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. */ #include "tkMacOSXPrivate.h" #include <sys/param.h> #define URL_MAX_LENGTH (17 + MAXPATHLEN) /* * This is a Tcl_Event structure that the Quit AppleEvent handler uses to * schedule the ReallyKillMe function. */ typedef struct KillEvent { Tcl_Event header; /* Information that is standard for all * events. */ Tcl_Interp *interp; /* Interp that was passed to the Quit * AppleEvent */ } KillEvent; /* * Static functions used only in this file. */ |
︙ | |||
662 663 664 665 666 667 668 | 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 | - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | OSStatus err; err = AEGetAttributePtr(theEvent, keyMissedKeywordAttr, typeWildCard, &returnedType, NULL, 0, &actualSize); return (err != errAEDescNotFound); } |
Changes to macosx/tkMacOSXMenu.c.
︙ | |||
788 789 790 791 792 793 794 | 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 | - + | inPostMenu = 1; int oldMode = Tcl_SetServiceMode(TCL_SERVICE_NONE); NSView *view = [win contentView]; NSRect frame = NSMakeRect(x + 9, tkMacOSXZeroScreenHeight - y - 9, 1, 1); frame.origin = [view convertPoint: |
︙ |
Changes to macosx/tkMacOSXMouseEvent.c.
︙ | |||
22 23 24 25 26 27 28 | 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 | - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - - - - - - + + + + + + - - - - + + - + | Window window; Point global; Point local; } MouseEventData; static int GenerateButtonEvent(MouseEventData *medPtr); static unsigned int ButtonModifiers2State(UInt32 buttonState, |
︙ | |||
129 130 131 132 133 134 135 | 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 | - + + + + + + + + + - - - - - + + + - + - - + + - + | buttonNumber = [theEvent buttonNumber]; } #endif case NSTabletPoint: case NSTabletProximity: case NSScrollWheel: break; |
︙ | |||
183 184 185 186 187 188 189 | 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 | - + | UInt32 buttons; OSStatus err = GetEventParameter(eventRef, kEventParamMouseChord, typeUInt32, NULL, sizeof(UInt32), NULL, &buttons); if (err == noErr) { state |= (buttons & ((1<<5) - 1)) << 8; } else { if (button < 5) { |
︙ | |||
220 221 222 223 224 225 226 | 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 | - + - + - + + - + + | if (modifiers & NSNumericPadKeyMask) { state |= Mod3Mask; } if (modifiers & NSFunctionKeyMask) { state |= Mod4Mask; } |
︙ | |||
420 421 422 423 424 425 426 | 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 | - + | if (getLocal) { MacDrawable *macWin = (MacDrawable *) w; NSWindow *win = TkMacOSXDrawableWindow(w); if (win) { NSPoint local; |
︙ | |||
518 519 520 521 522 523 524 | 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 | - + | med.global.h = x; med.global.v = y; med.local = med.global; if (win) { NSPoint local = NSMakePoint(x, tkMacOSXZeroScreenHeight - y); |
︙ |
Changes to macosx/tkMacOSXPrivate.h.
︙ | |||
290 291 292 293 294 295 296 297 298 299 300 301 302 303 | 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 | + + + + + + + + + + + + + + + + + + | @interface TKApplication(TKMenu) - (void)tkSetMainMenu:(TKMenu *)menu; @end @interface TKApplication(TKClipboard) - (void)tkProvidePasteboard:(TkDisplay *)dispPtr; - (void)tkCheckPasteboard; @end @interface TKApplication(TKHLEvents) - (void) terminate: (id) sender; - (void) preferences: (id) sender; - (void) handleQuitApplicationEvent: (NSAppleEventDescriptor *)event withReplyEvent: (NSAppleEventDescriptor *)replyEvent; - (void) handleOpenApplicationEvent: (NSAppleEventDescriptor *)event withReplyEvent: (NSAppleEventDescriptor *)replyEvent; - (void) handleReopenApplicationEvent: (NSAppleEventDescriptor *)event withReplyEvent: (NSAppleEventDescriptor *)replyEvent; - (void) handleShowPreferencesEvent: (NSAppleEventDescriptor *)event withReplyEvent: (NSAppleEventDescriptor *)replyEvent; - (void) handleOpenDocumentsEvent: (NSAppleEventDescriptor *)event withReplyEvent: (NSAppleEventDescriptor *)replyEvent; - (void) handlePrintDocumentsEvent: (NSAppleEventDescriptor *)event withReplyEvent: (NSAppleEventDescriptor *)replyEvent; - (void) handleDoScriptEvent: (NSAppleEventDescriptor *)event withReplyEvent: (NSAppleEventDescriptor *)replyEvent; @end VISIBILITY_HIDDEN @interface TKContentView : NSView <NSTextInput> { @private /*Remove private API calls.*/ #if 0 id _savedSubviews; |
︙ | |||
322 323 324 325 326 327 328 329 330 331 332 333 334 335 | 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 | + + + + + | - (BOOL) acceptsFirstResponder; - (void) keyDown: (NSEvent *) theEvent; @end VISIBILITY_HIDDEN @interface TKWindow : NSWindow @end @interface NSWindow(TKWm) - (NSPoint) convertPointToScreen:(NSPoint)point; - (NSPoint) convertPointFromScreen:(NSPoint)point; @end #pragma mark NSMenu & NSMenuItem Utilities @interface NSMenu(TKUtils) + (id)menuWithTitle:(NSString *)title; + (id)menuWithTitle:(NSString *)title menuItems:(NSArray *)items; + (id)menuWithTitle:(NSString *)title submenus:(NSArray *)submenus; |
︙ | |||
351 352 353 354 355 356 357 | 374 375 376 377 378 379 380 381 | - - - - - | keyEquivalent:(NSString *)keyEquivalent keyEquivalentModifierMask:(NSUInteger)keyEquivalentModifierMask; + (id)itemWithTitle:(NSString *)title action:(SEL)action target:(id)target keyEquivalent:(NSString *)keyEquivalent keyEquivalentModifierMask:(NSUInteger)keyEquivalentModifierMask; @end |
Changes to macosx/tkMacOSXWindowEvent.c.
︙ | |||
743 744 745 746 747 748 749 | 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 | - + + - - + - - + - + + + | * *---------------------------------------------------------------------- */ int Tk_MacOSXIsAppInFront(void) { |
︙ |
Changes to macosx/tkMacOSXWm.c.
︙ | |||
195 196 197 198 199 200 201 202 203 204 205 206 207 208 | 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 | + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + | /* * Hash table for Mac Window -> TkWindow mapping. */ static Tcl_HashTable windowTable; static int windowHashInit = false; #pragma mark NSWindow(TKWm) /* * Conversion of coordinates between window and screen. */ @implementation NSWindow(TKWm) #if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 - (NSPoint) convertPointToScreen: (NSPoint) point { return [self convertBaseToScreen:point]; } - (NSPoint) convertPointFromScreen: (NSPoint)point { return [self convertScreenToBase:point]; } @end #else - (NSPoint) convertPointToScreen: (NSPoint) point { NSRect pointrect; pointrect.origin = point; pointrect.size.width = 0; pointrect.size.height = 0; return [self convertRectToScreen:pointrect].origin; } - (NSPoint) convertPointFromScreen: (NSPoint)point { NSRect pointrect; pointrect.origin = point; pointrect.size.width = 0; pointrect.size.height = 0; return [self convertRectFromScreen:pointrect].origin; } @end #endif #pragma mark - /* * Forward declarations for procedures defined in this file: */ static NSRect InitialWindowBounds(TkWindow *winPtr, NSWindow *macWindow); |
︙ |
Changes to macosx/tkMacOSXXStubs.c.
︙ | |||
177 178 179 180 181 182 183 | 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 | + + + + - + + + + + + + + + + + | display->proto_minor_version = [[cgVers objectAtIndex:2] integerValue]; } if (!vendor[0]) { snprintf(vendor, sizeof(vendor), "Apple AppKit %g", NSAppKitVersionNumber); } display->vendor = vendor; { int major, minor, patch; #if MAC_OS_X_VERSION_MIN_REQUIRED < 1080 |
︙ |
Changes to unix/configure.
︙ | |||
7082 7083 7084 7085 7086 7087 7088 | 7082 7083 7084 7085 7086 7087 7088 7089 7090 7091 7092 7093 7094 7095 7096 | - + | if test "${SHARED_BUILD}" = 1 -a "${SHLIB_SUFFIX}" != ""; then LIB_SUFFIX=${SHARED_LIB_SUFFIX} MAKE_LIB='${SHLIB_LD} -o $@ ${OBJS} ${SHLIB_LD_LIBS} ${TCL_SHLIB_LD_EXTRAS} ${TK_SHLIB_LD_EXTRAS} ${LD_SEARCH_FLAGS}' if test "${SHLIB_SUFFIX}" = ".dll"; then |
︙ |
Changes to unix/tcl.m4.
︙ | |||
2065 2066 2067 2068 2069 2070 2071 | 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 | - + | UNSHARED_LIB_SUFFIX='${VERSION}.a']) DLL_INSTALL_DIR="\$(LIB_INSTALL_DIR)" AS_IF([test "${SHARED_BUILD}" = 1 -a "${SHLIB_SUFFIX}" != ""], [ LIB_SUFFIX=${SHARED_LIB_SUFFIX} MAKE_LIB='${SHLIB_LD} -o [$]@ ${OBJS} ${SHLIB_LD_LIBS} ${TCL_SHLIB_LD_EXTRAS} ${TK_SHLIB_LD_EXTRAS} ${LD_SEARCH_FLAGS}' AS_IF([test "${SHLIB_SUFFIX}" = ".dll"], [ |
︙ |