aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPaul Eggert2011-04-12 01:39:43 -0700
committerPaul Eggert2011-04-12 01:39:43 -0700
commite4cebfca13580f80fb0ecee27afb81b55c031535 (patch)
tree26a3dc715187305f33eac0a04cf6e195c6ca3f0a /src
parent5bf46f05111229b5b9e7b6435151bd0f84586eb4 (diff)
downloademacs-e4cebfca13580f80fb0ecee27afb81b55c031535.tar.gz
emacs-e4cebfca13580f80fb0ecee27afb81b55c031535.zip
* xfns.c: Make symbols static if they're not exported.
(x_last_font_name, x_display_info_for_name): (x_set_foreground_color, x_set_background_color, x_set_mouse_color): (x_set_cursor_color, x_set_border_pixel, x_set_border_color): (x_set_cursor_type, x_set_icon_type, x_set_icon_name): (x_set_scroll_bar_foreground, x_set_scroll_bar_background): (x_explicitly_set_name, x_set_title, xic_defaut_fontset, tip_timer): (last_show_tip_args): Now static. (xic_defaut_fontset, xic_create_fontsetname): Define only if defined HAVE_X_WINDOWS && defined USE_X_TOOLKIT (x_screen_planes): Remove; unused. * dispextern.h (x_screen_planes): Remove decl.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog13
-rw-r--r--src/dispextern.h1
-rw-r--r--src/xfns.c75
3 files changed, 35 insertions, 54 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 572644bf1c7..9b145d865db 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,5 +1,18 @@
12011-04-12 Paul Eggert <eggert@cs.ucla.edu> 12011-04-12 Paul Eggert <eggert@cs.ucla.edu>
2 2
3 * xfns.c: Make symbols static if they're not exported.
4 (x_last_font_name, x_display_info_for_name):
5 (x_set_foreground_color, x_set_background_color, x_set_mouse_color):
6 (x_set_cursor_color, x_set_border_pixel, x_set_border_color):
7 (x_set_cursor_type, x_set_icon_type, x_set_icon_name):
8 (x_set_scroll_bar_foreground, x_set_scroll_bar_background):
9 (x_explicitly_set_name, x_set_title, xic_defaut_fontset, tip_timer):
10 (last_show_tip_args): Now static.
11 (xic_defaut_fontset, xic_create_fontsetname): Define only if
12 defined HAVE_X_WINDOWS && defined USE_X_TOOLKIT
13 (x_screen_planes): Remove; unused.
14 * dispextern.h (x_screen_planes): Remove decl.
15
3 * dispnew.c: Make symbols static if they're not exported. 16 * dispnew.c: Make symbols static if they're not exported.
4 * dispextern.h (redraw_garbaged_frames, scrolling): 17 * dispextern.h (redraw_garbaged_frames, scrolling):
5 (increment_row_positions): Remove. 18 (increment_row_positions): Remove.
diff --git a/src/dispextern.h b/src/dispextern.h
index eb5090343e6..4ad107a7266 100644
--- a/src/dispextern.h
+++ b/src/dispextern.h
@@ -3171,7 +3171,6 @@ void gamma_correct (struct frame *, COLORREF *);
3171 3171
3172#ifdef HAVE_WINDOW_SYSTEM 3172#ifdef HAVE_WINDOW_SYSTEM
3173 3173
3174int x_screen_planes (struct frame *);
3175void x_implicitly_set_name (struct frame *, Lisp_Object, Lisp_Object); 3174void x_implicitly_set_name (struct frame *, Lisp_Object, Lisp_Object);
3176 3175
3177extern Lisp_Object tip_frame; 3176extern Lisp_Object tip_frame;
diff --git a/src/xfns.c b/src/xfns.c
index 6fd332016ce..50a56b55614 100644
--- a/src/xfns.c
+++ b/src/xfns.c
@@ -150,9 +150,11 @@ int image_cache_refcount, dpyinfo_refcount;
150#endif 150#endif
151 151
152#if defined (USE_GTK) && defined (HAVE_FREETYPE) 152#if defined (USE_GTK) && defined (HAVE_FREETYPE)
153char *x_last_font_name; 153static char *x_last_font_name;
154#endif 154#endif
155 155
156static struct x_display_info *x_display_info_for_name (Lisp_Object);
157
156 158
157/* Error if we are not connected to X. */ 159/* Error if we are not connected to X. */
158 160
@@ -419,35 +421,6 @@ x_top_window_to_frame (struct x_display_info *dpyinfo, int wdesc)
419 421
420 422
421 423
422static void x_default_font_parameter (struct frame *, Lisp_Object);
423
424static Lisp_Object unwind_create_frame (Lisp_Object);
425static Lisp_Object unwind_create_tip_frame (Lisp_Object);
426
427void x_set_foreground_color (struct frame *, Lisp_Object, Lisp_Object);
428static void x_set_wait_for_wm (struct frame *, Lisp_Object, Lisp_Object);
429void x_set_background_color (struct frame *, Lisp_Object, Lisp_Object);
430void x_set_mouse_color (struct frame *, Lisp_Object, Lisp_Object);
431void x_set_cursor_color (struct frame *, Lisp_Object, Lisp_Object);
432void x_set_border_color (struct frame *, Lisp_Object, Lisp_Object);
433void x_set_cursor_type (struct frame *, Lisp_Object, Lisp_Object);
434void x_set_icon_type (struct frame *, Lisp_Object, Lisp_Object);
435void x_set_icon_name (struct frame *, Lisp_Object, Lisp_Object);
436void x_explicitly_set_name (struct frame *, Lisp_Object, Lisp_Object);
437void x_set_menu_bar_lines (struct frame *, Lisp_Object, Lisp_Object);
438void x_set_title (struct frame *, Lisp_Object, Lisp_Object);
439void x_set_tool_bar_lines (struct frame *, Lisp_Object, Lisp_Object);
440void x_set_scroll_bar_foreground (struct frame *, Lisp_Object,
441 Lisp_Object);
442void x_set_scroll_bar_background (struct frame *, Lisp_Object,
443 Lisp_Object);
444static Lisp_Object x_default_scroll_bar_color_parameter (struct frame *,
445 Lisp_Object,
446 Lisp_Object,
447 const char *, const char *,
448 int);
449
450
451/* Store the screen positions of frame F into XPTR and YPTR. 424/* Store the screen positions of frame F into XPTR and YPTR.
452 These are the positions of the containing window manager window, 425 These are the positions of the containing window manager window,
453 not Emacs's own window. */ 426 not Emacs's own window. */
@@ -766,7 +739,7 @@ xg_set_icon_from_xpm_data (FRAME_PTR f, const char **data)
766 In that case, just record the parameter's new value 739 In that case, just record the parameter's new value
767 in the standard place; do not attempt to change the window. */ 740 in the standard place; do not attempt to change the window. */
768 741
769void 742static void
770x_set_foreground_color (struct frame *f, Lisp_Object arg, Lisp_Object oldval) 743x_set_foreground_color (struct frame *f, Lisp_Object arg, Lisp_Object oldval)
771{ 744{
772 struct x_output *x = f->output_data.x; 745 struct x_output *x = f->output_data.x;
@@ -802,7 +775,7 @@ x_set_foreground_color (struct frame *f, Lisp_Object arg, Lisp_Object oldval)
802 unload_color (f, old_fg); 775 unload_color (f, old_fg);
803} 776}
804 777
805void 778static void
806x_set_background_color (struct frame *f, Lisp_Object arg, Lisp_Object oldval) 779x_set_background_color (struct frame *f, Lisp_Object arg, Lisp_Object oldval)
807{ 780{
808 struct x_output *x = f->output_data.x; 781 struct x_output *x = f->output_data.x;
@@ -877,7 +850,7 @@ make_invisible_cursor (struct frame *f)
877 return c; 850 return c;
878} 851}
879 852
880void 853static void
881x_set_mouse_color (struct frame *f, Lisp_Object arg, Lisp_Object oldval) 854x_set_mouse_color (struct frame *f, Lisp_Object arg, Lisp_Object oldval)
882{ 855{
883 struct x_output *x = f->output_data.x; 856 struct x_output *x = f->output_data.x;
@@ -1022,7 +995,7 @@ x_set_mouse_color (struct frame *f, Lisp_Object arg, Lisp_Object oldval)
1022 update_face_from_frame_parameter (f, Qmouse_color, arg); 995 update_face_from_frame_parameter (f, Qmouse_color, arg);
1023} 996}
1024 997
1025void 998static void
1026x_set_cursor_color (struct frame *f, Lisp_Object arg, Lisp_Object oldval) 999x_set_cursor_color (struct frame *f, Lisp_Object arg, Lisp_Object oldval)
1027{ 1000{
1028 unsigned long fore_pixel, pixel; 1001 unsigned long fore_pixel, pixel;
@@ -1093,7 +1066,7 @@ x_set_cursor_color (struct frame *f, Lisp_Object arg, Lisp_Object oldval)
1093 Note that this does not fully take effect if done before 1066 Note that this does not fully take effect if done before
1094 F has an x-window. */ 1067 F has an x-window. */
1095 1068
1096void 1069static void
1097x_set_border_pixel (struct frame *f, int pix) 1070x_set_border_pixel (struct frame *f, int pix)
1098{ 1071{
1099 unload_color (f, f->output_data.x->border_pixel); 1072 unload_color (f, f->output_data.x->border_pixel);
@@ -1122,7 +1095,7 @@ x_set_border_pixel (struct frame *f, int pix)
1122 Note: under X11, this is normally the province of the window manager, 1095 Note: under X11, this is normally the province of the window manager,
1123 and so emacs' border colors may be overridden. */ 1096 and so emacs' border colors may be overridden. */
1124 1097
1125void 1098static void
1126x_set_border_color (struct frame *f, Lisp_Object arg, Lisp_Object oldval) 1099x_set_border_color (struct frame *f, Lisp_Object arg, Lisp_Object oldval)
1127{ 1100{
1128 int pix; 1101 int pix;
@@ -1134,7 +1107,7 @@ x_set_border_color (struct frame *f, Lisp_Object arg, Lisp_Object oldval)
1134} 1107}
1135 1108
1136 1109
1137void 1110static void
1138x_set_cursor_type (FRAME_PTR f, Lisp_Object arg, Lisp_Object oldval) 1111x_set_cursor_type (FRAME_PTR f, Lisp_Object arg, Lisp_Object oldval)
1139{ 1112{
1140 set_frame_cursor_types (f, arg); 1113 set_frame_cursor_types (f, arg);
@@ -1143,7 +1116,7 @@ x_set_cursor_type (FRAME_PTR f, Lisp_Object arg, Lisp_Object oldval)
1143 cursor_type_changed = 1; 1116 cursor_type_changed = 1;
1144} 1117}
1145 1118
1146void 1119static void
1147x_set_icon_type (struct frame *f, Lisp_Object arg, Lisp_Object oldval) 1120x_set_icon_type (struct frame *f, Lisp_Object arg, Lisp_Object oldval)
1148{ 1121{
1149 int result; 1122 int result;
@@ -1175,7 +1148,7 @@ x_set_icon_type (struct frame *f, Lisp_Object arg, Lisp_Object oldval)
1175 UNBLOCK_INPUT; 1148 UNBLOCK_INPUT;
1176} 1149}
1177 1150
1178void 1151static void
1179x_set_icon_name (struct frame *f, Lisp_Object arg, Lisp_Object oldval) 1152x_set_icon_name (struct frame *f, Lisp_Object arg, Lisp_Object oldval)
1180{ 1153{
1181 int result; 1154 int result;
@@ -1398,7 +1371,7 @@ x_set_tool_bar_lines (struct frame *f, Lisp_Object value, Lisp_Object oldval)
1398 isn't a valid color name, do nothing. OLDVAL is the old value of 1371 isn't a valid color name, do nothing. OLDVAL is the old value of
1399 the frame parameter. */ 1372 the frame parameter. */
1400 1373
1401void 1374static void
1402x_set_scroll_bar_foreground (struct frame *f, Lisp_Object value, Lisp_Object oldval) 1375x_set_scroll_bar_foreground (struct frame *f, Lisp_Object value, Lisp_Object oldval)
1403{ 1376{
1404 unsigned long pixel; 1377 unsigned long pixel;
@@ -1431,7 +1404,7 @@ x_set_scroll_bar_foreground (struct frame *f, Lisp_Object value, Lisp_Object old
1431 valid color name, do nothing. OLDVAL is the old value of the frame 1404 valid color name, do nothing. OLDVAL is the old value of the frame
1432 parameter. */ 1405 parameter. */
1433 1406
1434void 1407static void
1435x_set_scroll_bar_background (struct frame *f, Lisp_Object value, Lisp_Object oldval) 1408x_set_scroll_bar_background (struct frame *f, Lisp_Object value, Lisp_Object oldval)
1436{ 1409{
1437 unsigned long pixel; 1410 unsigned long pixel;
@@ -1682,7 +1655,7 @@ x_set_name (struct frame *f, Lisp_Object name, int explicit)
1682/* This function should be called when the user's lisp code has 1655/* This function should be called when the user's lisp code has
1683 specified a name for the frame; the name will override any set by the 1656 specified a name for the frame; the name will override any set by the
1684 redisplay code. */ 1657 redisplay code. */
1685void 1658static void
1686x_explicitly_set_name (FRAME_PTR f, Lisp_Object arg, Lisp_Object oldval) 1659x_explicitly_set_name (FRAME_PTR f, Lisp_Object arg, Lisp_Object oldval)
1687{ 1660{
1688 x_set_name (f, arg, 1); 1661 x_set_name (f, arg, 1);
@@ -1700,7 +1673,7 @@ x_implicitly_set_name (FRAME_PTR f, Lisp_Object arg, Lisp_Object oldval)
1700/* Change the title of frame F to NAME. 1673/* Change the title of frame F to NAME.
1701 If NAME is nil, use the frame name as the title. */ 1674 If NAME is nil, use the frame name as the title. */
1702 1675
1703void 1676static void
1704x_set_title (struct frame *f, Lisp_Object name, Lisp_Object old_name) 1677x_set_title (struct frame *f, Lisp_Object name, Lisp_Object old_name)
1705{ 1678{
1706 /* Don't change the title if it's already NAME. */ 1679 /* Don't change the title if it's already NAME. */
@@ -1888,9 +1861,10 @@ static XIMStyle supported_xim_styles[] =
1888}; 1861};
1889 1862
1890 1863
1864#if defined HAVE_X_WINDOWS && defined USE_X_TOOLKIT
1891/* Create an X fontset on frame F with base font name BASE_FONTNAME. */ 1865/* Create an X fontset on frame F with base font name BASE_FONTNAME. */
1892 1866
1893const char xic_defaut_fontset[] = "-*-*-*-r-normal--14-*-*-*-*-*-*-*"; 1867static const char xic_defaut_fontset[] = "-*-*-*-r-normal--14-*-*-*-*-*-*-*";
1894 1868
1895/* Create an Xt fontset spec from the name of a base font. 1869/* Create an Xt fontset spec from the name of a base font.
1896 If `motif' is True use the Motif syntax. */ 1870 If `motif' is True use the Motif syntax. */
@@ -2016,6 +1990,7 @@ xic_create_fontsetname (const char *base_fontname, int motif)
2016 strcat (fontsetname, ":"); 1990 strcat (fontsetname, ":");
2017 return fontsetname; 1991 return fontsetname;
2018} 1992}
1993#endif /* HAVE_X_WINDOWS && USE_X_TOOLKIT */
2019 1994
2020#ifdef DEBUG_XIC_FONTSET 1995#ifdef DEBUG_XIC_FONTSET
2021static void 1996static void
@@ -3887,12 +3862,6 @@ x_char_height (register struct frame *f)
3887 return FRAME_LINE_HEIGHT (f); 3862 return FRAME_LINE_HEIGHT (f);
3888} 3863}
3889 3864
3890int
3891x_screen_planes (register struct frame *f)
3892{
3893 return FRAME_X_DISPLAY_INFO (f)->n_planes;
3894}
3895
3896 3865
3897 3866
3898/************************************************************************ 3867/************************************************************************
@@ -4017,7 +3986,7 @@ select_visual (struct x_display_info *dpyinfo)
4017/* Return the X display structure for the display named NAME. 3986/* Return the X display structure for the display named NAME.
4018 Open a new connection if necessary. */ 3987 Open a new connection if necessary. */
4019 3988
4020struct x_display_info * 3989static struct x_display_info *
4021x_display_info_for_name (Lisp_Object name) 3990x_display_info_for_name (Lisp_Object name)
4022{ 3991{
4023 Lisp_Object names; 3992 Lisp_Object names;
@@ -4538,13 +4507,13 @@ Lisp_Object tip_frame;
4538/* If non-nil, a timer started that hides the last tooltip when it 4507/* If non-nil, a timer started that hides the last tooltip when it
4539 fires. */ 4508 fires. */
4540 4509
4541Lisp_Object tip_timer; 4510static Lisp_Object tip_timer;
4542Window tip_window; 4511Window tip_window;
4543 4512
4544/* If non-nil, a vector of 3 elements containing the last args 4513/* If non-nil, a vector of 3 elements containing the last args
4545 with which x-show-tip was called. See there. */ 4514 with which x-show-tip was called. See there. */
4546 4515
4547Lisp_Object last_show_tip_args; 4516static Lisp_Object last_show_tip_args;
4548 4517
4549 4518
4550static Lisp_Object 4519static Lisp_Object