WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: DirWin beta - tiny file manager  (Read 20225 times)

Offline MikeLockmoore

  • Hero Member
  • *****
  • Posts: 525
  • Good software needn't be big!
Re: DirWin beta - tiny file manager
« Reply #30 on: July 04, 2011, 12:47:56 PM »
New version 0.7.4 is now available.  This version:
   Fixes a few segfault crashes
   Uses environ. var to hold selected file items for commands
   Has a "Usage" button if you want to see disk space used by selected files/directories
   Retains selections after more commands
   Esc key unselects items if the file list has keyboard focus

I'll submit the extension for publication too.  The size is very close to the same.
« Last Edit: July 04, 2011, 12:53:58 PM by MikeLockmoore »

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: DirWin beta - tiny file manager
« Reply #31 on: July 04, 2011, 02:48:02 PM »
That is what I did.  It does not work.

Offline Jason W

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 9730
Re: DirWin beta - tiny file manager
« Reply #32 on: July 04, 2011, 04:45:42 PM »
New version uploaded to the repo.

As mentioned, I noticed the same behavior as gerald_clark when trying to navigate directories.  The new version with it's optional "Usage" button allows navigation with the limited testing I have done so far on my machine.

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: DirWin beta - tiny file manager
« Reply #33 on: July 04, 2011, 08:53:03 PM »
Much better.
Thanks.

Offline MikeLockmoore

  • Hero Member
  • *****
  • Posts: 525
  • Good software needn't be big!
Re: DirWin beta - tiny file manager
« Reply #34 on: July 05, 2011, 08:01:01 AM »
@gerald_clark:  Hmm, It worked OK in most versions, but it seems the first version I posted to this forum and the repository had that bug.  I have not done anything specific to fix it, but I guess I undid something that caused it.  Let me know if it comes back in any form.

All: I noticed on a second PC that the "Usage" button is placed a few pixels too low, so that it overlaps slightly the file list area.  I'll come up with a better placement in the next release.  Maybe make it a bit smaller.
 

Offline SamK

  • Hero Member
  • *****
  • Posts: 713
Re: DirWin beta - tiny file manager
« Reply #35 on: July 05, 2011, 11:52:40 AM »
All: I noticed on a second PC that the "Usage" button is placed a few pixels too low, so that it overlaps slightly the file list area.  I'll come up with a better placement in the next release.  Maybe make it a bit smaller.
I was in the process of creating a screen-shot to report this when this was posted.  Screenshots are available for the following also if they will help visualize the matters.

Additionally for Usage Button
  • In a maximized view the button changes height and horizontal location
  • Returning to a window view the button changes back to the original height but at a different horizontal location than the original
  • It is a useful addition to display the number of files and the total size.  Might the "Usage?" button be removed and the functionality retained within the "Menu" button.  This will preserve the minimalistic, uncluttered, DirWin interface (in my view one of its most appealing features).

Column Widths
Might it be possible to reduce the width of the Type, Size, and Date columns and reallocate the space to the File column?  This will help to avoid truncation of long file names.

Spaces in Names
Two Directories, "DummyDir1" and "Dummy Dir 1" and their contents are identical apart from the spaces in directory and file names.  Selecting either a file or dir not containing a space "Usage?" reports correctly.  The same operation including a space reports "1 item occupying 0 KB"
   

Offline MikeLockmoore

  • Hero Member
  • *****
  • Posts: 525
  • Good software needn't be big!
Re: DirWin beta - tiny file manager
« Reply #36 on: July 05, 2011, 03:45:06 PM »
@SamK:

Thanks for issue report and suggestions.  I'll think about them.  Taking the Usage? button away may be acceptable.  Another thought I had was to make the button borderless and change the label to a fairly unobtrusive "...".  But that's assuming I can figure out the dynamic placement in various WM fonts and window sizes.  The date column is fairly tight already, but maybe I could allocate a little smaller portion to the size and type columns.

The issue about the spaces is probably due to a lack of quoting in the command string... hopefully easy to fix.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11618
Re: DirWin beta - tiny file manager
« Reply #37 on: July 06, 2011, 04:08:35 AM »
Hi SamK
Quote
Spaces in Names
Two Directories, "DummyDir1" and "Dummy Dir 1" and their contents are identical apart from the spaces in directory and file names.  Selecting either a file or dir not containing a space "Usage?" reports correctly.  The same operation including a space reports "1 item occupying 0 KB"
Spaces in file and directory names are frequently problematic. They are often used as a field separator
and can wreak havoc in scripts that are not written to deal with them. There are some cases where
the space gets replaced with the octal escape sequence \040. For instance, if you create a mount
point with a space in it and mount something to it, the file /proc/mounts will contain \040 where the
space used to be. This is done so that the fields in that file can still be parsed correctly. As a result you
can no longer do a simple string compare on the mount point if you want to search for it. The best way
to avoid potential problems with names is to stick to A-Z, a-z, 0-9, ., _, and -. In particular, avoid things
like space, ?, *, $, and \. I'm sure there a few I missed.

Offline Lee

  • Hero Member
  • *****
  • Posts: 645
    • My Core wiki user page
