[Therion] hidden points of centerline

Martin Budaj m.budaj at gmail.com
Tue Feb 10 22:34:25 CET 2009


On Fri, Feb 6, 2009 at 12:38 PM, Martin Sluka <martinsluka at mac.com> wrote:
>
> On 5.2.2009, at 8:41, Boldt, Markus wrote:
>
>> but not how it is possible to scale the Text of
>> the scalebar.

You can use this code in the layout. Change \size[20] to whatever you
need. Someday the customization parameters will be accessible from
layout without the need for redefining macros, but currently some more
important issues are on the list.

Martin

code mpost
def s_scalebar (expr l, units, txt) =
  begingroup
    interim warningcheck:=0;
    tmpl:=l / Scale * cm * units / 2;
  endgroup;
  pickup PenC;
  draw (-tmpl,0)--(tmpl,0);
  draw (-tmpl,0)--(-tmpl,2bp);
  draw (tmpl,0)--(tmpl,2bp);
  begingroup
    interim labeloffset:=2bp;
    label.top(thTEX("\size[20]" & decimal (l) & "\thinspace " & txt),origin);
  endgroup
enddef;



More information about the Therion mailing list