diff options
| author | Joakim Verona | 2010-08-20 22:00:00 +0200 |
|---|---|---|
| committer | Joakim Verona | 2010-08-20 22:00:00 +0200 |
| commit | 38f9163d622c5024a75775ce1a2fc9e99e4bd9cb (patch) | |
| tree | d7ae74d47cd743840f6e6c79b850bc6c1a4b1081 /src | |
| parent | ccd806186417c006a97ac89162d2af3acb3d3047 (diff) | |
| parent | ff2de6d2bb239c5fdcfaba2c8efd5c62610e3b7d (diff) | |
| download | emacs-38f9163d622c5024a75775ce1a2fc9e99e4bd9cb.tar.gz emacs-38f9163d622c5024a75775ce1a2fc9e99e4bd9cb.zip | |
merge from upstream
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 29 | ||||
| -rw-r--r-- | src/cmds.c | 41 | ||||
| -rw-r--r-- | src/dispnew.c | 37 | ||||
| -rw-r--r-- | src/emacs.c | 2 | ||||
| -rw-r--r-- | src/image.c | 9 | ||||
| -rw-r--r-- | src/w32fns.c | 7 | ||||
| -rw-r--r-- | src/w32menu.c | 6 | ||||
| -rw-r--r-- | src/xdisp.c | 21 |
8 files changed, 102 insertions, 50 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 5d26db96634..5b44cc8f34c 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,32 @@ | |||
| 1 | 2010-08-20 Eli Zaretskii <eliz@gnu.org> | ||
| 2 | |||
| 3 | * emacs.c <emacs_version>: Add a comment regarding | ||
| 4 | msdos/mainmake.v2's dependency on the syntax of this declaration. | ||
| 5 | |||
| 6 | 2010-08-20 Eli Zaretskii <eliz@gnu.org> | ||
| 7 | |||
| 8 | * dispnew.c (buffer_posn_from_coords): Fix calculation of buffer | ||
| 9 | position for R2L lines by mirroring the pixel position wrt the | ||
| 10 | text are box. Improve commentary. | ||
| 11 | |||
| 12 | 2010-08-20 Andreas Schwab <schwab@linux-m68k.org> | ||
| 13 | |||
| 14 | * image.c (imagemagick_clear_image): Remove debugging output. | ||
| 15 | |||
| 16 | 2010-08-19 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 17 | |||
| 18 | * cmds.c (Vself_insert_face, Vself_insert_face_command): Remove. | ||
| 19 | (Qpost_self_insert_hook, Vpost_self_insert_hook): New vars. | ||
| 20 | (internal_self_insert): Run Qpost_self_insert_hook rather than handle | ||
| 21 | self-insert-face. | ||
| 22 | (syms_of_cmds): Initialize the new vars. | ||
| 23 | |||
| 24 | 2010-08-19 Jason Rumney <jasonr@gnu.org> | ||
| 25 | |||
| 26 | * w32menu.c (set_frame_menubar): Remove call to undefined function. | ||
| 27 | |||
| 28 | * w32fns.c (w32_wnd_proc): Don't check context before initializing. | ||
| 29 | |||
| 1 | 2010-08-19 Jan Djärv <jan.h.d@swipnet.se> | 30 | 2010-08-19 Jan Djärv <jan.h.d@swipnet.se> |
| 2 | 31 | ||
| 3 | * nsselect.m (nxatoms_of_nsselect): Use "Selection" and "Secondary". | 32 | * nsselect.m (nxatoms_of_nsselect): Use "Selection" and "Secondary". |
diff --git a/src/cmds.c b/src/cmds.c index 4cb6ca199e7..f306ede7ca5 100644 --- a/src/cmds.c +++ b/src/cmds.c | |||
| @@ -37,12 +37,6 @@ Lisp_Object Qkill_forward_chars, Qkill_backward_chars, Vblink_paren_function; | |||
| 37 | /* A possible value for a buffer's overwrite-mode variable. */ | 37 | /* A possible value for a buffer's overwrite-mode variable. */ |
| 38 | Lisp_Object Qoverwrite_mode_binary; | 38 | Lisp_Object Qoverwrite_mode_binary; |
| 39 | 39 | ||
| 40 | /* Non-nil means put this face on the next self-inserting character. */ | ||
| 41 | Lisp_Object Vself_insert_face; | ||
| 42 | |||
| 43 | /* This is the command that set up Vself_insert_face. */ | ||
| 44 | Lisp_Object Vself_insert_face_command; | ||
| 45 | |||
| 46 | static int internal_self_insert (int, int); | 40 | static int internal_self_insert (int, int); |
| 47 | 41 | ||
| 48 | DEFUN ("forward-point", Fforward_point, Sforward_point, 1, 1, 0, | 42 | DEFUN ("forward-point", Fforward_point, Sforward_point, 1, 1, 0, |
| @@ -346,6 +340,7 @@ After insertion, the value of `auto-fill-function' is called if the | |||
| 346 | A value of 2 means this did things that call for an undo boundary. */ | 340 | A value of 2 means this did things that call for an undo boundary. */ |
| 347 | 341 | ||
| 348 | static Lisp_Object Qexpand_abbrev; | 342 | static Lisp_Object Qexpand_abbrev; |
| 343 | static Lisp_Object Qpost_self_insert_hook, Vpost_self_insert_hook; | ||
| 349 | 344 | ||
| 350 | static int | 345 | static int |
| 351 | internal_self_insert (int c, int noautofill) | 346 | internal_self_insert (int c, int noautofill) |
| @@ -451,10 +446,10 @@ internal_self_insert (int c, int noautofill) | |||
| 451 | && synt != Sword | 446 | && synt != Sword |
| 452 | && NILP (current_buffer->read_only) | 447 | && NILP (current_buffer->read_only) |
| 453 | && PT > BEGV | 448 | && PT > BEGV |
| 454 | && (!NILP (current_buffer->enable_multibyte_characters) | 449 | && (SYNTAX (!NILP (current_buffer->enable_multibyte_characters) |
| 455 | ? SYNTAX (XFASTINT (Fprevious_char ())) == Sword | 450 | ? XFASTINT (Fprevious_char ()) |
| 456 | : (SYNTAX (UNIBYTE_TO_CHAR (XFASTINT (Fprevious_char ()))) | 451 | : UNIBYTE_TO_CHAR (XFASTINT (Fprevious_char ()))) |
| 457 | == Sword))) | 452 | == Sword)) |
| 458 | { | 453 | { |
| 459 | int modiff = MODIFF; | 454 | int modiff = MODIFF; |
| 460 | Lisp_Object sym; | 455 | Lisp_Object sym; |
| @@ -514,15 +509,6 @@ internal_self_insert (int c, int noautofill) | |||
| 514 | hairy = 2; | 509 | hairy = 2; |
| 515 | } | 510 | } |
| 516 | 511 | ||
| 517 | /* If previous command specified a face to use, use it. */ | ||
| 518 | if (!NILP (Vself_insert_face) | ||
| 519 | && EQ (current_kboard->Vlast_command, Vself_insert_face_command)) | ||
| 520 | { | ||
| 521 | Fput_text_property (make_number (PT - 1), make_number (PT), | ||
| 522 | Qface, Vself_insert_face, Qnil); | ||
| 523 | Vself_insert_face = Qnil; | ||
| 524 | } | ||
| 525 | |||
| 526 | if ((synt == Sclose || synt == Smath) | 512 | if ((synt == Sclose || synt == Smath) |
| 527 | && !NILP (Vblink_paren_function) && INTERACTIVE | 513 | && !NILP (Vblink_paren_function) && INTERACTIVE |
| 528 | && !noautofill) | 514 | && !noautofill) |
| @@ -530,6 +516,9 @@ internal_self_insert (int c, int noautofill) | |||
| 530 | call0 (Vblink_paren_function); | 516 | call0 (Vblink_paren_function); |
| 531 | hairy = 2; | 517 | hairy = 2; |
| 532 | } | 518 | } |
| 519 | /* Run hooks for electric keys. */ | ||
| 520 | call1 (Vrun_hooks, Qpost_self_insert_hook); | ||
| 521 | |||
| 533 | return hairy; | 522 | return hairy; |
| 534 | } | 523 | } |
| 535 | 524 | ||
| @@ -550,15 +539,13 @@ syms_of_cmds (void) | |||
| 550 | Qexpand_abbrev = intern_c_string ("expand-abbrev"); | 539 | Qexpand_abbrev = intern_c_string ("expand-abbrev"); |
| 551 | staticpro (&Qexpand_abbrev); | 540 | staticpro (&Qexpand_abbrev); |
| 552 | 541 | ||
| 553 | DEFVAR_LISP ("self-insert-face", &Vself_insert_face, | 542 | Qpost_self_insert_hook = intern_c_string ("post-self-insert-hook"); |
| 554 | doc: /* If non-nil, set the face of the next self-inserting character to this. | 543 | staticpro (&Qpost_self_insert_hook); |
| 555 | See also `self-insert-face-command'. */); | ||
| 556 | Vself_insert_face = Qnil; | ||
| 557 | 544 | ||
| 558 | DEFVAR_LISP ("self-insert-face-command", &Vself_insert_face_command, | 545 | DEFVAR_LISP ("post-self-insert-hook", &Vpost_self_insert_hook, |
| 559 | doc: /* This is the command that set up `self-insert-face'. | 546 | doc: /* Hook run at the end of `self-insert-command'. |
| 560 | If `last-command' does not equal this value, we ignore `self-insert-face'. */); | 547 | This run is run after inserting the charater. */); |
| 561 | Vself_insert_face_command = Qnil; | 548 | Vpost_self_insert_hook = Qnil; |
| 562 | 549 | ||
| 563 | DEFVAR_LISP ("blink-paren-function", &Vblink_paren_function, | 550 | DEFVAR_LISP ("blink-paren-function", &Vblink_paren_function, |
| 564 | doc: /* Function called, if non-nil, whenever a close parenthesis is inserted. | 551 | doc: /* Function called, if non-nil, whenever a close parenthesis is inserted. |
diff --git a/src/dispnew.c b/src/dispnew.c index 35893872c73..efcfd101782 100644 --- a/src/dispnew.c +++ b/src/dispnew.c | |||
| @@ -5351,9 +5351,15 @@ update_frame_line (struct frame *f, int vpos) | |||
| 5351 | ***********************************************************************/ | 5351 | ***********************************************************************/ |
| 5352 | 5352 | ||
| 5353 | /* Determine what's under window-relative pixel position (*X, *Y). | 5353 | /* Determine what's under window-relative pixel position (*X, *Y). |
| 5354 | Return the object (string or buffer) that's there. | 5354 | Return the OBJECT (string or buffer) that's there. |
| 5355 | Return in *POS the position in that object. | 5355 | Return in *POS the position in that object. |
| 5356 | Adjust *X and *Y to character positions. */ | 5356 | Adjust *X and *Y to character positions. |
| 5357 | Return in *DX and *DY the pixel coordinates of the click, | ||
| 5358 | relative to the top left corner of OBJECT, or relative to | ||
| 5359 | the top left corner of the character glyph at (*X, *Y) | ||
| 5360 | if OBJECT is nil. | ||
| 5361 | Return WIDTH and HEIGHT of the object at (*X, *Y), or zero | ||
| 5362 | if the coordinates point to an empty area of the display. */ | ||
| 5357 | 5363 | ||
| 5358 | Lisp_Object | 5364 | Lisp_Object |
| 5359 | buffer_posn_from_coords (struct window *w, int *x, int *y, struct display_pos *pos, Lisp_Object *object, int *dx, int *dy, int *width, int *height) | 5365 | buffer_posn_from_coords (struct window *w, int *x, int *y, struct display_pos *pos, Lisp_Object *object, int *dx, int *dy, int *width, int *height) |
| @@ -5366,7 +5372,7 @@ buffer_posn_from_coords (struct window *w, int *x, int *y, struct display_pos *p | |||
| 5366 | #ifdef HAVE_WINDOW_SYSTEM | 5372 | #ifdef HAVE_WINDOW_SYSTEM |
| 5367 | struct image *img = 0; | 5373 | struct image *img = 0; |
| 5368 | #endif | 5374 | #endif |
| 5369 | int x0, x1; | 5375 | int x0, x1, to_x; |
| 5370 | 5376 | ||
| 5371 | /* We used to set current_buffer directly here, but that does the | 5377 | /* We used to set current_buffer directly here, but that does the |
| 5372 | wrong thing with `face-remapping-alist' (bug#2044). */ | 5378 | wrong thing with `face-remapping-alist' (bug#2044). */ |
| @@ -5377,8 +5383,29 @@ buffer_posn_from_coords (struct window *w, int *x, int *y, struct display_pos *p | |||
| 5377 | start_display (&it, w, startp); | 5383 | start_display (&it, w, startp); |
| 5378 | 5384 | ||
| 5379 | x0 = *x - WINDOW_LEFT_MARGIN_WIDTH (w); | 5385 | x0 = *x - WINDOW_LEFT_MARGIN_WIDTH (w); |
| 5380 | move_it_to (&it, -1, x0 + it.first_visible_x, *y, -1, | 5386 | |
| 5381 | MOVE_TO_X | MOVE_TO_Y); | 5387 | /* First, move to the beginning of the row corresponding to *Y. We |
| 5388 | need to be in that row to get the correct value of base paragraph | ||
| 5389 | direction for the paragraph at *X. */ | ||
| 5390 | move_it_to (&it, -1, 0, *y, -1, MOVE_TO_X | MOVE_TO_Y); | ||
| 5391 | |||
| 5392 | /* TO_X is the pixel position that the iterator will compute for the | ||
| 5393 | glyph at *X. This is because iterator positions are not offset | ||
| 5394 | due to hscroll. */ | ||
| 5395 | to_x = x0 + it.first_visible_x; | ||
| 5396 | if (it.bidi_it.paragraph_dir == R2L) | ||
| 5397 | /* For lines in an R2L paragraph, we need to mirror TO_X wrt the | ||
| 5398 | text area. This is because the iterator, even in R2L | ||
| 5399 | paragraphs, delivers glyphs as if they started at the left | ||
| 5400 | margin of the window. (When we actually produce glyphs for | ||
| 5401 | display, we reverse their order in PRODUCE_GLYPHS, but the | ||
| 5402 | iterator doesn't know about that.) The following line adjusts | ||
| 5403 | the pixel position to the iterator geometry, which is what | ||
| 5404 | move_it_* routines use. */ | ||
| 5405 | to_x = window_box_width (w, TEXT_AREA) - to_x; | ||
| 5406 | |||
| 5407 | /* Now move horizontally in the row to the glyph under *X. */ | ||
| 5408 | move_it_in_display_line (&it, ZV, to_x, MOVE_TO_X); | ||
| 5382 | 5409 | ||
| 5383 | Fset_buffer (old_current_buffer); | 5410 | Fset_buffer (old_current_buffer); |
| 5384 | 5411 | ||
diff --git a/src/emacs.c b/src/emacs.c index 026a210af50..67a99d674e7 100644 --- a/src/emacs.c +++ b/src/emacs.c | |||
| @@ -91,6 +91,8 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ | |||
| 91 | #endif | 91 | #endif |
| 92 | #endif | 92 | #endif |
| 93 | 93 | ||
| 94 | /* If you change the following line, remember to update | ||
| 95 | msdos/mainmake.v2 which gleans the Emacs version from it! */ | ||
| 94 | static const char emacs_copyright[] = "Copyright (C) 2010 Free Software Foundation, Inc."; | 96 | static const char emacs_copyright[] = "Copyright (C) 2010 Free Software Foundation, Inc."; |
| 95 | static const char emacs_version[] = "24.0.50"; | 97 | static const char emacs_version[] = "24.0.50"; |
| 96 | 98 | ||
diff --git a/src/image.c b/src/image.c index e2aeae3f357..ae4bf2fd937 100644 --- a/src/image.c +++ b/src/image.c | |||
| @@ -7400,7 +7400,6 @@ static void | |||
| 7400 | imagemagick_clear_image (struct frame *f, | 7400 | imagemagick_clear_image (struct frame *f, |
| 7401 | struct image *img) | 7401 | struct image *img) |
| 7402 | { | 7402 | { |
| 7403 | printf("clearing imagemagick image\n"); | ||
| 7404 | x_clear_image (f, img); | 7403 | x_clear_image (f, img); |
| 7405 | } | 7404 | } |
| 7406 | 7405 | ||
| @@ -7485,7 +7484,6 @@ imagemagick_load_image (/* Pointer to emacs frame structure. */ | |||
| 7485 | image. Interface :index is same as for GIF. First we "ping" the | 7484 | image. Interface :index is same as for GIF. First we "ping" the |
| 7486 | image to see how many sub-images it contains. Pinging is faster | 7485 | image to see how many sub-images it contains. Pinging is faster |
| 7487 | than loading the image to find out things about it. */ | 7486 | than loading the image to find out things about it. */ |
| 7488 | printf("im ping file %s\n", filename); | ||
| 7489 | image = image_spec_value (img->spec, QCindex, NULL); | 7487 | image = image_spec_value (img->spec, QCindex, NULL); |
| 7490 | ino = INTEGERP (image) ? XFASTINT (image) : 0; | 7488 | ino = INTEGERP (image) ? XFASTINT (image) : 0; |
| 7491 | ping_wand=NewMagickWand(); | 7489 | ping_wand=NewMagickWand(); |
| @@ -7519,7 +7517,6 @@ imagemagick_load_image (/* Pointer to emacs frame structure. */ | |||
| 7519 | 7517 | ||
| 7520 | if (filename != NULL) | 7518 | if (filename != NULL) |
| 7521 | { | 7519 | { |
| 7522 | printf("im read file %s\n", filename); | ||
| 7523 | image_info=CloneImageInfo((ImageInfo *) NULL); | 7520 | image_info=CloneImageInfo((ImageInfo *) NULL); |
| 7524 | (void) strcpy(image_info->filename, filename); | 7521 | (void) strcpy(image_info->filename, filename); |
| 7525 | image_info -> number_scenes = 1; | 7522 | image_info -> number_scenes = 1; |
| @@ -7529,7 +7526,6 @@ imagemagick_load_image (/* Pointer to emacs frame structure. */ | |||
| 7529 | im_image = ReadImage (image_info, exception); | 7526 | im_image = ReadImage (image_info, exception); |
| 7530 | CatchException(exception); | 7527 | CatchException(exception); |
| 7531 | 7528 | ||
| 7532 | printf("im wand from image\n"); | ||
| 7533 | image_wand = NewMagickWandFromImage(im_image); | 7529 | image_wand = NewMagickWandFromImage(im_image); |
| 7534 | } | 7530 | } |
| 7535 | else | 7531 | else |
| @@ -7565,7 +7561,6 @@ imagemagick_load_image (/* Pointer to emacs frame structure. */ | |||
| 7565 | } | 7561 | } |
| 7566 | if(desired_width != -1 && desired_height != -1) | 7562 | if(desired_width != -1 && desired_height != -1) |
| 7567 | { | 7563 | { |
| 7568 | printf("MagickScaleImage %d %d\n", desired_width, desired_height); | ||
| 7569 | status = MagickScaleImage(image_wand, desired_width, desired_height); | 7564 | status = MagickScaleImage(image_wand, desired_width, desired_height); |
| 7570 | if (status == MagickFalse) { | 7565 | if (status == MagickFalse) { |
| 7571 | image_error ("Imagemagick scale failed", Qnil, Qnil); | 7566 | image_error ("Imagemagick scale failed", Qnil, Qnil); |
| @@ -7592,7 +7587,6 @@ imagemagick_load_image (/* Pointer to emacs frame structure. */ | |||
| 7592 | h=XFASTINT(XCAR(XCDR(crop))); | 7587 | h=XFASTINT(XCAR(XCDR(crop))); |
| 7593 | x=XFASTINT(XCAR(XCDR(XCDR(crop)))); | 7588 | x=XFASTINT(XCAR(XCDR(XCDR(crop)))); |
| 7594 | y=XFASTINT(XCAR(XCDR(XCDR(XCDR(crop))))); | 7589 | y=XFASTINT(XCAR(XCDR(XCDR(XCDR(crop))))); |
| 7595 | printf("MagickCropImage(image_wand, %d,%d, %d,%d)\n", w, h, x, y); | ||
| 7596 | MagickCropImage(image_wand, w,h, x,y); | 7590 | MagickCropImage(image_wand, w,h, x,y); |
| 7597 | } | 7591 | } |
| 7598 | 7592 | ||
| @@ -7609,7 +7603,6 @@ imagemagick_load_image (/* Pointer to emacs frame structure. */ | |||
| 7609 | PixelSetColor (background, "#ffffff");/*TODO remove hardcode*/ | 7603 | PixelSetColor (background, "#ffffff");/*TODO remove hardcode*/ |
| 7610 | 7604 | ||
| 7611 | rotation = extract_float (value); | 7605 | rotation = extract_float (value); |
| 7612 | printf ("MagickRotateImage %f\n", rotation); | ||
| 7613 | 7606 | ||
| 7614 | status = MagickRotateImage (image_wand, background, rotation); | 7607 | status = MagickRotateImage (image_wand, background, rotation); |
| 7615 | DestroyPixelWand (background); | 7608 | DestroyPixelWand (background); |
| @@ -7691,7 +7684,6 @@ imagemagick_load_image (/* Pointer to emacs frame structure. */ | |||
| 7691 | int imagedepth = 24;/*MagickGetImageDepth(image_wand);*/ | 7684 | int imagedepth = 24;/*MagickGetImageDepth(image_wand);*/ |
| 7692 | char* exportdepth = imagedepth <= 8 ? "I" : "BGRP";/*"RGBP";*/ | 7685 | char* exportdepth = imagedepth <= 8 ? "I" : "BGRP";/*"RGBP";*/ |
| 7693 | /* Try to create a x pixmap to hold the imagemagick pixmap. */ | 7686 | /* Try to create a x pixmap to hold the imagemagick pixmap. */ |
| 7694 | printf("imagedepth:%d exportdepth:%s\n", imagedepth, exportdepth); | ||
| 7695 | if (!x_create_x_image_and_pixmap (f, width, height, imagedepth, | 7687 | if (!x_create_x_image_and_pixmap (f, width, height, imagedepth, |
| 7696 | &ximg, &img->pixmap)){ | 7688 | &ximg, &img->pixmap)){ |
| 7697 | image_error("Imagemagick X bitmap allocation failure", Qnil, Qnil); | 7689 | image_error("Imagemagick X bitmap allocation failure", Qnil, Qnil); |
| @@ -7758,7 +7750,6 @@ imagemagick_load_image (/* Pointer to emacs frame structure. */ | |||
| 7758 | imagemagick_error: | 7750 | imagemagick_error: |
| 7759 | /* TODO more cleanup. */ | 7751 | /* TODO more cleanup. */ |
| 7760 | image_error ("Error parsing IMAGEMAGICK image `%s'", img->spec, Qnil); | 7752 | image_error ("Error parsing IMAGEMAGICK image `%s'", img->spec, Qnil); |
| 7761 | printf("Imagemagick error, see *Messages*\n"); | ||
| 7762 | return 0; | 7753 | return 0; |
| 7763 | } | 7754 | } |
| 7764 | 7755 | ||
diff --git a/src/w32fns.c b/src/w32fns.c index 64d0d8cb6d1..f91ad948828 100644 --- a/src/w32fns.c +++ b/src/w32fns.c | |||
| @@ -3109,9 +3109,6 @@ w32_wnd_proc (HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) | |||
| 3109 | HIMC context; | 3109 | HIMC context; |
| 3110 | struct window *w; | 3110 | struct window *w; |
| 3111 | 3111 | ||
| 3112 | if (!context) | ||
| 3113 | break; | ||
| 3114 | |||
| 3115 | f = x_window_to_frame (dpyinfo, hwnd); | 3112 | f = x_window_to_frame (dpyinfo, hwnd); |
| 3116 | w = XWINDOW (FRAME_SELECTED_WINDOW (f)); | 3113 | w = XWINDOW (FRAME_SELECTED_WINDOW (f)); |
| 3117 | 3114 | ||
| @@ -3129,6 +3126,10 @@ w32_wnd_proc (HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) | |||
| 3129 | - WINDOW_MODE_LINE_HEIGHT (w)); | 3126 | - WINDOW_MODE_LINE_HEIGHT (w)); |
| 3130 | 3127 | ||
| 3131 | context = get_ime_context_fn (hwnd); | 3128 | context = get_ime_context_fn (hwnd); |
| 3129 | |||
| 3130 | if (!context) | ||
| 3131 | break; | ||
| 3132 | |||
| 3132 | set_ime_composition_window_fn (context, &form); | 3133 | set_ime_composition_window_fn (context, &form); |
| 3133 | release_ime_context_fn (hwnd, context); | 3134 | release_ime_context_fn (hwnd, context); |
| 3134 | } | 3135 | } |
diff --git a/src/w32menu.c b/src/w32menu.c index 1146843bec8..0ed9bffe70c 100644 --- a/src/w32menu.c +++ b/src/w32menu.c | |||
| @@ -420,12 +420,8 @@ set_frame_menubar (FRAME_PTR f, int first_time, int deep_p) | |||
| 420 | 420 | ||
| 421 | set_buffer_internal_1 (XBUFFER (buffer)); | 421 | set_buffer_internal_1 (XBUFFER (buffer)); |
| 422 | 422 | ||
| 423 | /* Run the Lucid hook. */ | 423 | /* Run the hooks. */ |
| 424 | safe_run_hooks (Qactivate_menubar_hook); | 424 | safe_run_hooks (Qactivate_menubar_hook); |
| 425 | /* If it has changed current-menubar from previous value, | ||
| 426 | really recompute the menubar from the value. */ | ||
| 427 | if (! NILP (Vlucid_menu_bar_dirty_flag)) | ||
| 428 | call0 (Qrecompute_lucid_menubar); | ||
| 429 | safe_run_hooks (Qmenu_bar_update_hook); | 425 | safe_run_hooks (Qmenu_bar_update_hook); |
| 430 | FRAME_MENU_BAR_ITEMS (f) = menu_bar_items (FRAME_MENU_BAR_ITEMS (f)); | 426 | FRAME_MENU_BAR_ITEMS (f) = menu_bar_items (FRAME_MENU_BAR_ITEMS (f)); |
| 431 | 427 | ||
diff --git a/src/xdisp.c b/src/xdisp.c index d730387a51b..c80e1f35df3 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -217,7 +217,26 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ | |||
| 217 | glyph with suitably computed width. Both the blanks and the | 217 | glyph with suitably computed width. Both the blanks and the |
| 218 | stretch glyph are given the face of the background of the line. | 218 | stretch glyph are given the face of the background of the line. |
| 219 | This way, the terminal-specific back-end can still draw the glyphs | 219 | This way, the terminal-specific back-end can still draw the glyphs |
| 220 | left to right, even for R2L lines. */ | 220 | left to right, even for R2L lines. |
| 221 | |||
| 222 | Note one important detail mentioned above: that the bidi reordering | ||
| 223 | engine, driven by the iterator, produces characters in R2L rows | ||
| 224 | starting at the character that will be the rightmost on display. | ||
| 225 | As far as the iterator is concerned, the geometry of such rows is | ||
| 226 | still left to right, i.e. the iterator "thinks" the first character | ||
| 227 | is at the leftmost pixel position. The iterator does not know that | ||
| 228 | PRODUCE_GLYPHS reverses the order of the glyphs that the iterator | ||
| 229 | delivers. This is important when functions from the the move_it_* | ||
| 230 | family are used to get to certain screen position or to match | ||
| 231 | screen coordinates with buffer coordinates: these functions use the | ||
| 232 | iterator geometry, which is left to right even in R2L paragraphs. | ||
| 233 | This works well with most callers of move_it_*, because they need | ||
| 234 | to get to a specific column, and columns are still numbered in the | ||
| 235 | reading order, i.e. the rightmost character in a R2L paragraph is | ||
| 236 | still column zero. But some callers do not get well with this; a | ||
| 237 | notable example is mouse clicks that need to find the character | ||
| 238 | that corresponds to certain pixel coordinates. See | ||
| 239 | buffer_posn_from_coords in dispnew.c for how this is handled. */ | ||
| 221 | 240 | ||
| 222 | #include <config.h> | 241 | #include <config.h> |
| 223 | #include <stdio.h> | 242 | #include <stdio.h> |