Re: DirWin beta - tiny file manager
« Reply #38 on: July 06, 2011, 02:40:50 PM »
It is particularly annoying when a delete or backspace character sneaks into a file name.

I don't get this on tc but sometimes on SCO or HPUX - probably due to a misconfigured terminal program.

And I seem to recall ampersand causes problems, too.

32 bit core4.7.7, Xprogs, Xorg-7.6, wbar, jwm  |  - Testing -
PPR, data persistence through filetool.sh          |  32 bit core 8.0 alpha 1
USB Flash drive, one partition, ext2, grub4dos  | Otherwise similar

Offline TheNewbie

  • Newbie
  • *
  • Posts: 42
Re: DirWin beta - tiny file manager
« Reply #39 on: July 12, 2011, 03:50:16 PM »
The Usage button is just weirdly bugged, from my experience so far. For directories (when nothing is selected), it often says there is nothing (i.e. "This directory occupies 0KB"), and there are no weird characters in the path.

- I'm not sure if it's already intended to work like this, but a directory's disk usage should be calculated "deeply" (i.e. all subfolders under it). When it doesn't say 0KB, it seems to measure a directory only in files directly contained one level below it, or just the space required for a folder to exist.

- The alphabetical ordering seems to place capitals before lowercase (ex. 'O' comes before 'a').

- When right-clicking inside DirWin, the menu pops up, regardless of whether or not DirWin is on the top layer of the desktop. That is, the menu suddenly appears on top, but the DirWin window remains partially obscured, so it looks like the menu is coming out of a different window.

Offline MikeLockmoore

  • Hero Member
  • *****
  • Posts: 525
  • Good software needn't be big!
Re: DirWin beta - tiny file manager
« Reply #40 on: July 12, 2011, 05:25:59 PM »
@TheNewbie: Thanks for taking the time to post your issues.  I plan to take the Usage button away, but keep the menu command, but it would only be presented in the menu if you select something.  So if you want to see the usage of an entire directory, you would need to navigate up to the parent and select the intended directory there.  Then the "du -ck ..." command would be able to report the full usage.  I'm not sure why you don't get the "deep" usage... I thought I got the "deep" usage reported for my filesystems, but I'll double-check.

I'll think about the right-click behavior.  The current implementation was a "cheap" (i.e. small) way to get a context-sensitive menu without the overhead of managing a separate popup menu object in the code (since the menu button already had one).  Maybe I can come up with a friendlier behavior and still stay small.

@Rich, @Lee: Yes, there are many potential pitfalls with weird characters in filenames and directory names.  Since I exeucte some command-line functions in DirWin, I sometimes need to surround the names with quotation marks.  But my latest version of DirWin also uses an environment variable ($sel_items) to make the command line more compact and editable... and making the environment variable expansion and command-line quoting work consistently has been challenging.  Not to mention that to properly handle all allowed names, I'd need to escape instances of the quote character that are embedded in the actual name.   This gets messy, and is a reason that practical code is sometimes bigger than I'd like to see.
« Last Edit: July 12, 2011, 05:29:41 PM by MikeLockmoore »

Offline TheNewbie

  • Newbie
  • *
  • Posts: 42
Re: DirWin beta - tiny file manager
« Reply #41 on: July 12, 2011, 10:42:27 PM »
Well, the right-click feature using the main menu is fine for me. It's just that weird bug that causes the menu to pop out on top *of all windows*; for instance, if I'm running a browser and part of the DirWin window is covered by it, and I right-click on the DirWin window, the menu pops out on top of the browser, but the DirWin window itself does not come with it, so the DirWin menu looks like it's coming out of the browser. Sorry if that wasn't clear.

Offline MikeLockmoore

  • Hero Member
  • *****
  • Posts: 525
  • Good software needn't be big!
Re: DirWin beta - tiny file manager
« Reply #42 on: July 13, 2011, 09:34:33 AM »
@TheNewbie:  The original description made sense... I've just not investigated it yet to see if my environment behaves the same way.  If so, perhaps I can get DirWin to pop up to become the top window if the user right-clicks.

Offline SunBurnt

  • Full Member
  • ***
  • Posts: 102
Re: DirWin beta - tiny file manager
« Reply #43 on: August 07, 2011, 10:23:42 PM »
I posted this as a suggestion for Fluff also.
None of these features should take much room.

# All of this is best done in a right-click context menu.
1) Mount and unmount, drive partitions and loop mount files.
2) Compress and extract archive type files.
3) Set file extension associations for the file.
4) Cut, Copy, and Paste on the context menu.

Someone also suggested ftp, shouldn`t take much room either.

Offline MikeLockmoore

  • Hero Member
  • *****
  • Posts: 525
  • Good software needn't be big!
Re: DirWin beta - tiny file manager
« Reply #44 on: August 09, 2011, 02:16:40 PM »
SunBurnt:  Again, thanks for your interest.  Please see my comments in the Fluff posting, but remember that for DirWin I am trying to be extremely lean.  If a new feature takes 10KB of new code, it is maybe tolerable in Fluff, but probably not in DirWin.