MathGroup Archive 2010

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Possible bug in V8: Grid with TextCell

  • To: mathgroup at smc.vnet.net
  • Subject: [mg115091] Re: Possible bug in V8: Grid with TextCell
  • From: ADL <alberto.dilullo at tiscali.it>
  • Date: Thu, 30 Dec 2010 06:29:46 -0500 (EST)
  • References: <iff463$r6e$1@smc.vnet.net> <ifhidq$i6f$1@smc.vnet.net>

On 30 Dic, 10:12, Helen Read <read... at gmail.com> wrote:
> On 12/29/2010 5:57 AM, Carlos C=E9sar de Ara=FAjo wrote:
>
>
>
>
>
>
>
> > Please, take a look at the following image showing a cell with text and=
=
> > graphics side by side:
>
> >http://www.gregosetroianos.mat.br/Mathematica/TextGraphics.gif
>
> > Below I show the basic template involved. It used to work in V6 and V7.=
=
>  I
> > was disappointed to see that this is not the case anymore in V8 (Trial
> > version).
>
> > text = StringJoin@Table["bla, ", {180}];
>
> > textCell = TextCell[text, "Text", FontFamily ->  "Times",
> > TextJustification->1];
>
> > graphics = Framed@Graphics[{}];
>
> > Grid[{{textCell, graphics}},
> >   Alignment ->  Top]
>
> > Is it possible to achieve the older result in V8? Any workaround?
>
> I guess I'm not sure why you are putting a TextCell inside a Grid. Why
> not just put the text itself in the Grid. Or put the text in a Pane,
> which gives you better control of wrapping.
>
> text = Style[StringJoin@Table["bla, ", {180}], FontFamily -> "Times",
>     LineIndent -> 0];
>
> graphics = Framed@Graphics[{}];
>
> Grid[{{Pane[text, 300], graphics}}, Alignment -> Top]
>
> --
> Helen Read
> University of Vermont

I made some tests with Grid/Pane (v8 Windows) and discovered that Pane
is filled with bugs and the resulting image is almost never as
specified.

Just to make some examples:
- Pane[text,{w,h}] does not work as described in the help: it clips
the text instead of resizing. To resize, ImageSizeAction-
>"ResizeToFit" has to be specified
- Even after resizing, the text does not fill the specified region and
is irregularly indented on the right.
- The sizes of the image and the pane do not match, even if explicitly
set equal.

Moreover, I could not find a way to justify the text: only Left,
Center and Right alignments appear to exist.

ADL


  • Prev by Date: Re: Manually culling a list
  • Next by Date: Re: Possible bug in V8: Grid with TextCell
  • Previous by thread: Re: Possible bug in V8: Grid with TextCell
  • Next by thread: Re: Possible bug in V8: Grid with TextCell