if (first_unused >= f->width)
first_unused = f->width;
+ first_unused += FRAME_LEFT_SCROLL_BAR_WIDTH (f);
+
BLOCK_INPUT;
do_line_dance ();
abort ();
ht = f->height;
- intborder = f->output_data.x->internal_border_width;
+ intborder = CHAR_TO_PIXEL_COL (f, FRAME_LEFT_SCROLL_BAR_WIDTH (f));
x_update_cursor (updating_frame, 0);
left = 0;
if (top < 0)
top = 0;
- if (right > f->width)
- right = f->width;
+ if (right > FRAME_WINDOW_WIDTH (f))
+ right = FRAME_WINDOW_WIDTH (f);
if (bottom > f->height)
bottom = f->height;
FRAME_PTR f = XFRAME (WINDOW_FRAME (w));
int i;
int row = 0;
- int left = w->left;
+ int left = WINDOW_LEFT_MARGIN (w);
int top = w->top;
int height = XFASTINT (w->height) - ! MINI_WINDOW_P (w);
int width = window_internal_width (w);
{
int column = (i == FRAME_X_DISPLAY_INFO (f)->mouse_face_beg_row
? FRAME_X_DISPLAY_INFO (f)->mouse_face_beg_col
- : w->left);
+ : WINDOW_LEFT_MARGIN (w));
int endcolumn = (i == FRAME_X_DISPLAY_INFO (f)->mouse_face_end_row
? FRAME_X_DISPLAY_INFO (f)->mouse_face_end_col
- : w->left + width);
+ : WINDOW_LEFT_MARGIN (w) + width);
endcolumn = min (endcolumn, FRAME_CURRENT_GLYPHS (f)->used[i]);
/* If the cursor's in the text we are about to rewrite,
BLOCK_INPUT;
{
- int inside_width = VERTICAL_SCROLL_BAR_INSIDE_WIDTH (XINT (bar->width));
- int inside_height = VERTICAL_SCROLL_BAR_INSIDE_HEIGHT (XINT (bar->height));
- int top_range = VERTICAL_SCROLL_BAR_TOP_RANGE (XINT (bar->height));
+ int inside_width = VERTICAL_SCROLL_BAR_INSIDE_WIDTH (f, XINT (bar->width));
+ int inside_height = VERTICAL_SCROLL_BAR_INSIDE_HEIGHT (f, XINT (bar->height));
+ int top_range = VERTICAL_SCROLL_BAR_TOP_RANGE (f, XINT (bar->height));
/* Make sure the values are reasonable, and try to preserve
the distance between start and end. */
dragged. */
if (NILP (bar->dragging))
{
- int top_range = VERTICAL_SCROLL_BAR_TOP_RANGE (pixel_height);
+ int top_range = VERTICAL_SCROLL_BAR_TOP_RANGE (f, pixel_height);
if (whole == 0)
x_scroll_bar_set_handle (bar, 0, top_range, 0);
Window w = SCROLL_BAR_X_WINDOW (bar);
FRAME_PTR f = XFRAME (WINDOW_FRAME (XWINDOW (bar->window)));
GC gc = f->output_data.x->normal_gc;
+ int width_trim = (FRAME_HAS_VERTICAL_SCROLL_BARS_ON_LEFT (f)
+ ? LEFT_VERTICAL_SCROLL_BAR_WIDTH_TRIM
+ : 0);
BLOCK_INPUT;
XDrawRectangle (FRAME_X_DISPLAY (f), w, gc,
/* x, y, width, height */
- 0, 0, XINT (bar->width) - 1, XINT (bar->height) - 1);
-
+ 0, 0,
+ XINT (bar->width) - 1 - width_trim,
+ XINT (bar->height) - 1);
+
UNBLOCK_INPUT;
}
emacs_event->frame_or_window = bar->window;
emacs_event->timestamp = event->xbutton.time;
{
+ FRAME_PTR f = XFRAME (WINDOW_FRAME (XWINDOW (bar->window)));
int internal_height
- = VERTICAL_SCROLL_BAR_INSIDE_HEIGHT (XINT (bar->height));
+ = VERTICAL_SCROLL_BAR_INSIDE_HEIGHT (f, XINT (bar->height));
int top_range
- = VERTICAL_SCROLL_BAR_TOP_RANGE (XINT (bar->height));
+ = VERTICAL_SCROLL_BAR_TOP_RANGE (f, XINT (bar->height));
int y = event->xbutton.y - VERTICAL_SCROLL_BAR_TOP_BORDER;
if (y < 0) y = 0;
else
{
int inside_height
- = VERTICAL_SCROLL_BAR_INSIDE_HEIGHT (XINT (bar->height));
+ = VERTICAL_SCROLL_BAR_INSIDE_HEIGHT (f, XINT (bar->height));
int top_range
- = VERTICAL_SCROLL_BAR_TOP_RANGE (XINT (bar->height));
+ = VERTICAL_SCROLL_BAR_TOP_RANGE (f, XINT (bar->height));
win_y -= VERTICAL_SCROLL_BAR_TOP_BORDER;