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

Home » Public Forums » archive » call to X device opens window
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
call to X device opens window [message #50742] Thu, 19 October 2006 03:49 Go to next message
Bringfried Stecklum is currently offline  Bringfried Stecklum
Messages: 75
Registered: January 1996
Member
Just a quick question related to the X device. I am just wondering why
device,set_font='AnyFontYouLike' opens a window if none are open while,
e.g. device,deco=0 does not do it?

regards,

Bringfried Stecklum
  • Attachment: stecklum.vcf
    (Size: 0.20KB, Downloaded 73 times)
Re: call to X device opens window [message #50972 is a reply to message #50742] Wed, 25 October 2006 17:23 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Bringfried Stecklum writes:

> Just a quick question related to the X device. I am just wondering why
> device,set_font='AnyFontYouLike' opens a window if none are open while,
> e.g. device,deco=0 does not do it?

Of course, you don't have to see this window
open on your display, I don't think. I think
a pixmap window works just as well.

thisWindow = !D.Window
Window, /Free, /pixmap, XSize=10, YSize=10
Device, Set_Font='AnyFont'
WDelete, !D.Window
IF thisWindow GE 0 THEN WSet, thisWindow

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
Re: call to X device opens window [message #50973 is a reply to message #50742] Wed, 25 October 2006 17:20 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Sven Geier writes:

> This guess is informed more by my knowledge of X than IDL, though, so
> there's no guarantees...

I think that about nails it.

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
Re: call to X device opens window [message #50975 is a reply to message #50742] Wed, 25 October 2006 17:02 Go to previous message
Sven Geier is currently offline  Sven Geier
Messages: 17
Registered: July 2002
Junior Member
Bringfried Stecklum wrote:

> Just a quick question related to the X device. I am just wondering why
> device,set_font='AnyFontYouLike' opens a window if none are open while,
> e.g. device,deco=0 does not do it?
>

1) The correct answer: Who knows why something in IDL works the way it
works...

2) The "best guess": device,/deco doesn't really do anything to the device -
it merely tells IDL how to treat that device (i.e. how to handle color). It
can be executed whether the device actually exists or not, as long as
you're not actually plotting anything. While set_font needs to make sure
whatever font you selected actually exists which means it needs to actually
talk to the X-server (of Xfs, really, I suppose): Because the X-server
could have different fonts available for different screens (different
resolutions etc) there needs to be an actual drawable with an
actually-existing resolution, color-depth etc before you can talk
about "fonts".

This guess is informed more by my knowledge of X than IDL, though, so
there's no guarantees...

-S

--
http://www.sgeier.net
My real email address does not contain any "Z"s.
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: !P.SYMSIZE still broken? after 5 years?
Next Topic: Suggestions for tips

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

Current Time: Wed Oct 08 19:30:00 PDT 2025

Total time taken to generate the page: 0.00649 seconds