Re: size and autoSize in TextControl

Hi Sylvain,

Don has answered your question, so I'll just add that
I would be solve your problem with a CellImpl. I'd
assume that text Strings, character angles, offsets
and scale factors are in some Data object or set of
Data objects. I'd construct a DataReferenceImpl for
each of these 'input' Data objects, each triggering
the CellImpl (i.e., passed to its addReference()
method). The CellImpl would contruct an 'output' Data
object that would be rendered as you like, plus it
would call PlotText.render_label() and/or
PlotText.render_font() to construct VisADGeometryArrays
and pass them to the setShape() methods of one or more
ShapeControls (for RealTypes mapped to Shape).
Alternatively, the CellImpl might be able to do it with
ScalarMaps to Text, and TextControls.

Good luck,
Bill

On Wed, 2 Jul 2003, Letourneau, Sylvain wrote:

> I'm trying to extend the functionalities of VisAD with respect to text
> rendering.  In particular, I want to be able to:
> a) specify the angle at which each character of text is rotated with respect
> to the baseline of the text string
> b) specify an offset (x, y, z) to adjust the beginning of the string
> c) specify a scaling factor to adjust the size of the characters
>
> I'm also building a GUI interface to specify these arguments and select the
> desired font.
>
> I've 2 questions with respect to c) above. First, it appears to me that the
> variable named "size" in TextControl is used to perform scaling but I'm not
> sure.  I would appreciate if someone could confirm this.  Second, I would
> like to know what is the meaning of the variable "autoSize" in TextControl
> and its relation to "size", if any.
>
> Thanks,
> Sylvain
>
>                                       Sylvain Létourneau
>               Tel/tél: 613 990-1178 | Facsimile/télécopieur: 613-952-0215
>                           sylvain.letourneau@xxxxxxxxxxxxxx
>                               http://iit-iti.nrc-cnrc.gc.ca
>
> Research Officer                                      Agent de Recherche
> Integrated Reasoning                          Raisonnement Intégré
> Institute for Information Technology  Institut de technologie de
> l`information
> National Research Council                     Conseil national de
> recherches Canada
> M-50, 1200 Montreal Road                      M-50, 1200, chemin Montréal
> Ottawa, Ontario K1A 0R6                               Ottawa, Ontario K1A 0R6
>               Government of Canada | Gouvernement du Canada
>                               http://www.nrc-cnrc.gc.ca
>
>
>


  • 2003 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the visad archives: