Drag and drop hints

Saving using drag-and-drop

Each application's savebox contains an icon representing the file to save. You can drag this icon to a ROX-Filer window, a directory on a pinboard or panel, or to another application. For example, if you want to save a compressed text file, drag from Edit's savebox onto Archive, and then drag the compressed data to a filer window to actually save it.


Download Handler

With ROX-Filer, you can select which program you want to use to download resources (images, software, data, etc). This is used when you drag a link from a web browser into a filer window, for example.

To change the download handler program, open the "Options"-dialog of ROX-Filer and select the "Drag and Drop"-tab.

Hint: if you want downloads over SSL (https) to work, you should try curl instead of wget; it is generally a better choice

ROX applications designed to be used as Download Handlers include:

  • ROXget
  • Fetch
  • DownloadManager is a companion program for newer versions of Fetch. It co-ordinates multiple instances of Fetch via DBUS to limit the number of downloads using your net connection at once.

Drag-and-drop saving with Vim

You need something like this in your ~/.vimrc file:

function! Save()
  let tmpname = tempname()
  let fname = expand('%')
  if fname == ''
    let fname = 'TextFile'
  silent exec 'write !savebox ' . fname . ' > ' . tmpname
  let newname = system('cat ' . tmpname)
  let tmp = system('rm ' . tmpname)
  if tmpname != ''
    exec 'file ' . escape(newname, ' ')
    set nomodified
command! Save call Save()
map <F3> :Save<CR>

You'll need the savebox command from httphttp://rox.sourceforge.net/snapshots/gui_utils.tgz.
Extract the archive and run './configure && make install' as root to install savebox.
Once you have the script saved to .vimrc or .gvimrc, you can then hit F3 to
get a savebox from which you may then drag and drop to a ROX-Filer window;
updating the text within this box will change the name under which it is saved.

Keeping save boxes above other windows

Drag and drop saving is great, but can I keep the save box above all other windows while I'm using the filer?

All saveboxes (including the Copy/Rename/Link saveboxes in the filer) are
marked with the 'Savebox' class so your window manager can recognise them.
For example, sawfish users should choose 'Customise->Matched Windows' and
add a new rule. The matcher should be 'Class' and you can use Grab to copy
the value by clicking on any savebox. Set 'Depth' to a high number to keep it
above other windows.
Users of OroboROX, which on its own doesn't have an interface for this, may find httpDevil's Pie to be useful. You'll need to manually create the /.devilspie.xml file and the add something like (I hope):

 <flurb name="Savebox on top">
   <matcher name="DevilsPieMatcherWindowName">
    <property name="class_name" value="Savebox" />
   <action name="DevilsPieActionLayer">
    <property name="above" value="TRUE"/>