00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034 #ifndef __META_ACCEL_LABEL_H__
00035 #define __META_ACCEL_LABEL_H__
00036
00037 #include <gtk/gtklabel.h>
00038 #include "common.h"
00039
00040 #ifdef __cplusplus
00041 extern "C" {
00042 #endif
00043
00044
00045 #define META_TYPE_ACCEL_LABEL (meta_accel_label_get_type ())
00046 #define META_ACCEL_LABEL(obj) (GTK_CHECK_CAST ((obj), META_TYPE_ACCEL_LABEL, MetaAccelLabel))
00047 #define META_ACCEL_LABEL_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), META_TYPE_ACCEL_LABEL, MetaAccelLabelClass))
00048 #define META_IS_ACCEL_LABEL(obj) (GTK_CHECK_TYPE ((obj), META_TYPE_ACCEL_LABEL))
00049 #define META_IS_ACCEL_LABEL_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), META_TYPE_ACCEL_LABEL))
00050 #define META_ACCEL_LABEL_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), META_TYPE_ACCEL_LABEL, MetaAccelLabelClass))
00051
00052
00053 typedef struct _MetaAccelLabel MetaAccelLabel;
00054 typedef struct _MetaAccelLabelClass MetaAccelLabelClass;
00055
00056 struct _MetaAccelLabel
00057 {
00058 GtkLabel label;
00059
00060 MetaVirtualModifier accel_mods;
00061 guint accel_key;
00062 guint accel_padding;
00063 gchar *accel_string;
00064 guint16 accel_string_width;
00065 };
00066
00067 struct _MetaAccelLabelClass
00068 {
00069 GtkLabelClass parent_class;
00070
00071 gchar *signal_quote1;
00072 gchar *signal_quote2;
00073 gchar *mod_name_shift;
00074 gchar *mod_name_control;
00075 gchar *mod_name_alt;
00076 gchar *mod_name_meta;
00077 gchar *mod_name_super;
00078 gchar *mod_name_hyper;
00079 gchar *mod_name_mod2;
00080 gchar *mod_name_mod3;
00081 gchar *mod_name_mod4;
00082 gchar *mod_name_mod5;
00083 gchar *mod_separator;
00084 gchar *accel_seperator;
00085 guint latin1_to_char : 1;
00086
00087
00088 void (*_gtk_reserved1) (void);
00089 void (*_gtk_reserved2) (void);
00090 void (*_gtk_reserved3) (void);
00091 void (*_gtk_reserved4) (void);
00092 };
00093
00094 GtkType meta_accel_label_get_type (void) G_GNUC_CONST;
00095 GtkWidget* meta_accel_label_new_with_mnemonic (const gchar *string);
00096 void meta_accel_label_set_accelerator (MetaAccelLabel *accel_label,
00097 guint accelerator_key,
00098 MetaVirtualModifier accelerator_mods);
00099
00100
00101 #ifdef __cplusplus
00102 }
00103 #endif
00104
00105
00106 #endif