Go to: Synopsis. Return value. Flags. Python examples.

Synopsis

projFileViewer( string , [clear=boolean], [deselectIndexedItem=int], [deselectItem=string], [displayHidden=boolean], [displayMode=int], [doubleClickCommand=script], [forceRefresh=boolean], [numberOfItem=boolean], [numberOfSelectedItem=boolean], [selectCommand=script], [selectItem=string], [sortBy=string], [updateCommand=script], [workspace=string])

Note: Strings representing object names and arguments must be separated by commas. This is not depicted in the synopsis.

projFileViewer is undoable, queryable, and editable.

This command creates a viewer that lists the project files in the current working directory. The viewer can then be attached to a pane.

Return value

None

In query mode, return type is based on queried flag.

Flags

clear, deselectIndexedItem, deselectItem, displayHidden, displayMode, doubleClickCommand, forceRefresh, numberOfItem, numberOfSelectedItem, selectCommand, selectItem, sortBy, updateCommand, workspace
Long name (short name) Argument types Properties
updateCommand(uc) script createedit
Specify the update command.
selectItem(si) string createqueryeditmultiuse
Select the given item.
deselectItem(di) string createqueryeditmultiuse
Deselect the given item.
deselectIndexedItem(dii) int createqueryeditmultiuse
Deselect the given index item.
numberOfSelectedItem(nsi) boolean query
Return the number of selected items.
numberOfItem(ni) boolean query
Return the number of items.
clear(cl) boolean createedit
Clear all items.
doubleClickCommand(dcc) script createedit
String is a command which is executed on a double click.
selectCommand(sc) script createedit
String is a command which is executed when an item is selected.
workspace(ws) string createqueryedit
Specify the workspace that this viewer works on.
forceRefresh(fr) boolean createedit
Force the displayed items to be refreshed.
displayMode(dm) int createqueryedit
Set the display mode. Default is icon. Mode 0 displays as text. Mode 1 displays as large icons. Mode 2 displays as small icons.
sortBy(sb) string createqueryedit
Specifies how the entry should be sorted. Possible values are "name", "date", and "size".
displayHidden(dh) boolean createqueryedit
Indicates whether hidden files should be displayed or not.

Flag can appear in Create mode of command Flag can appear in Edit mode of command
Flag can appear in Query mode of command Flag can have multiple arguments, passed either as a tuple or a list.

Python examples

import maya.cmds as cmds

cmds.window( 'ProjWindow', rtf=0, wh=(150, 150) )
cmds.paneLayout( 'ProjPanes' )
cmds.projFileViewer( 'ProjFileView', dm=0 )
cmds.paneLayout( 'ProjPanes', e=True, cn='single', sp=('ProjFileView', 1) )
cmds.projFileViewer( 'ProjFileView', e=True, fr=True )
cmds.showWindow()