Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The Code Editor features a help sidebar that can be used both for Macro and Python scripts. The sidebar can offer help for: functions and colour editing.

...

Function List

The function help can be activated by pressing F1.

...

If we press F1 when the text cursor is not positioned on a built-in function or icon parameter, or we press the  button in the toolbar, the help sidebar will open up showing the full Metview function list (including all the icon and non-icon functions).

Image RemovedImage Added

Here we have the option of either inserting the selected function into the editor or copying it into the clipboard. If we double-click or press the Details button the function's help page will be shown (see below).

Built-in function help (F1)

The function help can be activated by pressing F1.

Icon functions

If we press F1 on any of the icon functions' name, or we press the Image Added button in the toolbarthe help sidebar will open up showing the icon's help panel. In the example below the text cursor was located in  "mgraph("  when we pressed F1 so the sidebar shows the details of the Graph plotting icon:

Image RemovedImage Added

Alternatively, if we press F1 on an icon parameter (within an icon function) the help sidebar will show the icon help panel with the given parameter automatically selected in the parameter list. In the example below the text cursor was located in parameter  "graph_symbol_outline"  (within the icon function mgraph) when we pressed F1:

Image RemovedImage Added

The icon help panel contains two tabs:

...

This tab shows the list of all the parameters belonging to the icon:

Image RemovedImage Added

When we click on a parameter in the list the available values of the parameter (if it offers a predefined list of values) will be shown in the Values list. By clicking on a colour parameter the colour editor will appear below the parameter list:

Image RemovedImage Added

The Code generated for selection section at the bottom of the panel shows a preview of the code generated for the current parameter and its selected value. Using the buttons below this section the text can be either inserted into the code editor or copied into the clipboard.

Image RemovedImage Added

...

Accessing the documentation

...

This tab shows the web-based Metview documentation about the icon.

Image Removed

...

By pressing the Documentation button in the bottom left corner

Image Added

the icon's online documentation will be opened in a web browser:

Image Added

The web-based documentation will only be available if both of the following conditions are met:

  • Metview was built with the WebEngine component of the Qt framework.
  • The required level of OpenGL support is available in the current graphical environment.

...


Non-icon functions

If we press F1 on any of the non-icon functions, or we press the Image Added button in the toolbar in the text editor the help sidebar will show the description and web-based documentation of the given function. In the example below the text cursor was located in text "gradient("  when we pressed F1 so the sidebar shows the documentation of function gradient().

Image Added

Accessing the documentation

By pressing the Documentation button in the bottom right corner

Image Added

the function's online documentation will be opened in a web browser:

Image AddedImage Removed

Functions available for multiple data types

It can happen that a given function can be used with multiple data types and is documented on multiple web pages . Let us take the (e.g. values()) function as an example. The first thing to note is that . In this case there is a separate entry for each variant in the function list the tooltip describes all the variants of this function:

Image RemovedImage Added


Then and in the function 's help page at the top we can choose which variant's documentation we want to see:description page :

Image AddedImage Removed

Integrated Colour Editor (F2)

...