ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: "luigi.scarso" <luigi.scarso@logosrl.it>
Subject: Re: AutoScale and AutoSize
Date: Fri, 15 Apr 2005 11:43:30 +0200	[thread overview]
Message-ID: <425F8CC2.6050100@logosrl.it> (raw)
In-Reply-To: <425F7275.6070505@logosrl.it>

% AutoSize seem better, but
% I must setup ss and tfb inside body
% (I need these) so it's no a general macros
% Same problems of previous version.
%
\def\AutoSize#1#2#3{% #1=string #2=horiz.limit #3=startfont
\newdimen\Limit \Limit=#2 %
\newdimen\FontSize \FontSize=#3 %
\doloop{%
\setbox800=\hbox{\switchtobodyfont[ss,\the\FontSize]\tfb #1}%
\ifdim\wd800 <\Limit\exitloop%
\else%
\ifdim\FontSize <1bp\exitloop%
\else %
\advance\FontSize by -0.5bp%
\fi%
\fi}%
\box800\relax%
}

  parent reply	other threads:[~2005-04-15  9:43 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-04-15  6:54 justification Jörg Hagmann
2005-04-15  7:35 ` justification luigi.scarso
2005-04-15  9:32   ` justification Jörg Hagmann
2005-04-18 15:52     ` justification Peter Münster
2005-04-15  7:51 ` AutoScale and AutoSize luigi.scarso
2005-04-15  9:26   ` Hans Hagen
2005-04-15 12:07     ` luigi.scarso
2005-04-15 13:35       ` Hans Hagen
2005-04-15 14:06         ` luigi.scarso
2005-04-15 21:38           ` Hans Hagen
2005-04-18  7:12             ` Strange link on pragma site ? luigi.scarso
2005-04-15  9:43   ` luigi.scarso [this message]
2005-04-15  9:17 ` justification Hans Hagen
2005-04-15 10:20   ` justification Jörg Hagmann
2005-04-15 21:35     ` justification Hans Hagen
2005-04-15 14:31   ` justification Jörg Hagmann
2005-04-16  7:42   ` Hyphenation-paterns was:Re: justification Willi Egger
2005-04-15 20:12 ` justification Willi Egger
2005-04-16 10:50   ` justification Henning Hraban Ramm
2005-04-18 12:48     ` justification Jörg Hagmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=425F8CC2.6050100@logosrl.it \
    --to=luigi.scarso@logosrl.it \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).