saving as raw without filename extension

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

saving as raw without filename extension

jvander
Since upgrading my Mac from 10.5 to 10.6 I have a minor issue with saving raw files.  When I implement File -> save as -> raw data,   I automatically get ".raw" added to my filename when I look at in the finder.  I do not want this extension and do not want to have to manually remove it each time.  Apple discussions have not proved any help.

Is there a way to adjust settings in ImageJ to stop this?  I looked at input output preferences and saw no solution there.

(I'm pretty sure this is linked to the OS upgrade but I guess it could be a coincidence).

thanks

Joe vanderGracht

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html
Reply | Threaded
Open this post in threaded view
|

Re: saving as raw without filename extension

ctrueden
Hi Joe,

You can partially work around this issue by turning on the "Use
JFileChooser to open/save" option in the Edit > Options > Input/Output...
options. This avoids the forced Apple file extension behavior of AWT
FileDialogs.

However, ImageJ will still append the default file extension if you do not
specify one (relevant code at
https://github.com/fiji/ImageJA/blob/5f6b5c14/src/main/java/ij/io/SaveDialog.java#L130).
One workaround is to append a period to your filename (e.g., "raw." instead
of "raw") to fool ImageJ into thinking the file has an extension. But then
of course your file will end with a period character.

Regards,
Curtis


On Wed, Oct 3, 2012 at 1:48 PM, Joe Vandergracht <[hidden email]>wrote:

> Since upgrading my Mac from 10.5 to 10.6 I have a minor issue with saving
> raw files.  When I implement File -> save as -> raw data,   I automatically
> get ".raw" added to my filename when I look at in the finder.  I do not
> want this extension and do not want to have to manually remove it each
> time.  Apple discussions have not proved any help.
>
> Is there a way to adjust settings in ImageJ to stop this?  I looked at
> input output preferences and saw no solution there.
>
> (I'm pretty sure this is linked to the OS upgrade but I guess it could be
> a coincidence).
>
> thanks
>
> Joe vanderGracht
>
> --
> ImageJ mailing list: http://imagej.nih.gov/ij/list.html
>

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html
Reply | Threaded
Open this post in threaded view
|

Re: saving as raw without filename extension

jvander
In reply to this post by jvander
Thank you Curtis.  This completely solved my problem as I do indeed append my own extension name.  In my case they are square headerless images so I just name them filename.128 in the case of a 128 by 128 image.

I had never explored JFileChooser.  Thanks for the tip.

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html