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

Home » Public Forums » archive » Re: Different Platforms
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Different Platforms [message #10342 is a reply to message #10333] Wed, 19 November 1997 00:00 Go to previous message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Neil Winrow (ncw@dl.ac.uk) writes:

> I have written a number of widget programs, which are visually correct
> on my PC, however when they are run on the silicon graphics machines the
> layout starts to go terribly wrong. The character sizes are wrong, and
> the labelling carried out using the 'XYOUTS' call is all wrong. The
> whole window sizing falls down. The programs are going to be used on
> PC's, silicon graphics, and MAC's. Could anyone offer me a few pointers
> on how to correct these problems to run the programs on the different
> platforms.

There is nothing quite like trying to get IDL widget programs
to run on PCs, SGIs and Macs to get you to question your
sanity. And, of course, as soon as you have it figured out,
someone buys a Sun and then you have to deal with *those*
tinsy-tiny 12-point fonts. You soon realize that "font size"
must be one of those words like "true love" that is open to
all kinds of interpretation.

I once got so frustrated I took a survey of the 10 best
IDL widget programmers I knew. "How do you size strings
in your widget programs?", I asked. Would you believe I
got 10 completely different answers and that almost
every single answer had more to do with occult
science than with computer science? I wouldn't
be able to withstand the public ridicule if I
published the answers here.

SGIs seem to be the worst. I don't know why. They
have HUGE default fonts. Liam Gumley, who should know,
suggests you try something like this in your SGI start-up
file:

Device, Set_Character_Size = [ 6, 9 ]
Widget_Control, Default_Font = '7x13'

I have had fairly good success with a program named
STR_SIZE that you can get from my web page. It calculates
the proper character size to get a target string to be
be a particular size (in normalized coordinates)
in the output window. But this means setting the
CharSize keyword on all graphics output commands.
(Not a bad idea when you are writing what you hope will
be portable IDL applications, by the way. Then, at least,
if your programs look lousy on some person's system they
can change the CharSize parameter, which I usually have
as a keyword to the main program.)

I've had pretty good luck with something like this:

rightSize = Str_Size('This is a default string', 0.25)
Plot, data, CharSize=rightSize

Let us know what you come up with. I'll add it to the list.
It will make interesting reading 100 years from now. :-)

Cheers,

David

-----------------------------------------------------------
David Fanning, Ph.D.
Fanning Software Consulting
E-Mail: davidf@dfanning.com
Phone: 970-221-0438
Coyote's Guide to IDL Programming: http://www.dfanning.com/
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: FFT-bug???? (PV-Wave) -SORRY!!
Next Topic: when will RSI come out with a scaledDown version of IDL?

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

Current Time: Fri Oct 10 09:57:54 PDT 2025

Total time taken to generate the page: 1.19932 seconds