[PD-dev] text placement

Miller Puckette mpuckett at imusic1.ucsd.edu
Mon Jan 8 20:49:29 CET 2007


In g_rtext.c:

        sys_vgui("pdtk_text_new .x%lx.c %s %f %f {%.*s} %d %s\n",
            canvas, x->x_tag,
            dispx + LMARGIN, dispy + TMARGIN,
            outchars, tempbuf, sys_hostfontsize(font),
            (glist_isselected(x->x_glist,
                &x->x_glist->gl_gobj)? "blue" : "black"));

places the text, and the border gets drawn in the text_drawborder()
function.  I couldn't spot anything platform-dependent in the code,
although I've noticed that drawing comes out differently on Mac compared
to other platforms - create a slider, for instance and look at the bar.
I believe Pd corrects for that when drawing inlets/outlet on objects,
but I don't think there's anywhere else.

cheers
Miller

On Mon, Jan 08, 2007 at 01:20:49PM -0500, Hans-Christoph Steiner wrote:
> 
> Can anyone point me to where the text is placed on the canvas in  
> relation to the object and message boxes?  It seems to vary depending  
> on platform and I'd like to troubleshoot it.
> 
> .hc
> 
> ------------------------------------------------------------------------
> 
> As we enjoy great advantages from inventions of others, we should be  
> glad of an opportunity to serve others by any invention of ours; and  
> this we should do freely and generously.         - Benjamin Franklin
> 
> 
> 
> _______________________________________________
> PD-dev mailing list
> PD-dev at iem.at
> http://lists.puredata.info/listinfo/pd-dev




More information about the Pd-dev mailing list