Swarm 2014.1: User Guide

Files

The Perforce service's primary task is to version files, so Swarm makes it easy to browse the depot. Start browsing by clicking the Files link in the top toolbar.

The File Browser

  • breadcrumbs

    Swarm displays a list of breadcrumb links to help you quickly navigate to higher level directories quickly.

  • folder icon

    Links with folder icons represent directories of files within the depot. Click a directory link to display the contents of that directory.

  • parent folder icon

    Click the .. link with the up-arrow icon, when it appears, to navigate to the current directory's parent.

  • file icon

    Links with dog-eared page icons represent individual files within the depot. See below for more information.

  • History tab

    Click the History tab to display the list of changes made to files in the current directory, or any directories it contains. See “History” for more information.

a linked folder

Swarm creates links for files and directories wherever they appear in the Swarm UI.

Browsing deleted files and folders

The Show Deleted Files checkbox

When the Show Deleted Files checkbox is checked, Swarm includes deleted folders and files in the file display.

A file listing with a deleted folder and file.

Deleted folders and files are presented slightly muted compared to non-deleted entries.

File display

When Swarm is asked to display a file, if the file is a type that Swarm can display, Swarm presents the file's contents. Clicking the Open button displays the file content with no surrounding page markup. Clicking the Download button causes the file to be downloaded.

Version 2 of logo-lg.png

Along with the file's name, Swarm displays the version number for the currently displayed file. For example, this heading indicates that version 2 of logo-lg.png is being displayed. Every version of a file is available on the “History” tab.

A deleted version number

If the version of a file being previewed has been deleted, the version number appears in red:

Text Files

Swarm displays the contents of text files (include the Perforce filetypes unicode and UTF16) with line numbers. When possible, syntax highlighting is applied to make identification of various elements within the file easier.

Tip

For more information on Perforce filetypes, see Perforce Command Reference: File Types

a displayed text file

The Blame button

Click Blame to add a column to the display that identifies the userid responsible for each line of the file.

A displayed text file with blame

Each userid presented is a link that, when clicked, displays the changelist that provided the associated text. Muted userids indicate that the associated text is from the same changelist as the line above. For example, the userid gnicol is responsible for lines 1 through 9 in the screenshot above.

When you hover your pointer over a userid in the blame column, a tooltip appears displaying the associated changelist description.

The changelist associated with the current line

Images

Swarm displays web-safe images.

a displayed image

The checkerboard background in this example is not part of the logo; it helps identify where transparency exists.

When imagick (an optional module that integrates ImageMagick into PHP) is installed, Swarm can also display the following image formats: BMP, EPS, PSD, TGA, TIFF.

3D models

Swarm 2014.1 includes support for displaying select 3D model file types in the browser:

a 3D model rendered in Swarm

Supported file types include:

  • DAE - including any referenced web-safe texture images.

  • STL - both binary and ASCII versions of the format.

  • OBJ - including any referenced MTL files, and web-safe texture images.

When Swarm can display a 3D model, it renders a generic grid stage and places the model in the center, scaled to make viewing straightforward. A toggle control appears in the top right: when enabled, you can control the view with the mouse, and when not enabled, permits auto-rotation to occur (when possible).

  1. Click and hold the left mouse button to begin rotating the view. Drag while holding the left mouse button to rotate the view.

  2. Click and hold the right mouse button to begin panning the view. Drag while holding the right mouse button to pan the view.

  3. Roll the mouse wheel up or down to adjust the magnification of the view.

When possible, a second control appears allowing you to toggle between showing the model with surfaces, or just showing the model's wireframe.

Note

For systems with hardware acceleration, if your browser supports WebGL and hardware acceleration is enabled, Swarm renders the model and enables auto-rotation.

For systems without hardware acceleration or WebGL, but your browser supports HTML5 canvas elements and Javascript TypedArrays, Swarm renders the model but auto-rotation is disabled. Rendering is likely to be slow and rendering quality is likely to be low.

For browsers without HTML5 canvas alements and Javascript TypedArrays, no rendering is attempted; instead, users see a message indicating that the browser is not supported.

Other file types

It is possible to view other file types in Swarm, through the addition of additional modules, or by installing “LibreOffice” on the Swarm host.

When the file is a type that Swarm cannot display, Swarm presents the file's history, along with the Download button.

a file that cannot be displayed

0 matching pages