summaryrefslogtreecommitdiff
path: root/src/xsettings.c
diff options
context:
space:
mode:
authorJan D <jan.h.d@swipnet.se>2010-07-05 11:17:12 +0200
committerJan D <jan.h.d@swipnet.se>2010-07-05 11:17:12 +0200
commite4c8d29a32adbde811a109d5e19caa75fd9d042b (patch)
treeffaa67180bd87eae947408a76cddecaaa1c227b0 /src/xsettings.c
parent898b4c5c2cb4b4ae2fa2cd1631db63a9acff787a (diff)
downloademacs-e4c8d29a32adbde811a109d5e19caa75fd9d042b.tar.gz
Fix some bad prototypes and formatting after conversion from K&R declaration.
* lwlib/lwlib-Xaw.c: Include <ctype.h> for isdigit. (fill_xft_data, set_text): Remove unused variable screen. (draw_text): Cast bp to FcChar8*. (find_xft_data): Return 0 if inst or xft_data is not set. (wm_delete_window): Correct prototype. Initialize widget to 0 and return if widget is still 0 after loop. * lwlib/xlwmenu.c (XlwMenuSetValues, XlwMenuInitialize): Correct prototype. (display_menu_item): Remove unused variable gi. (make_windows_if_needed): Remove unused variable screen. (XlwMenuRedisplay): Remove unused variable i. * src/gtkutil.c (xg_get_pixbuf_from_pix_and_mask) (xg_get_image_for_pixmap, create_dialog) (xg_get_file_with_selection, xg_get_file_name, update_cl_data) (menuitem_highlight_callback, make_menu_item) (xg_create_one_menuitem, create_menus, xg_update_menu_item) (xg_create_scroll_bar, xg_update_scrollbar_pos) (xg_set_toolkit_scroll_bar_thumb, xg_tool_bar_button_cb) (xg_tool_bar_proxy_help_callback, xg_tool_bar_detach_callback) (xg_tool_bar_attach_callback, xg_tool_bar_help_callback) (xg_tool_bar_item_expose_callback): Reformat prototype. (xg_update_menubar): GList *group => GSList *group. (xg_modify_menubar_widgets): Initialize witem to 0, check witem != 0 before use. (update_frame_tool_bar): 4:th param to xg_get_image_for_pixmap changed to GTK_IMAGE (wimage). * src/xsettings.c (something_changedCB, parse_settings) (apply_xft_settings): Reformat prototype. (something_changedCB, init_gconf): Remove unused variable i. (read_settings): Remove unused variable long_len. * src/xsmfns.c (SSDATA): New macro. (smc_save_yourself_CB, x_session_initialize): Use SSDATA for strings passed to strlen/strcpy/strcat. (create_client_leader_window): Surround with #ifndef USE_GTK. Cast 7:th arg to XChangeProperty to (unsigned char *)
Diffstat (limited to 'src/xsettings.c')
-rw-r--r--src/xsettings.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/src/xsettings.c b/src/xsettings.c
index e8aba9ef2d8..a8c89f5fb3d 100644
--- a/src/xsettings.c
+++ b/src/xsettings.c
@@ -100,7 +100,10 @@ struct xsettings
that is SYSTEM_MONO_FONT. */
static void
-something_changedCB (GConfClient *client, guint cnxn_id, GConfEntry *entry, gpointer user_data)
+something_changedCB (GConfClient *client,
+ guint cnxn_id,
+ GConfEntry *entry,
+ gpointer user_data)
{
GConfValue *v = gconf_entry_get_value (entry);
@@ -108,7 +111,6 @@ something_changedCB (GConfClient *client, guint cnxn_id, GConfEntry *entry, gpoi
if (v->type == GCONF_VALUE_STRING)
{
const char *value = gconf_value_get_string (v);
- int i;
if (current_mono_font != NULL && strcmp (value, current_mono_font) == 0)
return; /* No change. */
@@ -222,7 +224,9 @@ get_prop_window (struct x_display_info *dpyinfo)
*/
static int
-parse_settings (unsigned char *prop, long unsigned int bytes, struct xsettings *settings)
+parse_settings (unsigned char *prop,
+ long unsigned int bytes,
+ struct xsettings *settings)
{
Lisp_Object byteorder = Fbyteorder ();
int my_bo = XFASTINT (byteorder) == 'B' ? MSBFirst : LSBFirst;
@@ -394,7 +398,6 @@ parse_settings (unsigned char *prop, long unsigned int bytes, struct xsettings *
static int
read_settings (struct x_display_info *dpyinfo, struct xsettings *settings)
{
- long long_len;
Atom act_type;
int act_form;
unsigned long nitems, bytes_after;
@@ -423,7 +426,9 @@ read_settings (struct x_display_info *dpyinfo, struct xsettings *settings)
static void
-apply_xft_settings (struct x_display_info *dpyinfo, int send_event_p, struct xsettings *settings)
+apply_xft_settings (struct x_display_info *dpyinfo,
+ int send_event_p,
+ struct xsettings *settings)
{
#ifdef HAVE_XFT
FcPattern *pat;
@@ -620,7 +625,6 @@ static void
init_gconf (void)
{
#if defined (HAVE_GCONF) && defined (HAVE_XFT)
- int i;
char *s;
g_type_init ();