Mercurial > MadButterfly
view examples/svg2code_ex/Makefile.pmake @ 446:2437047b8bb8
Fix bug of propertional shifting of sh_stext_t.
Original
- sh_stext_t does not apply shifting of text himself to scaled font face, but
- apply aggreagated matrix to font face.
- shifting in parent parent coord_t would applied to scaled font.
- amount of shifting is also multiplied by aggreagated matrix.
- It means shiftings of parent coord_ts are applied two times.
Now,
- remove x, y shifting from aggreagated matrices before applying
to scaled fonts.
author | Thinker K.F. Li <thinker@branda.to> |
---|---|
date | Sun, 02 Aug 2009 10:59:59 +0800 |
parents | d0646a6df46f |
children |
line wrap: on
line source
SVG=svg2code_ex.svg PREFIX?=/usr/local TOOLSDIR?=$(PREFIX)/share/mb INCDIR?=$(PREFIX)/include LIBDIR?=$(PREFIX)/lib BINDIR?=$(PREFIX)/bin INCS=-I$(INCDIR) CFLAGS+=`pkg-config --cflags cairo` $(INCS) -Wall LDFLAGS=-L$(LIBDIR) `pkg-config --libs cairo` LIBS=-lmbfly BINS= ex1 SVG2CODE= $(BINDIR)/svg2code.py MB_C_HEADER= $(TOOLSDIR)/mb_c_header.m4 MB_C_SOURCE= $(TOOLSDIR)/mb_c_source.m4 all: $(BINS) ex1: main.o $(SVG:C/.svg/.o/) $(CC) $(LDFLAGS) -o $@ $(.ALLSRC) $(LIBS) main.o: main.c $(SVG:C/.svg/.h/) $(CC) $(CFLAGS) -c -o $@ main.c $(SVG:C/.svg/.o/): $(SVG:C/.svg/.c/) $(SVG:C/.svg/.h/) $(CC) -c $(CFLAGS) -o $@ $(SVG:C/.svg/.c/) $(SVG:C/.svg/.mb/): $(SVG) $(SVG2CODE) $(.ALLSRC) $@ $(SVG:C/.svg/.c/): $(SVG:C/.svg/.mb/) m4 -I $(TOOLSDIR) $(MB_C_SOURCE) $(.ALLSRC) > $@ $(SVG:C/.svg/.h/): $(SVG:C/.svg/.mb/) m4 -I $(TOOLSDIR) $(MB_C_HEADER) $(.ALLSRC) > $@ clean: for i in *.mb *.o *.core *~ $(SVG:C/.svg/.c/) $(SVG:C/.svg/.h/) $(BINS); do \ if [ -e "$$i" ]; then \ echo "delete $$i"; \ rm -f "$$i"; \ fi; \ done