Lisp_Object posn;
Lisp_Object string_info = Qnil;
int row, column;
+ int wx, wy;
/* Ignore mouse events that were made on frame that
have been deleted. */
/* Set `window' to the window under frame pixel coordinates
event->x/event->y. */
window = window_from_coordinates (f, XINT (event->x),
- XINT (event->y), &part, 0);
+ XINT (event->y),
+ &part, &wx, &wy, 0);
if (!WINDOWP (window))
{
event->x/ event->y. */
struct window *w = XWINDOW (window);
- /* Get window relative coordinates. Original code
- `rounded' this to glyph boundaries. */
- int wx = FRAME_TO_WINDOW_PIXEL_X (w, XINT (event->x));
- int wy = FRAME_TO_WINDOW_PIXEL_Y (w, XINT (event->y));
-
/* Set event coordinates to window-relative coordinates
for constructing the Lisp event below. */
XSETINT (event->x, wx);
pixel_to_glyph_coords (f, XINT (event->x), XINT (event->y),
&column, &row, NULL, 1);
window = window_from_coordinates (f, XINT (event->x),
- XINT (event->y), &part, 0);
+ XINT (event->y),
+ &part, 0, 0, 0);
if (!WINDOWP (window))
{
else
{
int pixcolumn, pixrow;
- column -= XINT (XWINDOW (window)->left);
- row -= XINT (XWINDOW (window)->top);
+ column -= WINDOW_LEFT_EDGE_COL (XWINDOW (window));
+ row -= WINDOW_TOP_EDGE_LINE (XWINDOW (window));
glyph_to_pixel_coords (XWINDOW(window), column, row,
&pixcolumn, &pixrow);
XSETINT (event->x, pixcolumn);
Lisp_Object window;
Lisp_Object posn;
Lisp_Object files;
+ int wx, wy;
/* The frame_or_window field should be a cons of the frame in
which the event occurred and a list of the filenames
return Qnil;
window = window_from_coordinates (f, XINT (event->x),
- XINT (event->y), &part, 0);
+ XINT (event->y),
+ &part, &wx, &wy, 0);
if (!WINDOWP (window))
{
event->x/ event->y. */
struct window *w = XWINDOW (window);
- /* Get window relative coordinates. */
- int wx = FRAME_TO_WINDOW_PIXEL_X (w, XINT (event->x));
- int wy = FRAME_TO_WINDOW_PIXEL_Y (w, XINT (event->y));
-
/* Set event coordinates to window-relative coordinates
for constructing the Lisp event below. */
XSETINT (event->x, wx);
enum window_part area;
Lisp_Object window;
Lisp_Object posn;
+ int wx, wy;
if (frame)
/* It's in a frame; which window on that frame? */
- window = window_from_coordinates (frame, XINT (x), XINT (y), &area, 0);
+ window = window_from_coordinates (frame, XINT (x), XINT (y),
+ &area, &wx, &wy, 0);
else
window = Qnil;
if (WINDOWP (window))
{
struct window *w = XWINDOW (window);
- int wx, wy;
- /* Get window relative coordinates. */
- wx = FRAME_TO_WINDOW_PIXEL_X (w, XINT (x));
- wy = FRAME_TO_WINDOW_PIXEL_Y (w, XINT (y));
+ /* Set window relative coordinates. */
XSETINT (x, wx);
XSETINT (y, wy);
register Lisp_Object name;
int nlength;
/* FIXME: Use the minibuffer's frame width. */
- int width = FRAME_WIDTH (SELECTED_FRAME ()) - 4;
+ int width = FRAME_COLS (SELECTED_FRAME ()) - 4;
int idx = -1;
int nobindings = 1;
Lisp_Object rest, vector;