[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
gEDA-cvs: CVS update: defines.h
User: cnieves
Date: 05/03/05 19:00:26
Modified: . defines.h prototype.h
Log:
Improved Unicode support, character to font file mapping by hashtable,
and font mapping definition using system-gafrc.
Revision Changes Path
1.46 +10 -0 eda/geda/devel/libgeda/include/defines.h
(In the diff below, changes in quantity of whitespace are not shown.)
Index: defines.h
===================================================================
RCS file: /home/cvspsrv/cvsroot/eda/geda/devel/libgeda/include/defines.h,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -b -r1.45 -r1.46
--- defines.h 20 Feb 2005 17:05:39 -0000 1.45
+++ defines.h 6 Mar 2005 00:00:25 -0000 1.46
@@ -355,6 +355,16 @@
#define M_PI 3.14159265358979323846
#endif
+/* Since we use Unicode, which isn't supported in GTK 1.2, define
+ the equivalent of the used functions here.
+ GTK 1.2 always deal with chars, instead of multibyte characters
+ as Unicode. */
+#ifdef HAS_GTK12
+typedef unsigned char gunichar;
+#define g_utf8_get_char_validated(string, len) (*((char *)string))
+#define g_utf8_find_next_char(string, len) ((char*)string+1)
+#endif
+
/* inspired of GLib's g_message() (gmessages.h) - LGPL */
#ifdef G_HAVE_ISO_VARARGS
1.95 +2 -1 eda/geda/devel/libgeda/include/prototype.h
(In the diff below, changes in quantity of whitespace are not shown.)
Index: prototype.h
===================================================================
RCS file: /home/cvspsrv/cvsroot/eda/geda/devel/libgeda/include/prototype.h,v
retrieving revision 1.94
retrieving revision 1.95
diff -u -b -r1.94 -r1.95
--- prototype.h 20 Feb 2005 17:05:39 -0000 1.94
+++ prototype.h 6 Mar 2005 00:00:25 -0000 1.95
@@ -54,6 +54,7 @@
SCM g_rc_bitmap_directory(SCM path);
SCM g_rc_scheme_directory(SCM path);
SCM g_rc_bus_ripper_symname(SCM scmsymname);
+SCM g_rc_map_font_character_to_file(SCM character_param, SCM file_param);
/* g_register.c */
void g_register_libgeda_funcs(void);
@@ -420,7 +421,7 @@
OBJECT *o_text_add_head(void);
void o_text_init(void);
void o_text_print_set(void);
-OBJECT *o_text_load_font(TOPLEVEL *w_current, unsigned char needed_char);
+OBJECT *o_text_load_font(TOPLEVEL *w_current, gunichar needed_char);
int o_text_num_lines(char *string);
int o_text_height(char *string, int size);
int o_text_width(TOPLEVEL *w_current, char *string, int size);