Hdfview-2.7 possible bug

Hi,
If I go to Tools -> User Options and check the "Current Working Directory"
check box in the Default Working Directory section under the General Setting
tab in hdfview 2.7 the change is not sticky and never gets made. Instead,
when I open up hdfview the next time, the box is unchecked and the Default
Working Directory is reset to the install location. I examined the
~/.hdfview file and work.dir field is reset to the install directory as soon
as hdfview is closed. I see no fields in the .hdfview file pertaining to
"Current Working Directory."

Izaak Beekman

···

===================================
(301)244-9367
UMD-CP Visiting Graduate Student
Aerospace Engineering
ibeekman@umiacs.umd.edu
ibeekman@umd.edu

Izaak,

Thank you for reporting the issue. We will take a look at the problem.

Thanks
--pc

···

On 10/7/2011 9:15 AM, Izaak Beekman wrote:

Hi,
If I go to Tools -> User Options and check the "Current Working Directory" check box in the Default Working Directory section under the General Setting tab in hdfview 2.7 the change is not sticky and never gets made. Instead, when I open up hdfview the next time, the box is unchecked and the Default Working Directory is reset to the install location. I examined the ~/.hdfview file and work.dir field is reset to the install directory as soon as hdfview is closed. I see no fields in the .hdfview file pertaining to "Current Working Directory."

Izaak Beekman

(301)244-9367
UMD-CP Visiting Graduate Student
Aerospace Engineering
ibeekman@umiacs.umd.edu <mailto:ibeekman@umiacs.umd.edu>
ibeekman@umd.edu <mailto:ibeekman@umd.edu>

_______________________________________________
Hdf-forum is for HDF software users discussion.
Hdf-forum@hdfgroup.org
http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org

Izaak,

HDFView uses what is from System.getProperty("user.dir") for "Current Working Directory" .
It seems that System.getProperty("user.dir") gives the directory where the program starts.
That is the reason that the location is always the same. The best way is to enter your own
path where you want HDFView to start to open files.

Two tentative solutions
1) No change for the current behavior, but using "Program Directory" instead of "Current
      Working Directory" for less confusing or
2) Using the directory of the latest open file in HDFView. If there is no open file, use what is
      from System.getProperty("user.dir")

We definitely would like to have your comments and suggestions.

Thanks
--pc

···

On 10/7/2011 9:15 AM, Izaak Beekman wrote:

Hi,
If I go to Tools -> User Options and check the "Current Working Directory" check box in the Default Working Directory section under the General Setting tab in hdfview 2.7 the change is not sticky and never gets made. Instead, when I open up hdfview the next time, the box is unchecked and the Default Working Directory is reset to the install location. I examined the ~/.hdfview file and work.dir field is reset to the install directory as soon as hdfview is closed. I see no fields in the .hdfview file pertaining to "Current Working Directory."

Izaak Beekman

(301)244-9367
UMD-CP Visiting Graduate Student
Aerospace Engineering
ibeekman@umiacs.umd.edu <mailto:ibeekman@umiacs.umd.edu>
ibeekman@umd.edu <mailto:ibeekman@umd.edu>

_______________________________________________
Hdf-forum is for HDF software users discussion.
Hdf-forum@hdfgroup.org
http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org

Peter,
The functionality I think would be most useful would be to be able to set
hdfview to look in the current working directory (the directory from which
hdfview was launched). Also, it would be wonderful if one could pass hdf5
files as arguments to hdfview so that the files would already be open once
in the hdfview gui, rather than wading through menus, and clicking through
the directory to find the file one is looking for.

By the way, the recent files functionality is a GREAT feature in hdfview.
Many thanks to all those who work on HDF5 and the various tools like
hdfview.

Izaak Beekman

···

===================================
(301)244-9367
Princeton University Doctoral Candidate
Mechanical and Aerospace Engineering
ibeekman@princeton.edu

UMD-CP Visiting Graduate Student
Aerospace Engineering
ibeekman@umiacs.umd.edu
ibeekman@umd.edu

On Sat, Oct 8, 2011 at 12:00 PM, <hdf-forum-request@hdfgroup.org> wrote:

Re: [Hdf-forum] hdfview-2.7 possible bug

Zaak Beekman wrote:

The functionality I think would be most useful would be to be
able to set hdfview to look in the current working directory (the
directory from which hdfview was launched). Also, it would be wonderful
if one could pass hdf5 files as arguments to hdfview so that the files
would already be open once in the hdfview gui, rather than wading
through menus, and clicking through the directory to find the file one
is looking for.

