Mercurial > MadButterfly
changeset 287:5c066380a84e
* Fix tspan inside tspan parsing issue
* Fix the compilation issue for the dynamic. However, we need to find why the rules for so does not work.
author | wycc |
---|---|
date | Sat, 31 Jan 2009 17:24:00 +0800 |
parents | 22d771e1b710 |
children | d5327265da1e |
files | examples/dynamic/Makefile.am tools/svg2code.py |
diffstat | 2 files changed, 19 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/examples/dynamic/Makefile.am Sat Jan 31 16:54:03 2009 +0800 +++ b/examples/dynamic/Makefile.am Sat Jan 31 17:24:00 2009 +0800 @@ -1,15 +1,28 @@ include $(top_srcdir)/config.mk -SUFFIXES=.svg .mbso +#SUFFIXES=.svg .mbso -%.so:%.svg +button.so:button.svg $(top_srcdir)/tools/svg2code.py $< $<.mb m4 -I $(top_srcdir)/tools mb_c_source.m4 $<.mb > $(<:.svg=.c) m4 -I $(top_srcdir)/tools mb_c_header.m4 $<.mb > $(<:.svg=.h) make $(<:.svg=.o) - gcc -shared -o $@ $(<:.svg=.o) + $(CC) -shared -o $@ $(<:.svg=.o) -noinst_PROGRAMS = dynamic hello text +mytext.so:mytext.svg + $(top_srcdir)/tools/svg2code.py $< $<.mb + m4 -I $(top_srcdir)/tools mb_c_source.m4 $<.mb > $(<:.svg=.c) + m4 -I $(top_srcdir)/tools mb_c_header.m4 $<.mb > $(<:.svg=.h) + make $(<:.svg=.o) + $(CC) -shared -o $@ $(<:.svg=.o) +scene.so:scene.svg + $(top_srcdir)/tools/svg2code.py $< $<.mb + m4 -I $(top_srcdir)/tools mb_c_source.m4 $<.mb > $(<:.svg=.c) + m4 -I $(top_srcdir)/tools mb_c_header.m4 $<.mb > $(<:.svg=.h) + make $(<:.svg=.o) + $(CC) -shared -o $@ $(<:.svg=.o) + +noinst_PROGRAMS = dynamic hello text button.so mytext.so scene.so EXTRA_DIST = menu.svg button.svg dynamic_SOURCES = main.c mbapp.c mbapp.h mbbutton.c mbbutton.h @@ -18,7 +31,7 @@ dynamic_LDFLAGS = @pangocairo_LIBS@ dynamic_LDADD = $(top_builddir)/src/libmbfly.la BUILT_SOURCES = -CLEANFILES = menu.c menu.h menu.mb button.c button.h button.mb +CLEANFILES = menu.c menu.h menu.mb button.mb hello_SOURCES = hello.c mbapp.c mbapp.h
--- a/tools/svg2code.py Sat Jan 31 16:54:03 2009 +0800 +++ b/tools/svg2code.py Sat Jan 31 17:24:00 2009 +0800 @@ -444,7 +444,7 @@ if node.localName == None: txt_strs = txt_strs + node.data elif node.localName == 'tspan': - txt_strs = translate_tspan(node,coord_id, codefo, doc,txt_strs,attrs) + txt_strs = translate_tspan(node,tspan,coord_id, codefo, doc,txt_strs,attrs) pass pass attr[1] = len(txt_strs.encode('utf8'))