Commit ffcd5669 authored by Martin Rudalics's avatar Martin Rudalics

In x_new_font don't calculate non-toolkit scrollbar width from font width (Bug#17163).

* xterm.c (x_new_font): Don't calculate non-toolkit scrollbar
width from font width (Bug#17163).
parent 0b908bf2
2014-04-02 Martin Rudalics <rudalics@gmx.at>
* xterm.c (x_new_font): Don't calculate non-toolkit scrollbar
width from font width (Bug#17163).
2014-03-30 Martin Rudalics <rudalics@gmx.at>
* frame.c (x_set_frame_parameters): Calculate default values of
......
......@@ -7778,20 +7778,16 @@ x_new_font (struct frame *f, Lisp_Object font_object, int fontset)
compute_fringe_widths (f, 1);
/* Compute character columns occupied by scrollbar.
Don't do things differently for non-toolkit scrollbars
(Bug#17163). */
unit = FRAME_COLUMN_WIDTH (f);
#ifdef USE_TOOLKIT_SCROLL_BARS
/* The width of a toolkit scrollbar does not change with the new
font but we have to calculate the number of columns it occupies
anew. */
FRAME_CONFIG_SCROLL_BAR_COLS (f)
= (FRAME_CONFIG_SCROLL_BAR_WIDTH (f) + unit - 1) / unit;
#else
/* The width of a non-toolkit scrollbar is at least 14 pixels and a
multiple of the frame's character width. */
FRAME_CONFIG_SCROLL_BAR_COLS (f) = (14 + unit - 1) / unit;
FRAME_CONFIG_SCROLL_BAR_WIDTH (f)
= FRAME_CONFIG_SCROLL_BAR_COLS (f) * unit;
#endif
if (FRAME_CONFIG_SCROLL_BAR_WIDTH (f) > 0)
FRAME_CONFIG_SCROLL_BAR_COLS (f)
= (FRAME_CONFIG_SCROLL_BAR_WIDTH (f) + unit - 1) / unit;
else
FRAME_CONFIG_SCROLL_BAR_COLS (f) = (14 + unit - 1) / unit;
if (FRAME_X_WINDOW (f) != 0)
{
......@@ -7997,7 +7993,7 @@ xim_close_dpy (struct x_display_info *dpyinfo)
{
#ifdef HAVE_X11R6_XIM
struct xim_inst_t *xim_inst = dpyinfo->xim_callback_data;
if (dpyinfo->display)
{
Bool ret = XUnregisterIMInstantiateCallback
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment