[Previous] [Contents] [Index] [Next]

File Manager

This chapter shows you how to use the Photon File Manager to manage your files and directories. Topics include:

What is the File Manager?

The File Manager provides a simple, graphical way to maintain and organize your files. For example, it lets you go to any directories or folders-no matter where they reside in the filesystem-with a single mouse click. You can also sort, copy, move, delete, rename, or modify files simply by pressing a key or popping up a menu. You can even run QNX or Photon applications by double-clicking on their data files.

Starting the File Manager

To start the File Manager:

If the File Manager is running but hidden, you can find it by clicking on the File Manager icon in the Taskbar:

PFM Taskbar Icon

For information on using pterm, see "Opening a terminal window" in this chapter.

The File Manager at a glance

Here's a typical File Manager session:

PFM at a Glance

Here's what the main parts of the File Manager enable you to do:

Menus
Let you perform most major functions, from creating folders to configuring the File Manager.
Button bar
Lets you quickly create files, run commands, return to your home folder, update your Hotlist, and more:

File Manager buttons

Hotlist
Lets you keep track of the folders you use most often and provides quick access to them.
Note: The Hotlist shows only the folders that you've added to it, not a hierarchy of all the directories on your system.

Current path
Shows you the pathname of the current folder (in this case, //222/bedrock/fred).
File list
Shows you the contents of the current folder, and lets you select files for copying, moving, editing, and so on.

The file icons let you identify the file type:

PFM file/directory icons

The File list includes such information as the filename, size, modification date, owner, group and permissions.

Popup menus
Both the Hotlist and the File list have their own popup menus. To open them:
=>> Point anywhere in the Hotlist or File list and click the right mouse button.

The Hotlist popup lets you add folders to or remove folders from the Hotlist:

Hotlist popup Menu

The File list popup gives you quick access to many of the functions in the File menu:

Filelist popup Menu

Status bar
Shows you how many items the current folder contains or how many files you've selected. It also shows how much disk space is free.

Managing folders with the Hotlist

You can use the Hotlist to keep track of your "favorite" folders-the ones you use the most. They're kept in the order you added them in, but you can also sort them alphabetically.

Adding a folder

To add a folder to the Hotlist:

  1. Open the folder you want to add to the Hotlist (see "Opening a folder" below).
  2. Click on the Add Current Folder to Hotlist icon:

    Add Current Folder to Hotlist icon

    Or

    Point anywhere in the Hotlist, click the right mouse button, and choose Add Current to Hotlist.

The current folder is added to the bottom of the Hotlist.

Sorting the Hotlist

To put the Hotlist in alphabetical order:

=>> Click the right mouse button on one of the folders in the Hotlist, then choose Sort Root Folders.

Removing folders

To remove a folder from the Hotlist:

=>> Click the right mouse button on the folder you want to remove, then choose Remove Folder from Hotlist.

The folder is removed from the Hotlist, but isn't deleted from your system.

Opening a folder

You can open a folder from either the Hotlist or the File list, or by using the keyboard.

Using the Hotlist

To open a folder displayed in the Hotlist, using the mouse:

  1. Click on the folder. Its contents will appear in the File list.
  2. To open a "child folder" (subdirectory) of the folder you just opened, first click on the + sign to the left of the folder. The Hotlist will display the folder's child folders, if any exist.
  3. Click on the child folder you wish to open.

To open a folder displayed in the Hotlist, using the keyboard:

  1. Press Tab until a focus rectangle appears in the Hotlist.
  2. Select the folder by pressing one of the following keys:
    To select: Press:
    The previous or next folder in the list. /\ or \/
    A child folder of current folder (if any exists). -->
    The parent folder of current folder. <--
    The first or last folder in the list. Home or End
    The folder one page up or down in the list. Pg Up or Pg Dn
  3. Press Enter to open the folder.

Using the File list

To open a folder displayed in the File list, using the mouse:

=>> Double-click on the folder you want to open. Its contents will appear in the File list.

To open a folder displayed in the File list, using the keyboard:

  1. Press Tab until a focus rectangle appears in the File list.
  2. Select the folder by pressing a direction key (e.g. /\, Home, Pg Up, etc.).
  3. Press Enter, or the gray + key on the numeric keypad, to open the folder.
  4. To move back up to the parent folder, you can press Back Space, or the gray - key on the numeric keypad.

Using the keyboard

To open any folder, using the keyboard:

=>> Type its pathname in the Current path field, and press Enter.

Finding a file quickly

To find a file or folder quickly:

  1. Click anywhere inside the File list.
  2. Type the file's or folder's name, or the first few letters of its name. The File Manager will select the file that best matches the name you typed.

Once you're finished typing, the File Manager waits a period of time-by default this is 1.5 seconds-then lets you type in another name.


Note: This quick-search method searches for files in the current directory only. For this method to work, files must be sorted by filename and the Folders First option must be disabled in the Configuration dialog.

For more info, see the discussion on sorting files in "Changing how files are displayed" and the section on "Configuring the File Manager."


Selecting files

To work on any file or folder displayed in the File list, you must first select it. You can select using the mouse, the keyboard, or a menu.

Using the mouse and keyboard

To select: Do this:
A single file Click on the file.
Two or more files in any order Hold down Ctrl, click on the first file, then click on each remaining file.
A range of files (e.g. files from A to D) Hold down Shift, click on the first file in the range, then click on the last file in the range.

Using the keyboard

Selecting a single file:

To select the: Press:
Previous or next file in the list /\ or \/
First or last file in the list Home or End
First file one page up or one page down Pg Up or Pg Dn

Selecting two or more files in any order:

  1. Select the first file.
  2. Hold down Ctrl, then press a direction key (e.g. /\, Pg Dn) to "jump" to the next file you want to select.
  3. When you've reached the next file you want to select, press Space.
  4. Repeat the above two steps until you're done.

Selecting a range of files:

  1. Hold down Shift.
  2. Do one of the following:
    To select: Press:
    Additional files one at a time /\ or \/
    All the files to the beginning or the end of the list Home or End
    All the files in the next or previous page Pg Up or Pg Dn

Using a menu

To select: Do this:
All files in the current folder From the Select menu, choose Select, then choose All.
All the files that match a text pattern (e.g. all files ending with .c) From the Select menu, choose Select, then choose By Pattern, or simply press Ctrl -S , and enter the desired pattern.

Note: For examples of how to use patterns, see the section on "Controlling which files are displayed."

Deselecting files

To deselect: Do this:
A single file using the mouse Hold down Ctrl, then click on the file.
A single file using the keyboard Hold down Ctrl, press a direction key (e.g. /\) to go to the file you wish to deselect, then press Space.
All files or all files that match a text pattern From the Select menu, choose Deselect, then choose All or By Pattern.

Note: You can also deselect using other techniques similar to the techniques used for selecting files, such as pressing Shift and /\. Feel free to experiment!

Creating folders and files

Folders

To create a new folder in the current folder:

  1. From the File menu, choose the New item, then choose Folder.

    Or

    Click on the New Folder icon:

    Folder create Icon

  2. You'll see the Create New Folder dialog. Type the name of the new folder, then click on Create or press Enter.

    The new folder will appear in the File list, according to how you've sorted the list. If there are many files in the current folder, you may have to scroll to see your new folder.

You can also create a new folder within a folder that's not currently open. For example, let's say you're in /bedrock and you wish to create a dino folder under /bedrock/fred. In this case, you could type the following in the Create New Folder dialog:

fred/dino

Note that you don't have to type /bedrock, since you're already there!

If, however, you wish to create a new folder under another path, you must type the new folder's complete pathname. For example, if you're in /bedrock/fred and wish to create a letters folder under /quarry/slate, you'd type:

/quarry/slate/letters

Files

To create a new file in the current folder:

  1. From the File menu, choose the New item, then choose File.

    Or

    Click on the New File icon:

    Folder create Icon

  2. You'll see the Create New File dialog. Type the name of the new file, then click on Create or press Enter.
  3. A pterm window opens and a text editor starts in the window.

    For info on using this editor or choosing a different editor, ask your system administrator or see the section on "Configuring the File Manager."

  4. When you're finished, save the file and quit the editor. The pterm window will close and your new file will be added to the current folder.

Note: If you don't see the file, click on the Reopen Folder icon to refresh the File list. Remember that you can use the File Manager's quick-search method to locate your new file.

Creating a file in another folder

You can also create a new file within a folder that's not currently open. For example, let's say you're in /bedrock and you wish to create a file called yabadaba under /bedrock/fred. In this case, you could simply type the following in the Create New File dialog:

fred/yabadaba

Note that you don't have to type /bedrock, since you're already there!

If, however, you wish to create a new file under another path, you must type the file's complete pathname. For example, if you're in /bedrock and wish to create yabadaba under /quarry/slate, you'd type:

/quarry/slate/yabadaba

Viewing or editing files

To view a file, do one of the following:

To edit a file, do one of the following:


Note:
  • To bring up the correct popup menu, make sure the pointer is in the File list (not the Hotlist) before you click the right mouse button.
  • For info on using the viewer or editor, or on choosing a different viewer or editor, ask your system administrator or see the section on "Configuring the File Manager."

Copying and moving files

To copy or move a file:

  1. Select the file, then do one of the following:

    You'll see the Copy/Move dialog.

  2. Click on the combobox to choose from the list of folders you've already copied or moved files to, or type the pathname of the folder you're copying or moving the file to.

    For example, if you wish to move a file currently in /bedrock/fred to /quarry/slate, you'd type /quarry/slate.

  3. Click on Copy or Move.

Caution: If you try to copy or move a file from one folder to another folder, and a file with the same name exists in the target folder, the new file will overwrite the file in the target folder.

If you're copying or moving to a folder under the current folder, you don't have to type the entire pathname. For example, let's say you're in /bedrock and you wish to copy a file to the /bedrock/fred/letters folder. Instead of typing /bedrock/fred/letters, you could simply type fred/letters.

If you copy or move a file to a path that doesn't yet exist, the File Manager will, by default, create any necessary folders. For example, if you copy a file to /quarry/slate, and slate doesn't yet exist, the File Manager will create slate, then copy the file. To disable this feature, click on the "Create folders..." box in the Copy/Move dialog.

Deleting files or folders

To delete a file or a folder:

  1. Select the file or folder, then do one of the following:
  2. You'll see the Confirm File Delete dialog. If you selected a folder to delete, click on the "Include selected folders" button to confirm that you wish to delete the folder.
  3. Click on Yes or press Enter.

WARNING:
  • You can't recover a file you've deleted.
  • If you delete a folder, you'll also delete any files in that folder.

Changing file properties

You can change the properties of any file or folder, including its name, ownership, and permissions. Simply follow these steps:

  1. Select the file or folder you wish to modify, then do one of the following:
  2. Change your selected properties, then click on Done or press Enter.

Caution: If you've selected a folder, you'll be asked whether you wish to change the properties of both the folder and its contents. If you do, any changes you make will affect all folders and all files that reside under the selected folder.

For info on QNX file attributes and permissions, ask your system administrator or see the QNX OS Installation & Configuration manual.

Opening and closing a terminal window

If you wish to run text-based QNX utilities and applications from a window on your Photon workspace, you can use the File Manager to load the pterm terminal window.

To open and use a pterm window, do one of the following:

You're now in the QNX Shell, where you can invoke text-based utilities and applications as you would from a QNX terminal or console.

To log off from your session and remove the pterm window:

For more info on using and configuring pterm, see the chapter on pterm in this guide, and see the Photon Installation & Configuration guide.

Running a command

You can use the File Manager to start a Photon application or other QNX-based applications and utilities.

  1. Do one of the following:
  2. If you're starting a text application, make sure that the Run Inside Terminal button is enabled.

    If you choose "Close: Finish," the File Manager closes the terminal when the command is finished, regardless of errors. If you choose "Close: If no Error," the File Manager closes the terminal only if the command finishes without an error. If you use this option, you'll be able to read any error messages that the command displays.

  3. Type in the name of the command, or choose Browse to choose the command from the QNX filesystem.
  4. Click on Run or press Enter.

Quick-starting Photon applications

Here's another way to start a Photon application:

=>> Simply double-click on the application's executable file.

Note: The method works only with native Photon applications. If you don't know the name or location of a Photon executable, ask your system administrator or see the documentation that came with the application.

Starting an application from its data files

Depending on how your system has been set up, you can start an application by double-clicking on one of its associated data files. Most data files have the following icon:

Data File Icon

For example, you might be able to load a text editor by double-clicking on any data file that ends with .c-the editor would load, along with the selected file.


Note: If double-clicking a data file won't bring up an application, see the discussion on Associating files with an application in "Configuring the File Manager."

Printing files

To print a file that's selected, do one of the following:


Note: If a file doesn't print, ask your system administrator or check the Print command in the PFM Configuration dialog (see "Configuring the File Manager.")

Changing how files are displayed

At the top of the File list you'll see the following buttons:

File list buttons

Using these buttons you can sort your files in any order (by name, date, etc.) or change which information is displayed for each file.

Sorting files

To sort files: Click on:
Alphabetically Filename
By size Size
By the date they were last modified Date

Reversing the sort order

To reverse the sort order, click on Filename, Size, or Date again. For example, the first time you click on Filename, files are sorted from A to Z. The next time you click, they're sorted from Z to A.


Note: The File Manager's quick-search method works only if files are sorted from A to Z.

Displaying folders first

If you want folders to appear at the top of the File list:

  1. From the Tools menu, choose the Configure item. You'll see the PFM Configuration dialog.
  2. Click on Folders First, then click on Apply.

Note: If you display folders first, the File Manager's quick-search method will work only with folders.

For more info on using the Configuration dialog, see "Configuring the File Manager."

Choosing which details are displayed

By default, the File list shows you the name, size, date, and so on for each file. You can hide some of these details using the File list buttons.

For example, let's say you don't need to see the size of each file. To hide the Size field:

  1. Move the pointer onto the vertical line that separates the Size and Date buttons. The pointer changes to a resize pointer:

    Horizontal Resize Pointer

  2. Press the mouse button and drag the pointer to the left until the Size field is hidden.
  3. You'll now see two vertical lines in front of the Date field: the first controls the hidden Size field, the second controls the Date field.

    To uncover the Size field, simply drag the second line back to the right.


Note: Using the above technique, you can also resize any field.

Details at a glance

The following table briefly explains the contents of each field in the File list.

This field: Indicates:
Filename the name given to the file
Size the size of the file in bytes
Date the date the file was created or last modified
Links if this file is a symbolic link, the name of the file that this file is linked to
Owner the owner ID of the file's owner
Group the group ID of the file's owner
Permissions from left to right, the user, group, and other access permissions of the file (these permissions control what kinds of operations users can perform on the file and which users can perform those operations)

For more info on symbolic links, owner IDs, and permissions, ask your system administrator or see the QNX OS Installation & Configuration guide.

Controlling which files are displayed

To control which files are displayed in the File list, you can enter patterns in the Pattern combobox:

pattern combobox

This box uses standard pattern-matching characters, including the asterisk (*), question mark (?), and brackets ([ ]). By default, the box contains *, which tells the File Manager to display all files in the current folder. The following table shows examples of using these characters.

Example patterns

If you enter: You'll see:
f* all files starting with "f" (e.g. frd.c, flnt)
*.[ch] all files ending with ".c" or ".h" (e.g. frd.c, barn.h)
fred? all files beginning with "fred" and ending with one other character

Configuring the File Manager

To configure the File Manager to your preferences, do one of the following:

You'll see the PFM Configuration dialog:

Configure Dialog

You can set the following preferences:

View Options
The Folders First button lets you control whether folders always appear at the top of the File list, before any other files. The Hide "dot" Files button lets you hide any files that begin with a dot, such as .elm, .kshrc, and so on. Typically, these are configuration files that are rarely accessed.
Config Saving
If you select Automatic, the File Manager will automatically save its current state when you quit. That includes not only options in the Configuration dialog, but also the size of the window, how files are sorted, and so on.

If you select Manual, the File Manager will save its current state only if you:

Hotlist Font
File List Font
Let you specify the font used to display folders in the Hotlist and files in the File list. If you click on the Select button, you'll see the following dialog:

Select font dialog

Click on the combobox at the top to select a typeface (e.g. Swiss 721, Courier, etc.), then use the other controls to change the size or style of the font.

The A/A (anti-aliasing) button makes scalable fonts draw a bit slower, but look smoother.

If you're familiar with the format used to specify Photon font names, you could type in the name, size, and style of the font directly into the Hotlist Font or File List Font field.

KeyFind Timeout
To find a file quickly, you can simply type in the name or first few letters of the file you wish to find. Once you're finished typing, the File Manager waits a period a time-by default this is 1.5 seconds-then lets you type in another name.

The KeyFind Timeout field lets you change the period of time the File Manager waits. Specify a new time in milliseconds (e.g. to change the wait time to 2 seconds, specify 2000).

Terminal Command
Lets you specify how the Photon terminal window, pterm, starts up. (To start pterm, see "Opening a Terminal Window" in this chapter.)
View Command
Lets you specify the file viewer that appears when you ask to view a file. The default is less; to change the command line for invoking this utility, see the QNX OS Utilities Reference.
Edit Command
Lets you specify the file editor that appears when you ask to edit a file. The default editor is vedit; to change the command line for invoking this editor, see its entry in the QNX OS Utilities Reference.
Print Command
Lets you specify the print command that will be invoked when you ask to print a file. For more information on print commands, see the QNX OS Installation & Configuration manual.

Associating files with an application

To have an application start automatically when you double-click on any of its data files, you use the File Manager's Associate dialog. This dialog lets you specify file patterns and the commands they're associated with. For example, you can specify that files ending in .c will start your favorite text editor or viewer.

To use the Associate dialog, do one of the following:

You'll see the Associate dialog.

Associate Dialog

When you add or edit a pattern, you can use all the standard pattern-matching characters, including the asterisk (*), question mark (?), and brackets ([ ]).

Here are some examples:

This pattern: Would match:
* all files
*.h all files ending in .h
*.[ch] all files ending in .c or .h
*.bmp all files ending in .bmp

Starting a text-based application

If you wish to have a text-based application (e.g. an editor) load when you select a data file, you must tell the File Manager to first open a pterm window for that application. For example, if you'd like the text-based less utility to load when you double-click on any file ending in .c, you would specify pterm less.


[Previous] [Contents] [Index] [Next]