diff options
| author | YAMAMOTO Mitsuharu | 2008-04-06 01:59:20 +0000 |
|---|---|---|
| committer | YAMAMOTO Mitsuharu | 2008-04-06 01:59:20 +0000 |
| commit | db4bb66a325e056a4223abbf00249a2a8c0e658f (patch) | |
| tree | 7ffb036efd98045415b1bcbd618794e5ab962cfb /src | |
| parent | f2ec385ecd26c73ea9014ddfa009999b4cc2b24b (diff) | |
| download | emacs-db4bb66a325e056a4223abbf00249a2a8c0e658f.tar.gz emacs-db4bb66a325e056a4223abbf00249a2a8c0e658f.zip | |
(FRAME_OUTER_TO_INNER_DIFF_X, FRAME_OUTER_TO_INNER_DIFF_Y):
Move to mactoolbox.c.
(HOURGLASS_WIDTH, HOURGLASS_HEIGHT): Change to 15.
(Fx_selection_owner_p): Add EXFUN.
(install_window_handler, remove_window_handler, XSetWindowBackground):
Remove externs.
(do_apple_menu) [!TARGET_API_MAC_CARBON]: Likewise.
(mac_prepare_for_quickdraw) [USE_CG_DRAWING]: Likewise.
(x_raise_frame, x_lower_frame, mac_alert_sound_play)
(install_application_handler, mac_get_frame_bounds, mac_get_frame_mouse)
(mac_convert_frame_point_to_global, mac_set_frame_window_background)
(mac_update_begin mac_update_end, mac_frame_up_to_date, x_flush)
(mac_create_frame_window, mac_dispose_frame_window, mac_begin_clip)
(mac_end_clip, mac_create_scroll_bar, mac_dispose_scroll_bar)
(mac_set_scroll_bar_bounds, mac_redraw_scroll_bar, mac_fill_menubar)
(create_and_show_popup_menu, mac_get_selection_from_symbol)
(mac_valid_selection_target_p, mac_clear_selection)
(mac_get_selection_ownership_info, mac_valid_selection_value_p)
(mac_put_selection_value, mac_selection_has_target_p)
(mac_get_selection_value, mac_get_selection_target_list): Add externs.
(mac_update_proxy_icon, mac_show_hourglass, mac_hide_hourglass)
(mac_reposition_hourglass, mac_file_dialog, create_and_show_dialog)
(mac_dnd_default_known_types) [TARGET_API_MAC_CARBON]: Likewise.
(mac_run_loop_run_once) [MAC_OSX]: Likewise.
(mac_dialog) [!TARGET_API_MAC_CARBON]: Likewise.
(mac_begin_cg_clip, mac_end_cg_clip) [USE_CG_DRAWING]: Likewise.
(x_set_toolkit_scroll_bar_thumb) [!USE_TOOLKIT_SCROLL_BARS]: Likewise.
(x_scroll_bar_set_handle) [!USE_TOOLKIT_SCROLL_BARS]: Likewise.
Diffstat (limited to 'src')
| -rw-r--r-- | src/macterm.h | 116 |
1 files changed, 86 insertions, 30 deletions
diff --git a/src/macterm.h b/src/macterm.h index c95d464544a..8b9eda7a3bb 100644 --- a/src/macterm.h +++ b/src/macterm.h | |||
| @@ -379,12 +379,6 @@ typedef struct mac_output mac_output; | |||
| 379 | /* This is the 'font_info *' which frame F has. */ | 379 | /* This is the 'font_info *' which frame F has. */ |
| 380 | #define FRAME_MAC_FONT_TABLE(f) (FRAME_MAC_DISPLAY_INFO (f)->font_table) | 380 | #define FRAME_MAC_FONT_TABLE(f) (FRAME_MAC_DISPLAY_INFO (f)->font_table) |
| 381 | 381 | ||
| 382 | /* The difference in pixels between the top left corner of the | ||
| 383 | Emacs window (including possible window manager decorations) | ||
| 384 | and FRAME_MAC_WINDOW (f). */ | ||
| 385 | #define FRAME_OUTER_TO_INNER_DIFF_X(f) ((f)->x_pixels_diff) | ||
| 386 | #define FRAME_OUTER_TO_INNER_DIFF_Y(f) ((f)->y_pixels_diff) | ||
| 387 | |||
| 388 | /* Value is the smallest width of any character in any font on frame F. */ | 382 | /* Value is the smallest width of any character in any font on frame F. */ |
| 389 | 383 | ||
| 390 | #define FRAME_SMALLEST_CHAR_WIDTH(F) \ | 384 | #define FRAME_SMALLEST_CHAR_WIDTH(F) \ |
| @@ -557,8 +551,8 @@ struct scroll_bar { | |||
| 557 | #define MAC_AQUA_SMALL_VERTICAL_SCROLL_BAR_WIDTH (11) | 551 | #define MAC_AQUA_SMALL_VERTICAL_SCROLL_BAR_WIDTH (11) |
| 558 | 552 | ||
| 559 | /* Size of hourglass controls */ | 553 | /* Size of hourglass controls */ |
| 560 | #define HOURGLASS_WIDTH (16) | 554 | #define HOURGLASS_WIDTH (15) |
| 561 | #define HOURGLASS_HEIGHT (16) | 555 | #define HOURGLASS_HEIGHT (15) |
| 562 | 556 | ||
| 563 | /* Some constants that are used locally. */ | 557 | /* Some constants that are used locally. */ |
| 564 | /* Creator code for Emacs on Mac OS. */ | 558 | /* Creator code for Emacs on Mac OS. */ |
| @@ -632,6 +626,8 @@ extern int XParseGeometry P_ ((char *, int *, int *, unsigned int *, | |||
| 632 | extern void x_set_window_size P_ ((struct frame *, int, int, int)); | 626 | extern void x_set_window_size P_ ((struct frame *, int, int, int)); |
| 633 | extern void x_set_mouse_position P_ ((struct frame *, int, int)); | 627 | extern void x_set_mouse_position P_ ((struct frame *, int, int)); |
| 634 | extern void x_set_mouse_pixel_position P_ ((struct frame *, int, int)); | 628 | extern void x_set_mouse_pixel_position P_ ((struct frame *, int, int)); |
| 629 | extern void x_raise_frame P_ ((struct frame *)); | ||
| 630 | extern void x_lower_frame P_ ((struct frame *)); | ||
| 635 | extern void x_make_frame_visible P_ ((struct frame *)); | 631 | extern void x_make_frame_visible P_ ((struct frame *)); |
| 636 | extern void x_make_frame_invisible P_ ((struct frame *)); | 632 | extern void x_make_frame_invisible P_ ((struct frame *)); |
| 637 | extern void x_iconify_frame P_ ((struct frame *)); | 633 | extern void x_iconify_frame P_ ((struct frame *)); |
| @@ -651,29 +647,12 @@ extern GC XCreateGC P_ ((Display *, void *, unsigned long, XGCValues *)); | |||
| 651 | extern void XFreeGC P_ ((Display *, GC)); | 647 | extern void XFreeGC P_ ((Display *, GC)); |
| 652 | extern void XSetForeground P_ ((Display *, GC, unsigned long)); | 648 | extern void XSetForeground P_ ((Display *, GC, unsigned long)); |
| 653 | extern void XSetBackground P_ ((Display *, GC, unsigned long)); | 649 | extern void XSetBackground P_ ((Display *, GC, unsigned long)); |
| 654 | extern void XSetWindowBackground P_ ((Display *, WindowRef, unsigned long)); | ||
| 655 | extern void XDrawLine P_ ((Display *, Pixmap, GC, int, int, int, int)); | 650 | extern void XDrawLine P_ ((Display *, Pixmap, GC, int, int, int, int)); |
| 656 | extern void mac_clear_area P_ ((struct frame *, int, int, | 651 | extern void mac_clear_area P_ ((struct frame *, int, int, |
| 657 | unsigned int, unsigned int)); | 652 | unsigned int, unsigned int)); |
| 658 | extern void mac_unload_font P_ ((struct mac_display_info *, XFontStruct *)); | 653 | extern void mac_unload_font P_ ((struct mac_display_info *, XFontStruct *)); |
| 659 | extern int mac_font_panel_visible_p P_ ((void)); | ||
| 660 | extern OSStatus mac_show_hide_font_panel P_ ((void)); | ||
| 661 | extern OSStatus mac_set_font_info_for_selection P_ ((struct frame *, int, int)); | ||
| 662 | extern OSStatus install_window_handler P_ ((WindowRef)); | ||
| 663 | extern void remove_window_handler P_ ((WindowRef)); | ||
| 664 | extern OSStatus mac_post_mouse_moved_event P_ ((void)); | 654 | extern OSStatus mac_post_mouse_moved_event P_ ((void)); |
| 665 | #if !TARGET_API_MAC_CARBON | ||
| 666 | extern void do_apple_menu P_ ((SInt16)); | ||
| 667 | #endif | ||
| 668 | #if USE_CG_DRAWING | ||
| 669 | extern void mac_prepare_for_quickdraw P_ ((struct frame *)); | ||
| 670 | #endif | ||
| 671 | extern void mac_get_window_bounds P_ ((struct frame *, Rect *, Rect *)); | ||
| 672 | extern int mac_quit_char_key_p P_ ((UInt32, UInt32)); | 655 | extern int mac_quit_char_key_p P_ ((UInt32, UInt32)); |
| 673 | #if USE_MAC_TOOLBAR | ||
| 674 | extern void update_frame_tool_bar P_ ((FRAME_PTR f)); | ||
| 675 | extern void free_frame_tool_bar P_ ((FRAME_PTR f)); | ||
| 676 | #endif | ||
| 677 | 656 | ||
| 678 | #define FONT_TYPE_FOR_UNIBYTE(font, ch) 0 | 657 | #define FONT_TYPE_FOR_UNIBYTE(font, ch) 0 |
| 679 | #define FONT_TYPE_FOR_MULTIBYTE(font, ch) 0 | 658 | #define FONT_TYPE_FOR_MULTIBYTE(font, ch) 0 |
| @@ -681,6 +660,7 @@ extern void free_frame_tool_bar P_ ((FRAME_PTR f)); | |||
| 681 | /* Defined in macselect.c */ | 660 | /* Defined in macselect.c */ |
| 682 | 661 | ||
| 683 | extern void x_clear_frame_selections P_ ((struct frame *)); | 662 | extern void x_clear_frame_selections P_ ((struct frame *)); |
| 663 | EXFUN (Fx_selection_owner_p, 1); | ||
| 684 | 664 | ||
| 685 | /* Defined in macfns.c */ | 665 | /* Defined in macfns.c */ |
| 686 | 666 | ||
| @@ -697,11 +677,6 @@ extern void x_set_tool_bar_lines P_ ((struct frame *, Lisp_Object, Lisp_Object)) | |||
| 697 | extern void mac_update_title_bar P_ ((struct frame *, int)); | 677 | extern void mac_update_title_bar P_ ((struct frame *, int)); |
| 698 | extern Lisp_Object x_get_focus_frame P_ ((struct frame *)); | 678 | extern Lisp_Object x_get_focus_frame P_ ((struct frame *)); |
| 699 | 679 | ||
| 700 | /* Defined in macmenu.c */ | ||
| 701 | |||
| 702 | extern void x_activate_menubar P_ ((struct frame *)); | ||
| 703 | extern void free_frame_menubar P_ ((struct frame *)); | ||
| 704 | |||
| 705 | /* Defined in mac.c. */ | 680 | /* Defined in mac.c. */ |
| 706 | 681 | ||
| 707 | extern void mac_clear_font_name_table P_ ((void)); | 682 | extern void mac_clear_font_name_table P_ ((void)); |
| @@ -733,5 +708,86 @@ extern Lisp_Object xrm_get_resource P_ ((XrmDatabase, const char *, | |||
| 733 | extern XrmDatabase xrm_get_preference_database P_ ((const char *)); | 708 | extern XrmDatabase xrm_get_preference_database P_ ((const char *)); |
| 734 | EXFUN (Fmac_get_preference, 4); | 709 | EXFUN (Fmac_get_preference, 4); |
| 735 | 710 | ||
| 711 | /* Defined in mactoolbox.c. */ | ||
| 712 | |||
| 713 | extern void mac_alert_sound_play P_ ((void)); | ||
| 714 | extern OSStatus install_application_handler P_ ((void)); | ||
| 715 | extern void mac_get_window_bounds P_ ((struct frame *, Rect *, Rect *)); | ||
| 716 | extern Rect *mac_get_frame_bounds P_ ((struct frame *, Rect *)); | ||
| 717 | extern void mac_get_frame_mouse P_ ((struct frame *, Point *)); | ||
| 718 | extern void mac_convert_frame_point_to_global P_ ((struct frame *, int *, | ||
| 719 | int *)); | ||
| 720 | #if TARGET_API_MAC_CARBON | ||
| 721 | extern void mac_update_proxy_icon P_ ((struct frame *)); | ||
| 722 | #endif | ||
| 723 | extern void mac_set_frame_window_background P_ ((struct frame *, | ||
| 724 | unsigned long)); | ||
| 725 | extern void mac_update_begin P_ ((struct frame *)); | ||
| 726 | extern void mac_update_end P_ ((struct frame *)); | ||
| 727 | extern void mac_frame_up_to_date P_ ((struct frame *)); | ||
| 728 | extern void x_flush P_ ((struct frame *)); | ||
| 729 | extern void mac_create_frame_window P_ ((struct frame *, int)); | ||
| 730 | extern void mac_dispose_frame_window P_ ((struct frame *)); | ||
| 731 | #if USE_CG_DRAWING | ||
| 732 | extern CGContextRef mac_begin_cg_clip P_ ((struct frame *, GC)); | ||
| 733 | extern void mac_end_cg_clip P_ ((struct frame *)); | ||
| 734 | #endif | ||
| 735 | extern void mac_begin_clip P_ ((struct frame *, GC)); | ||
| 736 | extern void mac_end_clip P_ ((struct frame *, GC)); | ||
| 737 | extern void mac_create_scroll_bar P_ ((struct scroll_bar *, const Rect *, | ||
| 738 | Boolean)); | ||
| 739 | extern void mac_dispose_scroll_bar P_ ((struct scroll_bar *)); | ||
| 740 | extern void mac_set_scroll_bar_bounds P_ ((struct scroll_bar *, const Rect *)); | ||
| 741 | extern void mac_redraw_scroll_bar P_ ((struct scroll_bar *)); | ||
| 742 | #ifdef USE_TOOLKIT_SCROLL_BARS | ||
| 743 | extern void x_set_toolkit_scroll_bar_thumb P_ ((struct scroll_bar *, | ||
| 744 | int, int, int)); | ||
| 745 | #else | ||
| 746 | extern void x_scroll_bar_set_handle P_ ((scroll_bar *, int, int, int)); | ||
| 747 | #endif | ||
| 748 | #if USE_MAC_FONT_PANEL | ||
| 749 | extern int mac_font_panel_visible_p P_ ((void)); | ||
| 750 | extern OSStatus mac_show_hide_font_panel P_ ((void)); | ||
| 751 | extern OSStatus mac_set_font_info_for_selection P_ ((struct frame *, int, int)); | ||
| 752 | #endif | ||
| 753 | #ifdef MAC_OSX | ||
| 754 | extern Boolean mac_run_loop_run_once P_ ((EventTimeout)); | ||
| 755 | #endif | ||
| 756 | #if USE_MAC_TOOLBAR | ||
| 757 | extern void update_frame_tool_bar P_ ((FRAME_PTR f)); | ||
| 758 | extern void free_frame_tool_bar P_ ((FRAME_PTR f)); | ||
| 759 | #endif | ||
| 760 | #if TARGET_API_MAC_CARBON | ||
| 761 | extern void mac_show_hourglass P_ ((struct frame *)); | ||
| 762 | extern void mac_hide_hourglass P_ ((struct frame *)); | ||
| 763 | extern void mac_reposition_hourglass P_ ((struct frame *)); | ||
| 764 | extern Lisp_Object mac_file_dialog P_ ((Lisp_Object, Lisp_Object, Lisp_Object, | ||
| 765 | Lisp_Object, Lisp_Object)); | ||
| 766 | #endif | ||
| 767 | extern void x_activate_menubar P_ ((struct frame *)); | ||
| 768 | extern void free_frame_menubar P_ ((struct frame *)); | ||
| 769 | extern void mac_fill_menubar P_ ((widget_value *, int)); | ||
| 770 | extern void create_and_show_popup_menu P_ ((FRAME_PTR, widget_value *, | ||
| 771 | int, int, int)); | ||
| 772 | #if TARGET_API_MAC_CARBON | ||
| 773 | extern void create_and_show_dialog P_ ((FRAME_PTR, widget_value *)); | ||
| 774 | #else | ||
| 775 | extern int mac_dialog P_ ((widget_value *)); | ||
| 776 | #endif | ||
| 777 | extern OSStatus mac_get_selection_from_symbol P_ ((Lisp_Object, int, | ||
| 778 | Selection *)); | ||
| 779 | extern int mac_valid_selection_target_p P_ ((Lisp_Object)); | ||
| 780 | extern OSStatus mac_clear_selection P_ ((Selection *)); | ||
| 781 | extern Lisp_Object mac_get_selection_ownership_info P_ ((Selection)); | ||
| 782 | extern int mac_valid_selection_value_p P_ ((Lisp_Object, Lisp_Object)); | ||
| 783 | extern OSStatus mac_put_selection_value P_ ((Selection, Lisp_Object, | ||
| 784 | Lisp_Object)); | ||
| 785 | extern int mac_selection_has_target_p P_ ((Selection, Lisp_Object)); | ||
| 786 | extern Lisp_Object mac_get_selection_value P_ ((Selection, Lisp_Object)); | ||
| 787 | extern Lisp_Object mac_get_selection_target_list P_ ((Selection)); | ||
| 788 | #if TARGET_API_MAC_CARBON | ||
| 789 | extern Lisp_Object mac_dnd_default_known_types P_ ((void)); | ||
| 790 | #endif | ||
| 791 | |||
| 736 | /* arch-tag: 6b4ca125-5bef-476d-8ee8-31ed808b7e79 | 792 | /* arch-tag: 6b4ca125-5bef-476d-8ee8-31ed808b7e79 |
| 737 | (do not change this comment) */ | 793 | (do not change this comment) */ |