Update of /cvsroot/pure-data/pd/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8462
Modified Files: Tag: branch-v0-39-2-extended g_all_guis.c g_bang.c g_hdial.c g_hslider.c g_mycanvas.c g_numbox.c g_vdial.c m_pd.h s_inter.c s_main.c g_graph.c g_template.c Log Message: use global sys_font instead of local font name; set global font to DejaVu Sans Mono
Index: s_main.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/s_main.c,v retrieving revision 1.20.2.4 retrieving revision 1.20.2.5 diff -C2 -d -r1.20.2.4 -r1.20.2.5 *** s_main.c 8 Jan 2007 05:50:30 -0000 1.20.2.4 --- s_main.c 28 Jan 2007 21:50:54 -0000 1.20.2.5 *************** *** 58,62 **** int sys_midioutdevlist[MAXMIDIOUTDEV] = {1};
! char sys_font[] = "Bitstream Vera Sans Mono"; /* tb: font name */ static int sys_main_srate; static int sys_main_advance; --- 58,62 ---- int sys_midioutdevlist[MAXMIDIOUTDEV] = {1};
! char sys_font[] = "DejaVu Sans Mono"; /* tb: font name */ static int sys_main_srate; static int sys_main_advance; *************** *** 105,110 ****
static t_fontinfo sys_fontlist[] = { ! {8, 5, 9, 8, 5, 9}, {10, 7, 13, 10, 7, 14}, {12, 9, 16, 12, 8, 16}, ! {16, 10, 20, 16, 10, 18},{24, 15, 25, 24, 15, 29},{36, 25, 45, 36, 23, 43}}; #define NFONT (sizeof(sys_fontlist)/sizeof(*sys_fontlist))
--- 105,110 ----
static t_fontinfo sys_fontlist[] = { ! {8, 5, 9, 8, 5, 9},{10, 6, 13, 10, 6, 13},{12, 7, 16, 12, 7, 16}, ! {16, 10, 18, 16, 10, 18},{24, 14, 25, 24, 14, 25},{36, 23, 43, 36, 23, 43}}; #define NFONT (sizeof(sys_fontlist)/sizeof(*sys_fontlist))
*************** *** 361,365 **** "-lib <file> -- load object library(s)\n", "-font <n> -- specify default font size in points\n", ! "-typeface <name> -- specify default font (default: Bitstream Vera Sans Mono)\n", "-verbose -- extra printout on startup and when searching for files\n", "-version -- don't run Pd; just print out which version it is \n", --- 361,365 ---- "-lib <file> -- load object library(s)\n", "-font <n> -- specify default font size in points\n", ! "-typeface <name> -- specify default font (default: DejaVu Sans)\n", "-verbose -- extra printout on startup and when searching for files\n", "-version -- don't run Pd; just print out which version it is \n",
Index: g_template.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_template.c,v retrieving revision 1.13.2.2 retrieving revision 1.13.2.3 diff -C2 -d -r1.13.2.2 -r1.13.2.3 *** g_template.c 8 Jan 2007 02:07:16 -0000 1.13.2.2 --- g_template.c 28 Jan 2007 21:50:54 -0000 1.13.2.3 *************** *** 2091,2095 **** sys_vgui(".x%lx.c create text %d %d -anchor nw -fill %s -text {%s}", glist_getcanvas(glist), xloc, yloc, colorstring, buf); ! sys_vgui(" -font {{Bitstream Vera Sans Mono} %d normal}", sys_hostfontsize(glist_getfont(glist))); sys_vgui(" -tags drawnumber%lx\n", data); --- 2091,2095 ---- sys_vgui(".x%lx.c create text %d %d -anchor nw -fill %s -text {%s}", glist_getcanvas(glist), xloc, yloc, colorstring, buf); ! sys_vgui(" -font {{%s} %d normal}", sys_font, sys_hostfontsize(glist_getfont(glist))); sys_vgui(" -tags drawnumber%lx\n", data);
Index: g_vdial.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_vdial.c,v retrieving revision 1.5.2.1 retrieving revision 1.5.2.2 diff -C2 -d -r1.5.2.1 -r1.5.2.2 *** g_vdial.c 8 Jan 2007 02:07:16 -0000 1.5.2.1 --- g_vdial.c 28 Jan 2007 21:50:54 -0000 1.5.2.2 *************** *** 591,595 **** else if(x->x_gui.x_fsf.x_font_style == 2) strcpy(x->x_gui.x_font, "times"); else { x->x_gui.x_fsf.x_font_style = 0; ! strcpy(x->x_gui.x_font, "Bitstream Vera Sans Mono"); } if(num < 1) num = 1; --- 591,595 ---- else if(x->x_gui.x_fsf.x_font_style == 2) strcpy(x->x_gui.x_font, "times"); else { x->x_gui.x_fsf.x_font_style = 0; ! strcpy(x->x_gui.x_font, sys_font); } if(num < 1) num = 1;
Index: g_all_guis.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_all_guis.c,v retrieving revision 1.8.2.1 retrieving revision 1.8.2.2 diff -C2 -d -r1.8.2.1 -r1.8.2.2 *** g_all_guis.c 8 Jan 2007 02:07:16 -0000 1.8.2.1 --- g_all_guis.c 28 Jan 2007 21:50:53 -0000 1.8.2.2 *************** *** 435,439 **** { f = 0; ! strcpy(iemgui->x_font, "Bitstream Vera Sans Mono"); } iemgui->x_fsf.x_font_style = f; --- 435,439 ---- { f = 0; ! strcpy(iemgui->x_font, sys_font); } iemgui->x_fsf.x_font_style = f; *************** *** 619,623 **** { f = 0; ! strcpy(iemgui->x_font, "Bitstream Vera Sans Mono"); } iemgui->x_fsf.x_font_style = f; --- 619,623 ---- { f = 0; ! strcpy(iemgui->x_font, sys_font); } iemgui->x_fsf.x_font_style = f;
Index: s_inter.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/s_inter.c,v retrieving revision 1.14.2.1 retrieving revision 1.14.2.2 diff -C2 -d -r1.14.2.1 -r1.14.2.2 *** s_inter.c 19 Dec 2006 05:55:44 -0000 1.14.2.1 --- s_inter.c 28 Jan 2007 21:50:54 -0000 1.14.2.2 *************** *** 90,94 ****
extern int sys_guisetportnumber; - extern char sys_font[]; /* tb: typeface */
static int sys_nfdpoll; --- 90,93 ----
Index: g_mycanvas.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_mycanvas.c,v retrieving revision 1.5.14.1 retrieving revision 1.5.14.2 diff -C2 -d -r1.5.14.1 -r1.5.14.2 *** g_mycanvas.c 8 Jan 2007 02:07:16 -0000 1.5.14.1 --- g_mycanvas.c 28 Jan 2007 21:50:53 -0000 1.5.14.2 *************** *** 332,336 **** else if(x->x_gui.x_fsf.x_font_style == 2) strcpy(x->x_gui.x_font, "times"); else { x->x_gui.x_fsf.x_font_style = 0; ! strcpy(x->x_gui.x_font, "Bitstream Vera Sans Mono"); } if (x->x_gui.x_fsf.x_rcv_able) pd_bind(&x->x_gui.x_obj.ob_pd, x->x_gui.x_rcv); --- 332,336 ---- else if(x->x_gui.x_fsf.x_font_style == 2) strcpy(x->x_gui.x_font, "times"); else { x->x_gui.x_fsf.x_font_style = 0; ! strcpy(x->x_gui.x_font, sys_font); } if (x->x_gui.x_fsf.x_rcv_able) pd_bind(&x->x_gui.x_obj.ob_pd, x->x_gui.x_rcv);
Index: m_pd.h =================================================================== RCS file: /cvsroot/pure-data/pd/src/m_pd.h,v retrieving revision 1.8.2.2 retrieving revision 1.8.2.3 diff -C2 -d -r1.8.2.2 -r1.8.2.3 *** m_pd.h 6 Jan 2007 02:53:17 -0000 1.8.2.2 --- m_pd.h 28 Jan 2007 21:50:54 -0000 1.8.2.3 *************** *** 367,370 **** --- 367,371 ---- char *result,int resultsize); EXTERN t_symbol *canvas_getdir(t_glist *x); + extern char sys_font[]; /* default typeface set in s_main.c */ EXTERN int sys_fontwidth(int fontsize); EXTERN int sys_fontheight(int fontsize);
Index: g_graph.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_graph.c,v retrieving revision 1.9.2.2 retrieving revision 1.9.2.3 diff -C2 -d -r1.9.2.2 -r1.9.2.3 *** g_graph.c 8 Jan 2007 02:07:16 -0000 1.9.2.2 --- g_graph.c 28 Jan 2007 21:50:54 -0000 1.9.2.3 *************** *** 748,752 **** t_symbol *s = garray_getname((t_garray *)g); sys_vgui(".x%lx.c create text %d %d -text {%s} -anchor sw\ ! -font {{Bitstream Vera Sans Mono} %d normal} -tags %s\n", (long)glist_getcanvas(x), x1, ymin, s->s_name, sys_hostfontsize(glist_getfont(x)), tag); --- 748,752 ---- t_symbol *s = garray_getname((t_garray *)g); sys_vgui(".x%lx.c create text %d %d -text {%s} -anchor sw\ ! -font {{%s} %d normal} -tags %s\n", sys_font, (long)glist_getcanvas(x), x1, ymin, s->s_name, sys_hostfontsize(glist_getfont(x)), tag); *************** *** 830,847 **** for (i = 0; i < x->gl_nxlabels; i++) sys_vgui(".x%lx.c create text\ ! %d %d -text {%s} -font {{Bitstream Vera Sans Mono} %d normal} -tags %s\n", glist_getcanvas(x), (int)glist_xtopixels(x, atof(x->gl_xlabel[i]->s_name)), ! (int)glist_ytopixels(x, x->gl_xlabely), x->gl_xlabel[i]->s_name, ! glist_getfont(x), tag);
/* draw y labels */ for (i = 0; i < x->gl_nylabels; i++) sys_vgui(".x%lx.c create text\ ! %d %d -text {%s} -font {{Bitstream Vera Sans Mono} %d normal} -tags %s\n", glist_getcanvas(x), (int)glist_xtopixels(x, x->gl_ylabelx), (int)glist_ytopixels(x, atof(x->gl_ylabel[i]->s_name)), ! x->gl_ylabel[i]->s_name, glist_getfont(x), tag);
--- 830,847 ---- for (i = 0; i < x->gl_nxlabels; i++) sys_vgui(".x%lx.c create text\ ! %d %d -text {%s} -font {{%s} %d normal} -tags %s\n", glist_getcanvas(x), (int)glist_xtopixels(x, atof(x->gl_xlabel[i]->s_name)), ! (int)glist_ytopixels(x, x->gl_xlabely), sys_font, ! x->gl_xlabel[i]->s_name, glist_getfont(x), tag);
/* draw y labels */ for (i = 0; i < x->gl_nylabels; i++) sys_vgui(".x%lx.c create text\ ! %d %d -text {%s} -font {{%s} %d normal} -tags %s\n", glist_getcanvas(x), (int)glist_xtopixels(x, x->gl_ylabelx), (int)glist_ytopixels(x, atof(x->gl_ylabel[i]->s_name)), ! x->gl_ylabel[i]->s_name, sys_font, glist_getfont(x), tag);
Index: g_hdial.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_hdial.c,v retrieving revision 1.6.2.1 retrieving revision 1.6.2.2 diff -C2 -d -r1.6.2.1 -r1.6.2.2 *** g_hdial.c 8 Jan 2007 02:07:16 -0000 1.6.2.1 --- g_hdial.c 28 Jan 2007 21:50:53 -0000 1.6.2.2 *************** *** 590,594 **** else if(x->x_gui.x_fsf.x_font_style == 2) strcpy(x->x_gui.x_font, "times"); else { x->x_gui.x_fsf.x_font_style = 0; ! strcpy(x->x_gui.x_font, "Bitstream Vera Sans Mono"); } if(num < 1) num = 1; --- 590,594 ---- else if(x->x_gui.x_fsf.x_font_style == 2) strcpy(x->x_gui.x_font, "times"); else { x->x_gui.x_fsf.x_font_style = 0; ! strcpy(x->x_gui.x_font, sys_font); } if(num < 1) num = 1;
Index: g_hslider.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_hslider.c,v retrieving revision 1.5.2.1 retrieving revision 1.5.2.2 diff -C2 -d -r1.5.2.1 -r1.5.2.2 *** g_hslider.c 8 Jan 2007 02:07:16 -0000 1.5.2.1 --- g_hslider.c 28 Jan 2007 21:50:53 -0000 1.5.2.2 *************** *** 587,591 **** else if(x->x_gui.x_fsf.x_font_style == 2) strcpy(x->x_gui.x_font, "times"); else { x->x_gui.x_fsf.x_font_style = 0; ! strcpy(x->x_gui.x_font, "Bitstream Vera Sans Mono"); } if(x->x_gui.x_fsf.x_rcv_able) pd_bind(&x->x_gui.x_obj.ob_pd, x->x_gui.x_rcv); --- 587,591 ---- else if(x->x_gui.x_fsf.x_font_style == 2) strcpy(x->x_gui.x_font, "times"); else { x->x_gui.x_fsf.x_font_style = 0; ! strcpy(x->x_gui.x_font, sys_font); } if(x->x_gui.x_fsf.x_rcv_able) pd_bind(&x->x_gui.x_obj.ob_pd, x->x_gui.x_rcv);
Index: g_bang.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_bang.c,v retrieving revision 1.4.12.1 retrieving revision 1.4.12.2 diff -C2 -d -r1.4.12.1 -r1.4.12.2 *** g_bang.c 8 Jan 2007 02:07:16 -0000 1.4.12.1 --- g_bang.c 28 Jan 2007 21:50:53 -0000 1.4.12.2 *************** *** 482,486 **** else if(x->x_gui.x_fsf.x_font_style == 2) strcpy(x->x_gui.x_font, "times"); else { x->x_gui.x_fsf.x_font_style = 0; ! strcpy(x->x_gui.x_font, "Bitstream Vera Sans Mono"); }
if (x->x_gui.x_fsf.x_rcv_able) --- 482,486 ---- else if(x->x_gui.x_fsf.x_font_style == 2) strcpy(x->x_gui.x_font, "times"); else { x->x_gui.x_fsf.x_font_style = 0; ! strcpy(x->x_gui.x_font, sys_font); }
if (x->x_gui.x_fsf.x_rcv_able)
Index: g_numbox.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_numbox.c,v retrieving revision 1.7.2.1 retrieving revision 1.7.2.2 diff -C2 -d -r1.7.2.1 -r1.7.2.2 *** g_numbox.c 8 Jan 2007 02:07:16 -0000 1.7.2.1 --- g_numbox.c 28 Jan 2007 21:50:53 -0000 1.7.2.2 *************** *** 807,811 **** else if(x->x_gui.x_fsf.x_font_style == 2) strcpy(x->x_gui.x_font, "times"); else { x->x_gui.x_fsf.x_font_style = 0; ! strcpy(x->x_gui.x_font, "Bitstream Vera Sans Mono"); } if (x->x_gui.x_fsf.x_rcv_able) pd_bind(&x->x_gui.x_obj.ob_pd, x->x_gui.x_rcv); --- 807,811 ---- else if(x->x_gui.x_fsf.x_font_style == 2) strcpy(x->x_gui.x_font, "times"); else { x->x_gui.x_fsf.x_font_style = 0; ! strcpy(x->x_gui.x_font, sys_font); } if (x->x_gui.x_fsf.x_rcv_able) pd_bind(&x->x_gui.x_obj.ob_pd, x->x_gui.x_rcv);