Zaak,

On my linux box, with hdfview 2.7, I just type:

hdfview ModifyTest.h5

on the command line and hdfview starts with that file open. It will
even handle multiple files. Isn’t that what you are looking for?
Also, you can just copy and paste path strings into the “file text
box”, or whatever it is called, at the top of the window. If the path
includes the file that file is open. If it doesn’t than a dialog to
that directory is opened.

Aren’t these features what you’re requesting in your second sentence
above?

By the way, on linux and probably other OS’s there is a readlink -f
command which I’ve found to be very useful for generating the full path
to be copied and pasted into hdfview.

Cheers,

–dan

···
-- Daniel Kahn
Science Systems and Applications Inc.
301-867-2162

Hi Izaak,

Peter,
The functionality I think would be most useful would be to be able to set hdfview to look in the current working directory (the directory from which hdfview was launched). Also, it would be wonderful if one could pass hdf5 files as arguments to hdfview so that the files would already be open once in the hdfview gui, rather than wading through menus, and clicking through the directory to find the file one is looking for.

As Daniel Kahn pointed out, you should be able to open file from command line. Also after you open any file,
hdfview will use the directory of the latest open file.

If you don't specify any file when you start hdfview, it will look for the property from "user.dir". Currently
we use the definition of "user.dir" from JVM.

By the way, the recent files functionality is a GREAT feature in hdfview. Many thanks to all those who work on HDF5 and the various tools like hdfview.

You are welcome. We wan to thank you for reporting the issues.

--pc

···

On 10/9/2011 9:00 AM, Zaak Beekman wrote:

Izaak Beekman

(301)244-9367
Princeton University Doctoral Candidate
Mechanical and Aerospace Engineering
ibeekman@princeton.edu <mailto:ibeekman@princeton.edu>

UMD-CP Visiting Graduate Student
Aerospace Engineering
ibeekman@umiacs.umd.edu <mailto:ibeekman@umiacs.umd.edu>
ibeekman@umd.edu <mailto:ibeekman@umd.edu>

On Sat, Oct 8, 2011 at 12:00 PM, <hdf-forum-request@hdfgroup.org > <mailto:hdf-forum-request@hdfgroup.org>> wrote:

    Re: [Hdf-forum] hdfview-2.7 possible bug

_______________________________________________
Hdf-forum is for HDF software users discussion.
Hdf-forum@hdfgroup.org
http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org

Dan,
Thanks for the reply. On my RHEL 5 x86_64 workstation if I type:

hdfview MyHDF5file.h5

hdfview opens, but not with my file loaded. Perhaps there is something
strange with how I am placing hdfview on my PATH, or with how my filesystem
is behaving. I have instealled hdfview to a NFS directory, and then create a
link to the hdfview executable in a (NFS) directory that's already on my
path using the old *nix stow command. The files are usually in different NFS
mounted directories or lustre mounted directories.

Either way, this feature/help request is secondary to what appears to me to
be a bug: checking the "current working directory" box in the settings
appears not to produce the desired behaviour that it did in hdfview 2.6.

Izaak Beekman

···

===================================
(301)244-9367
Princeton University Doctoral Candidate
Mechanical and Aerospace Engineering
ibeekman@princeton.edu

UMD-CP Visiting Graduate Student
Aerospace Engineering
ibeekman@umiacs.umd.edu
ibeekman@umd.edu

On Mon, Oct 10, 2011 at 9:11 AM, Daniel Kahn <daniel.kahn@ssaihq.com> wrote:

**

Zaak Beekman wrote:

The functionality I think would be most useful would be to be able to set
hdfview to look in the current working directory (the directory from which
hdfview was launched). Also, it would be wonderful if one could pass hdf5
files as arguments to hdfview so that the files would already be open once
in the hdfview gui, rather than wading through menus, and clicking through
the directory to find the file one is looking for.

Zaak,

On my linux box, with hdfview 2.7, I just type:

hdfview ModifyTest.h5

on the command line and hdfview starts with that file open. It will even
handle multiple files. Isn't that what you are looking for? Also, you can
just copy and paste path strings into the "file text box", or whatever it is
called, at the top of the window. If the path includes the file that file
is open. If it doesn't than a dialog to that directory is opened.

Aren't these features what you're requesting in your second sentence above?

By the way, on linux and probably other OS's there is a *readlink -f*command which I've found to be very useful for generating the full path to
be copied and pasted into hdfview.

Cheers,
--dan

--
Daniel Kahn
Science Systems and Applications Inc.301-867-2162