From ripley at stats.ox.ac.uk  Sun Jan 25 08:06:25 2009
From: ripley at stats.ox.ac.uk (Prof Brian Ripley)
Date: Sun, 25 Jan 2009 07:06:25 +0000 (GMT)
Subject: [Rd] Automatic shortening of text to fit into area
In-Reply-To: <05F24935-EBEE-432C-83C9-E2BF2717878E@uwaterloo.ca>
References: <05F24935-EBEE-432C-83C9-E2BF2717878E@uwaterloo.ca>
Message-ID: <alpine.OSX.1.00.0901250659070.32948@tystie.local>

Almost all devices do support clipping, so this is  rather a minority 
interest.

The person who AFAIK worte that comment and designed the clipping in 
the engine is Paul Murrell.  He has been on summer vacation, but it 
looks like he has just returned.  I suggest contacting him directly if 
he does nto respond to these postings.

On Sat, 24 Jan 2009, Sebastian Fischmeister wrote:

> Hello,
>
> A comment in engine.c states: "/* don't draw anything; this could be made 
> less crude :) */". The following patch makes it less crude: If the device 
> doesn't support clipping and the text doesn't fit into the area, then remove 
> one character after another from the text until either the text fits or the 
> string is empty.
>
> I attached the patch?it's not indented correctly to keep the patch size 
> small?and a test script, so you can give it a try. I don't know the R core 
> very well, so this change may need some discussion. Yet it works for my 
> figures.
>
> Have fun,
> Sebastian
>

-- 
Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595


[Rd] Automatic shortening of text to fit into area
Prof Brian Ripley