Corrected few things and added short description for creating and saving filter, as well as replacing the default filters set.

actorid
Marek Kochanowicz 11 years ago
parent 0141526c55
commit 8ae38eaa1f

@ -45,7 +45,7 @@ We strongly recommend to take a look at the filters table right now to see what
Back to the manual? Great.\\
If you want to create your own filter you have to know exactly what do you want to get in order to translate this into the expressions. Finally, you will have to write this with correct syntax. As a result table will show only desired rows.\\
Advance subsection covers everything that you need to know in order to create any filter you may want to.
\subsection{Namespaces}
\subsubsection{Namespaces}
Did you noticed that every default filter has ``project::`` prefix? It is a ``namespace``, a term borrowed from the C++ language. In case of OpenCS namespace of the filter determinate if the filter will be stored along with your project file or if it will be forgotten as soon as OpenCS quits.
\begin{description}
\item[project::] namespace indicates that filter is stored inside the project file.
@ -82,7 +82,7 @@ As you would imagine the range can be specified as including a border value, or
\item Mixing brackets is completely legal. For value equal 10, expression value(something, [5, 10) will evaluate to true. The same expression will evaluate to false for value equal 10.
\end{itemize}
\subsection{Logical expressions}
\susubbsection{Logical expressions}
This subsection takes care of two remaining groups of expressions: binary and unary. The only unary expression present in the OpenCS is logical not, while the remaining binary expressions are: or, and. This clearly makes theme from user point of view belonging to the same group of logical expressions.
\paragraph{not -- not expression()}
@ -95,4 +95,12 @@ Or expression is useful when showing two different group of records is needed. F
\paragraph{and -- and(expression1(), expression2())}
And is a expression that will return true if all arguments evaluates to true. As in the case of ''or`` you can use two or more arguments, separated by a comma.\\
As We mentioned earlier in the ''not`` filter, combining ''not`` with ''and`` can be very useful. For instance to show all armor types, excluding gauntlets you can write the following: ''and (not string("armor type", ".* gauntlet"), string(''Record Type``, ''Armor``))''.
As We mentioned earlier in the ''not`` filter, combining ''not`` with ''and`` can be very useful. For instance to show all armor types, excluding gauntlets you can write the following: ''and (not string("armor type", ".* gauntlet"), string(''Record Type``, ''Armor``))''.
\subsubsection{Creating and saving filter}
In order to create and save new filter, you should go to the filters table, right click and select option ``add record'' from the context menu. A horizontal widget group at the bottom of the table should show up. From there you should select a namespace responsible for scope of the filter (described earlier) and desired ID of the filter. After pressing ok button new entry will show up in the filters table. This filter does nothing at the moment, since it still lacks expressions. In order to add your formula simply double click the filter cell of the new entry and write it down there.\\
Done! You are free to use your filter.
\subsubsection{Replacing the default filters set}
{OpenCS} allows you to substitute default filters set provided by us, with your own filters. In order to do so you should create a new project, add desired filters, remove undesired and save. Rename the file to the ``defaultfilters'' (don't forget to remove .omwaddon.project extension) and place it inside your configuration directory.\\
The file acts as template for all new project files from now. If you wish to go back to the old default set, simply rename or remove the custom file.
Loading…
Cancel
Save