aboutsummaryrefslogtreecommitdiffstats
path: root/src/macterm.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* (XTread_socket): Undo previous change.YAMAMOTO Mitsuharu2006-07-181-7/+1
|
* (keycode_to_xkeysym): Remove function. All uses nowYAMAMOTO Mitsuharu2006-07-181-108/+118
| | | | | | | | | directly lookup keycode_to_xkeysym_table. [USE_MAC_TSM] (mac_handle_text_input_event): Don't construct ASCII_KEYSTROKE_EVENT for non-zero keycode_to_xkeysym_table entries. (XTread_socket): Use character codes to construct keypad key events. (mac_initialize_display_info) [MAC_OSX]: Use CGDisplaySamplesPerPixel. (x_delete_display): Apply 2006-07-04 change for xterm.c.
* (Qeql): Add extern.YAMAMOTO Mitsuharu2006-06-281-15/+78
| | | | | | | | | | | | | | | | | | (x_set_mouse_pixel_position) [MAC_OSX]: Use CGWarpMouseCursorPosition. (fm_style_face_attributes_alist) [USE_ATSUI]: New variable. (syms_of_macterm) [USE_ATSUI]: Initialize and staticpro it. Change keys of Vmac_atsu_font_table from strings to numbers. (fm_style_to_face_attributes) [USE_ATSUI]: New function. (init_font_name_table) [USE_ATSUI]: Use it. (saved_ts_script_language_on_focus) [USE_MAC_TSM]: New variable. (syms_of_macterm) [USE_MAC_TSM]: Initialize and staticpro it. [USE_MAC_TSM] (mac_tsm_resume): Restore script and language codes only when saved_ts_script_language_on_focus coincides with Vmac_ts_script_language_on_focus. [USE_MAC_TSM] (mac_tsm_suspend): Save value of Vmac_ts_script_language_on_focus to saved_ts_script_language_on_focus. (XTread_socket) [USE_MAC_TSM]: Add Mac OS Classic support. [USE_MAC_TSM] (mac_handle_text_input_event, init_tsm): Likewise.
* (do_app_resume, do_app_suspend): Remove functions.YAMAMOTO Mitsuharu2006-06-161-37/+104
| | | | | | | | | | (mac_tsm_resume, mac_tsm_suspend) [USE_MAC_TSM]: New functions. (mac_handle_window_event, XTread_socket) [USE_MAC_TSM]: Use them. (Vmac_ts_script_language_on_focus) [USE_MAC_TSM]: New variable. (syms_of_macterm) [USE_MAC_TSM]: Defvar it. (saved_ts_language, saved_ts_component) [USE_MAC_TSM]: New variables. (mac_initialize_display_info) [MAC_OSX]: Use Quartz Display Services functions to get size of main display in pixels.
* [USE_MAC_TSM] (mac_handle_text_input_event): Exclude 0x7f from ASCII range.YAMAMOTO Mitsuharu2006-06-061-1/+1
|
* (tsm_document_id) [USE_MAC_TSM]: New variable.YAMAMOTO Mitsuharu2006-06-031-5/+267
| | | | | | | | | | | | | | | | | | | | | (Qtext_input, Qupdate_active_input_area, Qunicode_for_key_event) [USE_MAC_TSM]: Likewise. (syms_of_macterm) [USE_MAC_TSM]: Intern and staticpro them. (Qbefore_string) [USE_MAC_TSM]: Add extern. (do_app_resume, do_app_suspend) [USE_MAC_TSM]: Call ActivateTSMDocument/DeactivateTSMDocument. (mac_store_event_ref_as_apple_event): Call mac_post_mouse_moved_event. (mac_handle_window_event) [USE_MAC_TSM]: Handle kEventWindowFocusAcquired/kEventWindowFocusRelinquish. (mac_handle_text_input_event) [USE_MAC_TSM]: New function. (install_window_handler) [USE_MAC_TSM]: Install it. Register kEventWindowFocusAcquired/kEventWindowFocusRelinquish. (keycode_to_xkeysym_table): Add entry for f16. (XTread_socket) [USE_MAC_TSM]: Set/reset read_socket_inev before/after passing keystroke event to toolbox dispatcher. (init_tsm) [USE_MAC_TSM]: New function. (mac_initialize) [USE_MAC_TSM]: Call it. (Vmac_ts_active_input_overlay) [USE_MAC_TSM]: New defvar.
* (mac_handle_visibility_change): Set buf.arg to Qnil.YAMAMOTO Mitsuharu2006-06-011-7/+6
| | | | (XTread_socket): Remove obsolete comment.
* (font_panel_shown_p) [USE_MAC_FONT_PANEL]: New variable.YAMAMOTO Mitsuharu2006-05-291-0/+22
| | | | | | | (mac_font_panel_visible_p, mac_show_hide_font_panel) [USE_MAC_FONT_PANEL]: New functions. [USE_MAC_FONT_PANEL] (mac_set_font_info_for_selection): Return immediately if font panel is not visible.
* (x_draw_stretch_glyph_string): Fix problems with invisibleKim F. Storm2006-05-271-9/+27
| | | | | cursor and erasing cursor on partially visible stretch glyph on left. (x_draw_hollow_cursor): Compute x via get_phys_cursor_geometry.
* (fn_keycode_to_keycode_table, XTread_socket) [MAC_OSX]:YAMAMOTO Mitsuharu2006-05-241-16/+21
| | | | Fix last change. Don't map `fn' modifier if pressed with F1 ... F12.
* (fn_keycode_to_xkeysym_table, convert_fn_keycode): Remove.YAMAMOTO Mitsuharu2006-05-231-169/+215
| | | | | | | | | (fn_keycode_to_keycode_table) [MAC_OSX]: New variable. (mac_set_unicode_keystroke_event) [TARGET_API_MAC_CARBON]: New function. (XTread_socket) [TARGET_API_MAC_CARBON]: Use it. (XTread_socket) [MAC_OSX]: Try 'uchr' Unicode keyboard-layout resource to backtranslate key with modifiers. (XTread_socket): Don't set read_socket_inev around AEProcessAppleEvent.
* (convert_fn_keycode): Fix last change.YAMAMOTO Mitsuharu2006-05-201-1/+1
|
* (XTread_socket) [TARGET_API_MAC_CARBON && MAC_OSX]:YAMAMOTO Mitsuharu2006-05-191-0/+3
| | | | Forward keyUp events to toolbox_dispatcher.
* (Qservice) [MAC_OSX]: Rename from Qservices. All uses changed.YAMAMOTO Mitsuharu2006-05-101-20/+43
| | | | | | | | | | [MAC_OSX] (mac_store_service_event): Rename from mac_store_services_event. All callers changed. [USE_MAC_FONT_PANEL] (mac_set_font_info_for_selection): Add args FACE_ID and C. All callers changed. (x_free_frame_resources) [USE_MAC_FONT_PANEL]: Call mac_set_font_info_for_selection when focus frame is destroyed. (XTread_socket): Revert to FrontNonFloatingWindow/FrontWindow.
* (XLoadQueryFont) [USE_ATSUI]: Set FMFontFamily valueYAMAMOTO Mitsuharu2006-05-071-70/+272
| | | | | | | | | | | | | | | | | | | | | | | | | | to font->mac_fontnum. [USE_MAC_FONT_PANEL] (mac_set_font_info_for_selection): New function. (x_new_focus_frame) [USE_MAC_FONT_PANEL]: Use it. (QCfamily, QCweight, QCslant, Qnormal, Qbold, Qitalic): Add extern. (QWindow) [MAC_OSX]: Likewise. (Qfont) [USE_MAC_FONT_PANEL]: Likewise. (Vmac_atsu_font_table) [USE_ATSUI]: New variable. (syms_of_macterm) [USE_ATSUI]: Defvar it. (Qtoolbar_switch_mode) [MAC_OSX]: New variable. (Qpanel_closed, Qselection) [USE_MAC_FONT_PANEL]: Likewise. (syms_of_macterm): Intern and staticpro them. (init_font_name_table) [USE_ATSUI]: Set data to Vmac_atsu_font_table. [TARGET_API_MAC_CARBON] (mac_store_event_ref_as_apple_event): New function. [USE_CARBON_EVENTS] (mac_handle_command_event): Use it. [MAC_OSX] (mac_store_services_event): Likewise. [USE_CARBON_EVENTS] (mac_handle_window_event) [MAC_OSX]: Handle kEventWindowToolbarSwitchMode event. (install_window_handler) [USE_CARBON_EVENTS && MAC_OSX]: Register it. [MAC_OSX] (mac_store_services_event): Change return type to OSStatus. [USE_MAC_FONT_PANEL] (mac_handle_font_event): New function. (install_window_handler) [USE_MAC_FONT_PANEL]: Install it. (XTread_socket): Select window on mouse click if x_focus_frame is NULL.
* (XTread_socket) [TARGET_API_MAC_CARBON]: Try windowYAMAMOTO Mitsuharu2006-05-051-244/+79
| | | | | | | | | | | | | | | | | path select also for proxy icon click. [TARGET_API_MAC_CARBON] (mac_post_mouse_moved_event): New function. [USE_TOOLKIT_SCROLL_BARS] (scroll_bar_timer_callback): Use it. (xlfdpat_create): Remove unused label `error' and trailing sentences. (mac_do_track_drag, mac_do_receive_drag): Move functions to macselect.c. (mac_do_track_dragUPP, mac_do_receive_dragUPP): Move variables to macselect.c. (install_drag_handler, remove_drag_handler): Add extern. (mac_store_apple_event): Change return type to void. All uses changed. Create Lisp object from Apple event and store it into input event. (mac_make_lispy_event_code): Remove function. [TARGET_API_MAC_CARBON] (mac_store_drag_event): New function. (install_window_handler): Call install_drag_handler. (remove_window_handler): Call remove_drag_handler.
* (mac_draw_line, mac_draw_line_to_pixmap): AdjustYAMAMOTO Mitsuharu2006-05-011-21/+98
| | | | | | | | | | | | | endpoints of strictly horizontal/vertical lines. (mac_set_clip_rectangles) [USE_CG_DRAWING]: Set clip_rects. (pcm_init, pcm_get_status): New functions. (x_per_char_metric, XLoadQueryFont): Use them instead of XCharStructRow and related macros. (x_draw_relief_rect): Don't adjust arguments of mac_draw_line. (x_free_frame_resources) [TARGET_API_MAC_CARBON]: Free FRAME_FILE_NAME. (XTread_socket) [TARGET_API_MAC_CARBON]: Handle proxy icon drag and window path pop-up menu on title bar. (mac_use_core_graphics) [USE_CG_DRAWING]: Set default to 1.
* (x_per_char_metric): Return NULL if glyph width is 0.YAMAMOTO Mitsuharu2006-04-211-64/+58
| | | | | | (add_mac_font_name): New function. (init_font_name_table): Use it. Adopt the first found font from those having the same family name.
* (XCreateGC, x_per_char_metric, xlfdpat_create)YAMAMOTO Mitsuharu2006-04-181-55/+21
| | | | | | (init_font_name_table, init_font_name_table, mac_do_list_fonts) (XLoadQueryFont, mac_store_apple_event): Don't check return value of xmalloc.
* Don't include gnu.h.YAMAMOTO Mitsuharu2006-04-121-292/+148
| | | | | | | | | | | | | | | | | | | | | | (x_io_error_quitter, x_draw_image_foreground_1): Remove prototypes. (x_sync): Move to macfns.c. [USE_CG_DRAWING] (mac_define_fringe_bitmap): Remove unused variable `mask_bits'. (mac_compute_glyph_string_overhangs): Avoid ambiguous `else'. (x_draw_image_glyph_string): Remove unused variable `pixmap'. (x_mac_to_emacs_modifiers): Remove function. (XTset_vertical_scroll_bar, mac_handle_visibility_change) (x_make_frame_visible, xlfdpat_create, mac_handle_command_event): Add explicit braces to avoid ambiguous `else'. (x_make_frame_visible): Remove unused variables `type', `original_top', and `original_left'. (mac_do_list_fonts, XTread_socket): Add parentheses around && within ||. (x_load_font): Remove unused variables `full_name', and `value'. (do_get_menus, do_init_managers, do_check_ram_size) [!MAC_OS8]: Remove functions. (do_zoom_window): Reorganize variables with respect to conditionals. (init_command_handler): Remove unused variable `err'. [MAC_OSX] (mac_check_bundle): Remove unused variable `child'.
* (XTread_socket): Initialize variable `f' before its use.YAMAMOTO Mitsuharu2006-04-031-1/+3
|
* (XTread_socket): Don't let key-press clear mouse faceKim F. Storm2006-03-241-1/+2
| | | | on in toolbar window if mouse-highlight is an integer.
* (XCreatePixmap) [!WORDS_BIG_ENDIAN && USE_CG_DRAWING]:YAMAMOTO Mitsuharu2006-03-161-7/+22
| | | | | | | | Create GWorld in ARGB pixel format. (mac_copy_area, mac_copy_area_with_mask) [USE_CG_DRAWING]: Remove functions. (x_draw_image_foreground) [USE_CG_DRAWING]: Use mac_draw_cg_image instead of mac_copy_area/mac_copy_area_with_mask.
* (mac_initialize) [USE_CG_DRAWING]: Call mac_init_fringe.YAMAMOTO Mitsuharu2006-03-151-6/+110
| | | | | | | | | | | (max_fringe_bmp, fringe_bmp) [USE_CG_DRAWING]: New variables. (mac_define_fringe_bitmap, mac_destroy_fringe_bitmap) (mac_draw_cg_image) [USE_CG_DRAWING]: New functions. (mac_draw_bitmap) [USE_CG_DRAWING]: Remove function. (x_draw_fringe_bitmap) [USE_CG_DRAWING]: Use mac_draw_cg_image instead of mac_draw_bitmap. (x_redisplay_interface) [USE_CG_DRAWING]: Set handlers for define_fringe_bitmap and destroy_fringe_bitmap.
* (mac_draw_rectangle, x_draw_glyph_string_foreground)YAMAMOTO Mitsuharu2006-03-121-34/+196
| | | | | | | | | | | | | | | | | | | (x_draw_composite_glyph_string_foreground) (x_draw_image_foreground): Undo previous changes. (x_draw_hollow_cursor): Likewise. Subtract 1 from the last argument of mac_draw_rectangle. (CG_SET_FILL_COLOR, CG_SET_STROKE_COLOR): New macros. (mac_draw_string_common, mac_draw_image_string_cg): Use them. (FRAME_CG_CONTEXT) [USE_CG_DRAWING]: New macro. (mac_begin_cg_clip, mac_end_cg_clip, mac_prepare_for_quickdraw) [USE_CG_DRAWING]: New functions. (mac_draw_line, mac_erase_rectangle, mac_clear_window) (mac_fill_rectangle, mac_draw_rectangle, mac_draw_string_common) (mac_draw_image_string_cg) [USE_CG_DRAWING]: Add Quartz 2D drawing part. (mac_draw_bitmap, mac_invert_rectangle, mac_draw_string_common) (mac_copy_area, mac_scroll_area, x_scroll_bar_create) (x_scroll_bar_remove, XTset_vertical_scroll_bar, x_set_window_size) (XTread_socket) [USE_CG_DRAWING]: Call mac_prepare_for_quickdraw.
* (mac_draw_rectangle): Don't add 1 to width and height.Eli Zaretskii2006-03-111-7/+7
| | | | | | | | (x_draw_glyph_string_foreground) (x_draw_composite_glyph_string_foreground) (x_draw_image_foreground): Don't subtract 1 from width and height arguments to mac_draw_rectangle. (x_draw_hollow_cursor): Add 1 to w->phys_cursor_width.
* (get_control_part_bounds): Fix type of return value.YAMAMOTO Mitsuharu2006-03-061-63/+108
| | | | | | | | | | (x_set_toolkit_scroll_bar_thumb, x_scroll_bar_create) (XTset_vertical_scroll_bar) [USE_TOOLKIT_SCROLL_BARS]: Don't show scroll bar if it is not tall enough to display scroll bar thumb. [USE_CARBON_EVENTS] (mac_convert_event_ref) (mac_handle_command_event, mac_handle_window_event) (mac_handle_mouse_event): Check error code of GetEventParameter. (convert_fn_keycode) [MAC_OSX]: Likewise.
* (x_set_toolkit_scroll_bar_thumb): Don't set controlYAMAMOTO Mitsuharu2006-02-231-9/+13
| | | | values if control is not visible or values are not changed.
* (GC_CLIP_REGION): Remove macro.YAMAMOTO Mitsuharu2006-02-221-41/+39
| | | | | | | | | | | | (mac_begin_clip, mac_end_clip): Take arg GC instead of REGION. All uses changed. Don't do clipping if n_clip_rects is zero. (mac_set_clip_rectangles): Use xassert instead of abort. Set n_clip_rects. Don't make clip_region empty when number of clipping rectangles is zero. (mac_reset_clip_rectangles): Set n_clip_rects directly instead of calling mac_set_clip_rectangles. (x_set_toolkit_scroll_bar_thumb): Temporarily hide scroll bar to avoid multiple redraws.
* (mac_draw_string_common): Remove arg MODE. New argYAMAMOTO Mitsuharu2006-02-211-145/+179
| | | | | | | | | | | | | | | | | BG_WIDTH. All uses changed. Draw background if BG_WIDTH is not zero. (mac_draw_image_string, mac_draw_image_string_16): New arg BG_WIDTH. [USE_CG_TEXT_DRAWING] (mac_draw_image_string_cg): Rename from mac_draw_string_cg. New arg BG_WIDTH. All uses changed. Draw background if BG_WIDTH is not zero. Use float constants as divisors instead of double. Use alloca instead of xmalloc/xfree. (x_draw_glyph_string_background, x_draw_glyph_string_foreground) [!MAC_OS8 || USE_ATSUI]: Background may be drawn using mac_draw_image_string* functions. (XLoadQueryFont) [MAC_OS8 && USE_ATSUI]: Don't adjust heights of some fonts when srcCopy text transfer mode might be used. (mac_begin_clip, mac_end_clip): Check if region is empty. (mac_set_clip_rectangles): When resetting clip region, make it empty instead of disposing of it.
* (mac_define_frame_cursor): Don't change pointer shapeYAMAMOTO Mitsuharu2006-02-101-9/+17
| | | | | | | | | | | for unfocused frame. (x_raise_frame): Call BringToFront instead of SelectWindow. (x_lower_frame): Use NULL instead of nil. (x_make_frame_visible): Don't call SelectWindow. (XTread_socket): Increment handling_signal at the start, decrement it at the end. [USE_CG_TEXT_DRAWING] (init_cg_text_anti_aliasing_threshold): Use CFPreferencesGetAppIntegerValue instead of Fmac_get_preference.
* Update years in copyright notice; nfc.Thien-Thi Nguyen2006-02-061-1/+1
|
* [USE_ATSUI] (atsu_get_text_layout_with_text_ptr)YAMAMOTO Mitsuharu2006-01-121-2/+5
| | | | | | [MAC_OS_X_VERSION_MAX_ALLOWED >= 1020]: Specify kATSLineUseQDRendering. (XLoadQueryFont) [USE_ATSUI]: Display diacritical marks in decomposed form.
* Don't include sys/param.h.YAMAMOTO Mitsuharu2005-12-241-19/+23
| | | | | | | | (init_coercion_handler): Add extern. [MAC_OS8] (main): Call init_coercion_handler. (mac_initialize) [MAC_OSX]: Likewise. [TARGET_API_MAC_CARBON] (mac_do_receive_drag): Use coercion of Apple event data for translation from/to file names.
* (mac_per_char_metric): Add prototype.YAMAMOTO Mitsuharu2005-12-221-256/+314
| | | | | | | | | | | | (x_per_char_metric) [USE_CG_TEXT_DRAWING]: Remove prototype. (mac_query_char_extents): New function. (x_per_char_metric): Use it. (XLoadQueryFont): Likewise. Consolidate min/max_bounds calculations. [USE_CG_TEXT_DRAWING] (mac_draw_string_cg): Use mac_per_char_metric instead of x_per_char_metric. (mac_text_extents_16): New function. (mac_compute_glyph_string_overhangs): Use it. (mac_unload_font): Free member `bounds' in struct MacFontStruct.
* (syms_of_macterm) <mac-allow-anti-aliasing>: Fix unintended defaultYAMAMOTO Mitsuharu2005-12-191-1/+1
| | | | value change.
* (mac_do_receive_drag): Drag-and-drop items are nowYAMAMOTO Mitsuharu2005-12-191-60/+71
| | | | | | | | | | | | | | | | | | | | | stored in member `args' of struct input_event. (x_use_underline_position_properties): Undo 2005-07-13 change. (syms_of_macterm) <x-use-underline-position-properties>: Likewise. (mac_use_core_graphics, mac_wheel_button_is_mouse_2) (mac_pass_command_to_system, mac_pass_control_to_system): New boolean variables renamed from Lisp_Object ones Vmac_use_core_graphics, Vmac_wheel_button_is_mouse_2, Vmac_pass_command_to_system, and Vmac_pass_control_to_system. All uses changed. (syms_of_macterm): DEFVAR_BOOL them. Remove previous DEFVAR_LISPs. Make them user options. (mac_handle_command_event, mac_store_services_event): Call create_apple_event_from_event_ref without 5th argument. (backtranslate_modified_keycode): Mask off modifier keys that are mapped to some Emacs modifiers before passing it to KeyTranslate. (syms_of_macterm): Make variables `mac-emulate-three-button-mouse', `mac-wheel-button-is-mouse-2', and `mac-*-modifier' user options. Fix docstrings of `mac-*-modifier'.
* (Qmac_ready_for_drag_n_drop, Qapplication, Qabout)YAMAMOTO Mitsuharu2005-12-101-397/+137
| | | | | | | | | | | | | | | | | | | | | | | (Qpreferences): Remove variables. (syms_of_macterm) : Don't initialize them. (Qhicommand) [USE_CARBON_EVENTS]: New variable. (syms_of_macterm) [USE_CARBON_EVENTS]: Initialize it. (init_required_apple_events, do_ae_open_application) (do_ae_print_documents, do_ae_open_documents) (do_ae_quit_application): Remove functions and prototypes. (mac_ready_for_apple_events, Qundefined, init_apple_event_handler) (mac_find_apple_event_spec): Add externs. (mac_store_application_menu_event): Remove function. (mac_store_apple_event, mac_make_lispy_event_code): New functions. (mac_handle_command_event): Create Apple event from Carbon event. Use mac_store_apple_event instead of mac_store_application_menu_event. [MAC_OSX] (mac_store_services_event): Likewise. (struct SelectionRange, SelectionRange): Remove struct and typedef. [MAC_OS8] (main): Call init_apple_event_handler instead of init_required_apple_events. (mac_initialize) [MAC_OSX]: Likewise. [!USE_CARBON_EVENTS] (mac_wait_next_event): Use mac_ready_for_apple_events instead of Qmac_ready_for_drag_n_drop.
* (Qcontrol): Rename from Qctrl. All uses changed.YAMAMOTO Mitsuharu2005-11-241-42/+42
| | | | | | | | | | (syms_of_macterm): Staticpro Qcontrol, Qmeta, Qalt, Qhyper, Qsuper, and Qmodifier_value. (Vmac_control_modifier, Vmac_option_modifier) (Vmac_command_modifier, Vmac_function_modifier) (Vmac_emulate_three_button_mouse, Vmac_wheel_button_is_mouse_2) (Vmac_pass_command_to_system, Vmac_pass_control_to_system) (Vmac_charset_info_alist): Doc fixes.
* [USE_CG_TEXT_DRAWING] (cg_text_anti_aliasing_threshold): New variable.YAMAMOTO Mitsuharu2005-11-191-0/+18
| | | | | | | [USE_CG_TEXT_DRAWING] (init_cg_text_anti_aliasing_threshold): New function. (init_font_name_table) [USE_ATSUI && USE_CG_TEXT_DRAWING]: Use it. [USE_CG_TEXT_DRAWING] (mac_draw_string_cg): Don't do antialiasing if font size is smaller than or equal to cg_text_anti_aliasing_threshold.
* [USE_CG_TEXT_DRAWING] (mac_draw_string_cg): New function.YAMAMOTO Mitsuharu2005-11-131-46/+206
| | | | | | | | | | | | (x_draw_glyph_string_foreground) [USE_CG_TEXT_DRAWING]: Use it. (XLoadQueryFont) [USE_CG_TEXT_DRAWING]: Set members cg_font and cg_glyphs in struct MacFontStruct if synthesized bold or italic is not used and font substitution never occurs for ASCII and Latin-1 characters. (XLoadQueryFont): Maximum and minimum metrics are now those among ASCII characters. (XLoadQueryFont) [!MAC_OS8 || USE_ATSUI]: Apply WebKit-style height adjustments for Courier, Helvetica, and Times.
* macterm.c (backtranslate_modified_keycode): New function toSteven Tamm2005-11-111-85/+226
| | | | | | | | | | | | mask modifiers off of keycodes for use in modifier mapping. (mac_determine_quit_char_modifiers): Remove mac-reverse-ctrl-meta and replace it with more flexible system mapping mac modifier keys to emacs modifier keys. (convert_fn_keycode): Map Fn-keys to their original keycode using a table (english keyboard only). (syms_of_macterm): Define mac-control-modifier, mac-command-modifier, mac-function-modifier. Define meta and ctrl for use as modifiers.
* (last_mouse_glyph_frame): New var.YAMAMOTO Mitsuharu2005-10-251-14/+34
| | | | | | | | | | | | | | | (note_mouse_movement): Say mouse moved if current frame differs from last_mouse_glyph_frame, and update last_mouse_glyph_frame. (XTmouse_position): Set last_mouse_glyph_frame. (XTread_socket): Clear last_mouse_glyph_frame on mouse up/down event. (mac_draw_string_common) [MAC_OSX && WORDS_BIG_ENDIAN]: Fix typo. Use EndianU16_BtoN. (mac_draw_string_common) [MAC_OSX]: Don't use ATSUClearLayoutControls. (x_per_char_metric, XLoadQueryFont) [MAC_OS_X_VERSION_MAX_ALLOWED < 1020]: Use device origins to get glyph bounds. (mac_to_x_fontname, mac_do_list_fonts) (mac_initialize_display_info): Change screen resolutions to 72dpi.
* (note_mouse_movement): Use PtInRect.YAMAMOTO Mitsuharu2005-10-181-11/+10
| | | | | | (XTread_socket): Also ignore mouse motion just before a button release event. Don't process button release event when mouse is not grabbed.
* (MAC_WINDOW_NORMAL_GC): Remove macro.YAMAMOTO Mitsuharu2005-10-161-466/+184
| | | | | | | | | | | | | | | | | | | (FRAME_NORMAL_GC): New macro. (mac_draw_line, mac_clear_area, mac_clear_window) (mac_fill_rectangle, mac_draw_string, mac_draw_string_16) (mac_draw_image_string, mac_draw_image_string_16): Rename from XDrawLine, XClearArea, XClearWindow, XFillRectangle, XDrawString, XDrawString16, XDrawImageString, and XDrawImageString16, respectively. All uses changed. (mac_draw_line, mac_erase_rectangle, mac_clear_area) (mac_clear_window, mac_draw_bitmap, mac_draw_rectangle) (mac_invert_rectangle, mac_draw_string_common, mac_draw_string) (mac_draw_string_16, mac_draw_image_string) (mac_draw_image_string_16, mac_copy_area, mac_copy_area_with_mask) (mac_scroll_area): Drawing functions now take frame as destination. All uses changed. (mac_draw_string_common): Get port height with FRAME_PIXEL_HEIGHT. (x_draw_fringe_bitmap): Set clipping area in face->gc.
* (note_mouse_movement, XTread_socket): Apply 2005-10-14 changes forYAMAMOTO Mitsuharu2005-10-141-8/+12
| | | | xterm.c.
* (note_mouse_movement): Undo last change.YAMAMOTO Mitsuharu2005-10-121-2/+0
|
* (note_mouse_movement): Restore help_echo_string if mouse is movedYAMAMOTO Mitsuharu2005-10-121-0/+2
| | | | inside last_mouse_glyph.
* (note_mouse_movement): Add call to remember_mouse_glyph.Kim F. Storm2005-10-111-132/+41
| | | | | | (glyph_rect, remember_mouse_glyph): Remove mac specific versions. (XTmouse_position): Adapt to use generic remember_mouse_glyph instead of pixel_to_glyph_coords.
* (PER_CHAR_METRIC): Remove unused macro.YAMAMOTO Mitsuharu2005-10-111-242/+254
| | | | | | | | | | | | | | | | | | | | | | (fm_font_family_alist): New variable. (syms_of_macterm): Initialize and staticpro it. (decode_mac_font_name): Replace '-' in family name with '_' if it occurs just once. Lower family name. (parse_x_font_name): Rename from x_font_name_to_mac_font_name. All uses changed. Remove argument MF and code conversion for it. Add argument SIZE. Rename argument MF_DECODED to FAMILY, and CS to CHARSET. Parse font size. Lower family name. Return integer value for status of parsing. (init_font_name_table) [USE_ATSUI]: Use decode_mac_font_name. Don't use Fdowncase because family name is already lowered by decode_mac_font_name. (init_font_name_table): Always call decode_mac_font_name. Add pair of family name and its reference to fm_font_family_alist. (mac_clear_font_name_table): Clear fm_font_family_alist. (XLoadQueryFont): Move font size parsing part to parse_x_font_name. Lookup fm_font_family_alist to get font family reference. (XLoadQueryFont) [USE_ATSUI]: Don't use Fdowncase because family name is already lowered by parse_x_font_name.