comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Write Text
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Write Text [message #8378] Fri, 28 February 1997 00:00
Stefan Schor is currently offline  Stefan Schor
Messages: 5
Registered: August 1996
Junior Member
Hallo,

is there someone who can tell me, how I can write a Text inside a
circle ? (align to the border - so the text is distorted)
(like Audio-CDs)

Ciao... (thanks)
Re: Write Text [message #8380 is a reply to message #8378] Fri, 28 February 1997 00:00 Go to previous message
Tim Patterson is currently offline  Tim Patterson
Messages: 65
Registered: October 1995
Member
Stefan Schor wrote:
>
> Hallo,
>
> is there someone who can tell me, how I can write a Text inside a
> circle ? (align to the border - so the text is distorted)
> (like Audio-CDs)
>
> Ciao... (thanks)

Hmmm.. right off the top of my head, I can think of two
hacks that might work. Really depends on exactly how you
are going to use them.

(1) Split the phrase into separate letters and use
the XYOUTS procedure to write each letter at a particular
point around a circle. This doesn't distort the text though!

(2) Using the z buffer, write your text out to a plot,
use TVRD to get that part of the plot, and then warp it
using the POLYWARP function and paste it to your main plot
with TV.

I guess your text will be different each time you do this
warp. If not, I'd just make up a gif using a painting
package that performs this sort of function, and just read that
in and TV it to where you need it.

Unless somebody has a better solution... :)

Tim
Re: Write Text [message #8383 is a reply to message #8378] Fri, 28 February 1997 00:00 Go to previous message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Stefan Schor <spion@dose.test.de> writes:

> is there someone who can tell me, how I can write a Text inside a
> circle ? (align to the border - so the text is distorted)
> (like Audio-CDs)

I don't have *any* time for this today... :-)

But it will look *something* like this:

*******************************
FUNCTION CIRCLE, xcenter, ycenter, radius
points = (2 * !PI / 119.0) * FINDGEN(120)
x = xcenter + radius * COS(points )
y = ycenter + radius * SIN(points )
retValue = TRANSPOSE([[x],[y]])
RETURN, retValue
END

points = Circle(100, 100, 50)
FOR j=0, 119, 10 DO $
XYOutS, points(0,j), points(1,j), String(j/10), $
/Device, Alignment=1.0, Orientation=30*j/10
END
****************************************

Cheers!

David

-----------------------------------------------------------
David Fanning, Ph.D.
Fanning Software Consulting
2642 Bradbury Court, Fort Collins, CO 80521
Phone: 970-221-0438 Fax: 970-221-4762
E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com
-----------------------------------------------------------
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Printing array on one line
Next Topic: 3.0 help system

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 18:41:06 PDT 2025

Total time taken to generate the page: 0.00549 seconds