Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
cgwindow and output file name
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  6 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Mats Löfdahl  
View profile  
 More options Jul 11 2012, 7:53 am
Newsgroups: comp.lang.idl-pvwave
From: Mats Löfdahl <mats.lofd...@gmail.com>
Date: Wed, 11 Jul 2012 04:53:39 -0700 (PDT)
Local: Wed, Jul 11 2012 7:53 am
Subject: cgwindow and output file name
When you use the "Save Window As" functionality in a cgwindow, the default file name is cgwindow.EXT in the current directory, where EXT depends on the format you want.

If you want another file name you can seklect an existing file name or type in a new name in the popup dialogue. This becomes a bit tedious (and error prone) if you have to do it a lot. I've been looking for a way to specify the file name when creating the window but I can't find anything.

Is there a way to do it?


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Mats Löfdahl  
View profile  
 More options Jul 11 2012, 8:09 am
Newsgroups: comp.lang.idl-pvwave
From: Mats Löfdahl <mats.lofd...@gmail.com>
Date: Wed, 11 Jul 2012 05:09:43 -0700 (PDT)
Local: Wed, Jul 11 2012 8:09 am
Subject: Re: cgwindow and output file name
Den onsdagen den 11:e juli 2012 kl. 13:53:39 UTC+2 skrev Mats Löfdahl:

> When you use the "Save Window As" functionality in a cgwindow, the default file name is cgwindow.EXT in the current directory, where EXT depends on the format you want.

> If you want another file name you can select an existing file name or type in a new name in the popup dialogue. This becomes a bit tedious (and error prone) if you have to do it a lot. I've been looking for a way to specify the file name when creating the window but I can't find anything.

> Is there a way to do it?

I am aware of the output keyword to the cg plot commands, but they output directly. This is not what I'm looking for, I just want the default file name to be the one you specify, when you choose to use save your graphics (consisting of several commands) to a file.

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
David Fanning  
View profile  
 More options Jul 11 2012, 9:43 am
Newsgroups: comp.lang.idl-pvwave
From: David Fanning <n...@idlcoyote.com>
Date: Wed, 11 Jul 2012 07:43:55 -0600
Local: Wed, Jul 11 2012 9:43 am
Subject: Re: cgwindow and output file name

Mats Löfdahl writes:
> When you use the "Save Window As" functionality in a
> cgwindow, the default file name is cgwindow.EXT in
> the current directory, where EXT depends on the format you want.

> If you want another file name you can seklect an
> existing file name or type in a new name in the popup
> dialogue. This becomes a bit tedious (and error prone)
> if you have to do it a lot. I've been looking for a
> way to specify the file name when creating the window >
> but I can't find anything.

> Is there a way to do it?

There are not too many things you can do when
you are working with an interactive program. I
could, of course, give you a place to write the
filename you want, but that is nearly as tedious
as, well, writing it the way you are doing it now. :-)

Still, you do have this control already, because
it is possible to ask cgWindow to output the
contents of the window independently of the window. And,
of course, you can specify the name of the output
file when you do so:

    cgControl, OUTPUT='whateveryoulike.png'

I do store the name of the *last* file you interacted with
with cgPickfile (presumably, in this case, the last file
you wrote if you are only working with one window at a time)
and I could retrieve the basename of that file and use it.
There will be errors from time to time if you are using
cgPickfile for other things.

I could also (but this is a LOT more work and I have
a full-time job now) allow you to suggest a name for
the output file and use that. That may, in time, become
just as tedious as the current solution, and it is
certain to complicate the code a great deal. It doesn't
immediately jump out at me as the "right thing to do".

In this case, I don't see a clear way forward. I wonder
if anyone else has a good idea?

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
David Fanning  
View profile  
 More options Jul 11 2012, 10:44 am
Newsgroups: comp.lang.idl-pvwave
From: David Fanning <n...@idlcoyote.com>
Date: Wed, 11 Jul 2012 08:44:09 -0600
Local: Wed, Jul 11 2012 10:44 am
Subject: Re: cgwindow and output file name

David Fanning writes:
> In this case, I don't see a clear way forward. I wonder
> if anyone else has a good idea?

OK, a little coffee helped.

Here is what I have done. I now save the root name and
output directory of the last file you have output in
cgWindow. All subsequent output commands construct
their default filename from the *last* filename output.
This will keep you in the same output directory and
make it easier to choose your own names.

You can find the updated program here:

   http://www.idlcoyote.com/programs/cgcmdwindow__define.pro

Let me know what you think.

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
David Fanning  
View profile  
 More options Jul 11 2012, 10:48 am
Newsgroups: comp.lang.idl-pvwave
From: David Fanning <n...@idlcoyote.com>
Date: Wed, 11 Jul 2012 08:48:58 -0600
Local: Wed, Jul 11 2012 10:48 am
Subject: Re: cgwindow and output file name

David Fanning writes:
> You can find the updated program here:

>    http://www.idlcoyote.com/programs/cgcmdwindow__define.pro

I guess I should mention that you will need a version of
the Coyote Library that split off cgWindow from
cgCmdWindow to make this work. In other words, get the
latest version of the Coyote Library, always!!

  http://www.idlcoyote.com/programs/zip_files/coyoteprograms.zip

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Mats Löfdahl  
View profile  
 More options Jul 11 2012, 11:33 am
Newsgroups: comp.lang.idl-pvwave
From: Mats Löfdahl <mats.lofd...@gmail.com>
Date: Wed, 11 Jul 2012 08:33:18 -0700 (PDT)
Local: Wed, Jul 11 2012 11:33 am
Subject: Re: cgwindow and output file name
Den onsdagen den 11:e juli 2012 kl. 15:43:55 UTC+2 skrev David Fanning:

The changes you did to cgcmdwindow__define.pro (your later posts) are probably useful too, but cgcontrol solved my problem. Thanks so much!

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »