> For the complete documentation index, see [llms.txt](https://chaoses-ib.gitbook.io/directory-opus/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://chaoses-ib.gitbook.io/directory-opus/manual/reference/scripting_reference/scripting_objects/format.md).

# Format

The **Format** object represents the current display format of a tab. It is obtained from the [**Tab**](/directory-opus/manual/reference/scripting_reference/scripting_objects/tab.md)**.format** property.

| Property Name       | Return Type                                                                                                                                                             | Description                                                                                                                                                                                                                                                                                                                                       |
| ------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| alpha\_folders      | *bool*                                                                                                                                                                  | Returns **True** if folders are always sorted alphabetically, **False** if otherwise.                                                                                                                                                                                                                                                             |
| autosize            | *bool*                                                                                                                                                                  | Returns **True** if column width auto-sizing is enabled, **False** if otherwise.                                                                                                                                                                                                                                                                  |
| checkboxes          | *bool*                                                                                                                                                                  | Returns **True** if [checkbox mode](/directory-opus/manual/basic_concepts/selecting_files/selecting_with_the_mouse_and_keyboard/checkbox_mode.md) is turned on, **False** if otherwise.                                                                                                                                                           |
| columns             | *collection:*[**Column**](/directory-opus/manual/reference/scripting_reference/scripting_objects/column.md)                                                             | Returns a collection of [**Column**](/directory-opus/manual/reference/scripting_reference/scripting_objects/column.md) objects that represent all the individual columns currently added to the display.                                                                                                                                          |
| format\_explain     | [**Vector**](/directory-opus/manual/reference/scripting_reference/scripting_objects/vector.md):*string*                                                                 | Returns a \*\*[Vector](/directory-opus/manual/reference/scripting_reference/scripting_objects/vector.md)\*\*of strings representing the explanation of the current folder format (the same text visible when hovering the mouse over the format lock icon in the status bar).                                                                     |
| frozen              | *int*                                                                                                                                                                   | Returns the number of frozen columns. Columns are always frozen from the left so this also tells you which columns are frozen (if any).                                                                                                                                                                                                           |
| getsizes            | *string*                                                                                                                                                                | Returns a string that indicates the state of the option to automatically calculate folder sizes. The string returned will be one of *default*, *on* or *off*.                                                                                                                                                                                     |
| group\_by           | *string*                                                                                                                                                                | If grouping is enabled, returns the name of the column that the list is grouped by.                                                                                                                                                                                                                                                               |
| group\_combine      | *string*                                                                                                                                                                | Returns a string indicating the current group combining mode. Possible values are **normal**, **never** and **other**.                                                                                                                                                                                                                            |
| group\_individual   | *bool*                                                                                                                                                                  | Returns **True** if the group combining mode is set to **Never combine**. Note that this option is deprecated, you should use **group\_combine** instead.                                                                                                                                                                                         |
| group\_reverse      | *bool*                                                                                                                                                                  | Returns **True** if the groups are sorted in reverse order.                                                                                                                                                                                                                                                                                       |
| hide\_attr          | *object:*[**FileAttr**](/directory-opus/manual/reference/scripting_reference/scripting_objects/fileattr.md)                                                             | Returns a [**FileAttr**](/directory-opus/manual/reference/scripting_reference/scripting_objects/fileattr.md) object indicating the file attributes that are hidden (any items with these attributes set will be hidden from the display).                                                                                                         |
| hide\_dirs          | *string*                                                                                                                                                                | Returns the wildcard pattern of folders that are hidden from the display.                                                                                                                                                                                                                                                                         |
| hide\_dirs\_regex   | *bool*                                                                                                                                                                  | Returns **True** if the current **hide\_dirs** pattern is using regular expressions.                                                                                                                                                                                                                                                              |
| hide\_ext           | *bool*                                                                                                                                                                  | Returns **True** if filename extensions are hidden, or **False** if they are displayed.                                                                                                                                                                                                                                                           |
| hide\_files         | *string*                                                                                                                                                                | Returns the wildcard pattern of files that are hidden from the display.                                                                                                                                                                                                                                                                           |
| hide\_files\_regex  | *bool*                                                                                                                                                                  | Returns **True** if the current **hide\_files** pattern is using regular expressions.                                                                                                                                                                                                                                                             |
| hide\_folder\_attr  | <p><em>object:</em><a href="/directory-opus/manual/reference/scripting_reference/scripting_objects/fileattr.md"><strong>FileAttr</strong></a><br>or <em>string</em></p> | Returns a [**FileAttr**](/directory-opus/manual/reference/scripting_reference/scripting_objects/fileattr.md) object indicating the folder attributes that are hidden (any folders with these attributes set will be hidden from the display). If the separate folder attribute filter is disabled this property will return the string **"off"**. |
| ignore\_prefix      | *string*                                                                                                                                                                | Returns the filename prefixes that are ignored when sorting the list.                                                                                                                                                                                                                                                                             |
| locked              | *bool*                                                                                                                                                                  | Returns **True** if the folder format is locked in the tab.                                                                                                                                                                                                                                                                                       |
| manual\_sort        | *bool*                                                                                                                                                                  | Returns **True** if [manual sorting](/directory-opus/manual/basic_concepts/sorting_and_grouping/manual_sorting.md) is enabled.                                                                                                                                                                                                                    |
| manual\_sort\_name  | *string*                                                                                                                                                                | If manual sorting is active, returns the name of the current sort order (if it has one).                                                                                                                                                                                                                                                          |
| manual\_sort\_order | *object:*[**SortOrder**](/directory-opus/manual/reference/scripting_reference/scripting_objects/sortorder.md)                                                           | If manual sort is active, returns a [**SortOrder**](/directory-opus/manual/reference/scripting_reference/scripting_objects/sortorder.md) object which lets you query and change the sort order.                                                                                                                                                   |
| mix\_type           | *string*                                                                                                                                                                | Returns a string indicating the current file/folder mixing type. The string returned will be one of *mixed*, *files* (files first) or *dirs* (folders first).                                                                                                                                                                                     |
| name\_ext           | *bool*                                                                                                                                                                  | Returns **True** if filenames and extensions are sorted separately.                                                                                                                                                                                                                                                                               |
| numeric\_name       | *bool*                                                                                                                                                                  | Returns **True** if numeric name sorting is enabled.                                                                                                                                                                                                                                                                                              |
| reverse\_sort       | *bool*                                                                                                                                                                  | Returns **True** if the over-all sort order is reversed.                                                                                                                                                                                                                                                                                          |
| show\_attr          | *object:*[**FileAttr**](/directory-opus/manual/reference/scripting_reference/scripting_objects/fileattr.md)                                                             | Returns a [**FileAttr**](/directory-opus/manual/reference/scripting_reference/scripting_objects/fileattr.md) object indicating the file attributes that are shown (only items with these attributes set will be shown in the display).                                                                                                            |
| show\_dirs          | *string*                                                                                                                                                                | Returns the wildcard pattern of folders that are shown (only folders matching this pattern will be shown).                                                                                                                                                                                                                                        |
| show\_dirs\_regex   | *bool*                                                                                                                                                                  | Returns **True** if the current **show\_dirs** pattern is using regular expressions.                                                                                                                                                                                                                                                              |
| show\_files         | *string*                                                                                                                                                                | Returns the wildcard pattern of files that are shown.                                                                                                                                                                                                                                                                                             |
| show\_files\_regex  | *bool*                                                                                                                                                                  | Returns **True** if the current **show\_files** pattern is using regular expressions.                                                                                                                                                                                                                                                             |
| show\_folder\_attr  | <p><em>object:</em><a href="/directory-opus/manual/reference/scripting_reference/scripting_objects/fileattr.md"><strong>FileAttr</strong></a><br>or <em>string</em></p> | Returns a [**FileAttr**](/directory-opus/manual/reference/scripting_reference/scripting_objects/fileattr.md) object indicating the folder attributes that are shown (only folders with these attributes set will be shown in the display). If the separate folder attribute filter is disabled this property will return the string **"off"**.    |
| sort\_ext           | *bool*                                                                                                                                                                  | Returns **True** if the name column is sorted by filename extension rather than filename.                                                                                                                                                                                                                                                         |
| sort\_field         | *object:*[**Column**](/directory-opus/manual/reference/scripting_reference/scripting_objects/column.md)                                                                 | Returns a [**Column**](/directory-opus/manual/reference/scripting_reference/scripting_objects/column.md) object representing the current sort field.                                                                                                                                                                                              |
| thumb\_size         | *int*                                                                                                                                                                   | Returns the custom thumbnail size, or 0 if no custom size is set.                                                                                                                                                                                                                                                                                 |
| thumb\_stretch      | *string*                                                                                                                                                                | If the format overrides the global thumbnail stretch mode, returns one of *FitReduce*, *FitSmooth*, *FitPixelated*, *FillCropSmooth*, or *FillCropPixelated*. Otherwise, returns *none*.                                                                                                                                                          |
| view                | *string*                                                                                                                                                                | Returns the current [view mode](/directory-opus/manual/basic_concepts/the_lister/view_modes.md) as a string. The returned string will be one of *large*\_*icons*, *small*\_*icons*, *list*, *details*, *power*, *thumbnails* or *tile.*                                                                                                           |
| word\_sort          | *bool*                                                                                                                                                                  | Returns **True** if word sorting is enabled.                                                                                                                                                                                                                                                                                                      |

| Method Name | **Arguments** | Return Type | Description                                                                                                                                                                                                                                                                                                                    |
| ----------- | ------------- | ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Update      | *none*        | *none*      | The first time a script accesses a particular **Format** object, a snapshot is taken of the tab's format. If the script then makes changes to that tab (e.g. it changes the sort field, etc), these changes will not be reflected by the object. To re-synchronize the object with the tab, call the **Format.Update** method. |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://chaoses-ib.gitbook.io/directory-opus/manual/reference/scripting_reference/scripting_objects/format.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
