15.07.2013 Views

jgrasp handbook

jgrasp handbook

jgrasp handbook

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Clear All Marks - removes all marks.<br />

18.9 Open File Dialog<br />

A dialog for opening files.<br />

DRAFT, February 18, 2003, Page 96<br />

Filters for the languages supported by jGRASP are provided, as well as the "all files" filter. Note that<br />

language filters classify files based on the extension only if they have not been opened in jGRASP before.<br />

Once a file is opened, jGRASP remembers that language. The default language for files with a ".h"<br />

extension can be set to C++ or C only (not both) by changing the extension settings for C or C++ (see<br />

settings).<br />

You can also type a list of extensions into the "Filter Extensions" field to filter by extensions. These must<br />

be separated by whitespace, and can start with ".", "*.", or nothing. For example: "*.c *.cpp", ".c .cpp", and<br />

"c cpp" will all show only files that end in ".c" or ".cpp".<br />

The Text / Binary radio buttons allow the file to be opened in text mode (UNIX, DOS, and Mac. line<br />

terminators accepted) or binary mode (only newlines are line terminators).<br />

18.10 Mouse Button Actions<br />

Left Mouse Button<br />

Shift Key Down - same as middle mouse button.<br />

Ctrl Key Down - same as right mouse button with CSD Window popup disabled.<br />

Single Click - positions cursor. If at left of window, selects a line.<br />

Double Click - if on text, selects a whitespace delimited word or whitespace. If on CSD, folds the<br />

CSD structure recursively. If on a folded CSD line, unfolds that line.<br />

Triple Click - selects a line.<br />

Quadruple Click - selects the whole text.<br />

Middle Mouse Button - Extends the current selection.<br />

Right Mouse Button - if CSD Window popup is enabled, brings up the popup menu, otherwise:<br />

Single Click - selects a single language-specific token or whitespace block.<br />

More Clicks - selects layers of matching parenthesis and braces.<br />

18.11 Folding<br />

The jGRASP CSD window allows text folding based on CSD structure and arbitrary folding. This folding is<br />

line-based: two or more lines are folded into one. For CSD structures, the first line remains unfolded. The<br />

second line (first folded line) displays the CSD folding symbol (a box with a plus inside) and if the second<br />

line contained only a comment, that comment. The fold commands are available on the View / Fold menu,<br />

through accelerator keys, and through mouse actions on the CSD. If the menu or accelerator key is used,<br />

folding is applied to the current text cursor position. For mouse clicking, it is applied to the position clicked<br />

on.<br />

When text is edited after a CSD is generated, the foldable structure is maintained as much as possible.<br />

An edited CSD may fold in unexpected ways - regenerating the CSD will fix this.<br />

The CSD structure containing the cursor is considered to be the innermost structure if the cursor is in the<br />

text, or the nearest CSD stem if the cursor is in the CSD. Note that each statement and declaration is a

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!