gnu-emacs-sources
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

gobject-c-align.el --- GObject C code alignment


From: Daiki Ueno
Subject: gobject-c-align.el --- GObject C code alignment
Date: Tue, 01 Jun 2010 07:22:01 +0900
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux)

Someone working with GObject-based code might be interested.

This package arranges C source code alignment in the style commonly used
in GNOME or GTK+.  For example, given that you have the following lines
selected:

 void eek_key_set_labels (EekKey *self, const gchar **labels);
 G_CONST_RETURN gchar *eek_key_get_label (EekKey *self);
 void eek_key_set_group_level (EekKey *self, gint group, gint level);
 gint eek_key_get_group (EekKey *self);
 gint eek_key_get_level (EekKey *self);
 void eek_key_long_method_name_which_requires_line_wrap (void);
 void eek_key_even_longer_method_name_which_occupies_preceding_spaces (void);

If you type `M-x gobject-c-align-func-decls-region', you will get:

 void                  eek_key_set_labels      (EekKey       *self,
                                                const gchar **labels);
 G_CONST_RETURN gchar *eek_key_get_label       (EekKey       *self);
 void                  eek_key_set_group_level (EekKey       *self,
                                                gint          group,
                                                gint          level);
 gint                  eek_key_get_group       (EekKey       *self);
 gint                  eek_key_get_level       (EekKey       *self);
 void                  eek_key_long_method_name_which_requires_line_wrap
                                               (void);
 void eek_key_even_longer_method_name_which_occupies_preceding_spaces
                                               (void);

Attachment: gobject-c-align.el
Description: application/emacs-lisp

Regards,
-- 
Daiki Ueno

reply via email to

[Prev in Thread] Current Thread [Next in Thread]