* Added more CSS control for menus, buttons, app names, shell commands, paths.

* Always wanting keyboard graphics for shortcuts, Jorge suggested simple borders
  for simplicity. Great idea! Added.
* Added Jorge's rounded boxes for note/warning/stop plus symbols.
* If anyone wants to fine tune esp. colours, go ahead. Jorge and I are both
  challenged in that department. :)
* A few small corrections and reformatting here and there.
* Excluded the topic "Installation" from the contents until it's further along.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29269 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Joachim Seemer
2009-02-21 11:40:17 +00:00
parent f9e9051d3e
commit e564a3c1f7
90 changed files with 853 additions and 766 deletions
+20 -20
View File
@@ -5,7 +5,7 @@
<head>
<!--
*
* Copyright 2008, Haiku. All rights reserved.
* Copyright 2008-2009, Haiku. All rights reserved.
* Distributed under the terms of the MIT License.
*
* Authors:
@@ -36,43 +36,43 @@
<div class="content">
<p>A query is a file search based on file attributes and can be performed within Tracker or in Terminal. Queries are saved in "<tt>/boot/home/queries/</tt>" and by default last seven days before being purged. Note, that these aren't static result lists of your search, but are the query formulas which trigger a new search whenever you open them.</p>
<p>A query is a file search based on file attributes and can be performed within Tracker or in Terminal. Queries are saved in <span class="path">/boot/home/queries/</span> and by default last seven days before being purged. Note, that these aren't static result lists of your search, but are the query formulas which trigger a new search whenever you open them.</p>
<h2><a id="find-window" name="find-window">The Find window</a></h2>
<p>You start a query by invoking the <i>Find...</i> menu either from the Deskbar menu or any Tracker window or the Desktop (which is actually a fullscreen Tracker window). The shortcut is <tt>ALT+F</tt>. You're presented with the Find window:</p>
<p>You start a query by invoking the <span class="menu">Find...</span> menu either from the Deskbar menu or any Tracker window or the Desktop (which is actually a fullscreen Tracker window). The shortcut is <span class="key">ALT</span>&#160;<span class="key">F</span>. You're presented with the Find window:</p>
<img src="../images/queries-images/basic-query.png" alt="basic-query.png" width="517" height="292" />
<ol>
<li><p>Select previous or saved queries or save the current query.</p></li>
<li><p>Narrow down your search from "All files and folders" to specific file
types.</p></li>
<li>Define the search method:<ul>
<li><i>by Name</i> - a basic search by filename</li>
<li><i>by Attribute</i> - an advanced search, you specify search terms for one or more attributes</li>
<li><i>by Formula</i> - an even more advanced search, you can fine-tune a complex query term</li></ul></li>
<li><span class="menu">by Name</span> - a basic search by filename</li>
<li><span class="menu">by Attribute</span> - an advanced search, you specify search terms for one or more attributes</li>
<li><span class="menu">by Formula</span> - an even more advanced search, you can fine-tune a complex query term</li></ul></li>
<li><p>Select which drives to search on.</p></li>
<li><p>Enter the search term.</p></li>
<li><p>The expander hides/unhides the additional options.</p></li>
<li><p>Uncheck the <i> Temporary</i> checkbox if you don't want this query self-destruct after 7 days.</p></li>
<li><p>Check if your query is supposed to <i>Include trash</i>.</p></li>
<li><p>Uncheck the <span class="menu">Temporary</span> checkbox if you don't want this query self-destruct after 7 days.</p></li>
<li><p>Check if your query is supposed to <span class="menu">Include trash</span>.</p></li>
<li><p>Optionally, enter a name for this query if you want to save it.</p></li>
<li><p>You can drag&amp;drop the icon to save the query.</p></li>
</ol>
<h2><a id="basic-query" name="basic-query">Basic queries - "by Name"</a></h2>
<p>If you simply want to find all files on your mounted disks that match a certain pattern, simply leave the search method at "<i>by Name</i>", enter the search term into the text box and press <tt>ENTER</tt>.</p>
<p>If you simply want to find all files on your mounted disks that match a certain pattern, simply leave the search method at "<span class="menu">by Name</span>", enter the search term into the text box and press <span class="key">ENTER</span>.</p>
<h2><a id="adv-query" name="adv-query">Advanced queries - "by Attribute"</a></h2>
<p>You can create more advanced queries by searching within the attributes of specific file types. For that to work, these attributes have to be indexed (see <a href="index.html">Index</a>).</p>
<img src="../images/queries-images/query-window.png" alt="query-window.png" width="441" height="172" />
<p>You start by setting the filetype from "<i>All files and folders</i>" to "<i>text | E-mail</i>" and change the search method to "<i>by Attribute</i>.</p>
<p>This adds a drop-down menu to the left of the textbox and the buttons "<i>Add</i> and <i>Remove</i> under that. From the menu you choose which attribute to query. With "<i>Add</i> and <i>Remove</i> you can query additional attributes or remove them again. These attributes can be logically linked with AND/OR.</p>
<p>You start by setting the filetype from "<span class="menu">All files and folders</span>" to "<span class="menu">text | E-mail</span>" and change the search method to "<span class="menu">by Attribute</span>.</p>
<p>This adds a drop-down menu to the left of the textbox and the buttons "<span class="button">Add</span> and <span class="button">Remove</span> under that. From the menu you choose which attribute to query. With "<span class="button">Add</span> and <span class="button">Remove</span> you can query additional attributes or remove them again. These attributes can be logically linked with AND/OR.</p>
<p>Let's do an email query as an example:</p>
<img src="../images/queries-images/query-window-filled.png" alt="query-window-filled.png" width="441" height="262" />
<p>This is your Find window when you're looking for all emails Clara Botter has sent to you in the last two months that had in the subject "vibraphone" or "skepticality".</p>
<h2><a id="more-adv-query" name="more-adv-query">Even more advanced queries - "by Formula"</a></h2>
<p>Typing in a formula query by hand is daunting and really quite unpractical. It still has its uses.</p>
<p>Take the above query by attribute of Clara's mails concerning vibraphones etc. If you have all the attributes and their search terms set, try switching to "<i>by Formula</i> mode and be overwhelmed by this one line query string:</p>
<p>Take the above query by attribute of Clara's mails concerning vibraphones etc. If you have all the attributes and their search terms set, try switching to "<span class="menu">by Formula</span> mode and be overwhelmed by this one line query string:</p>
<img src="../images/queries-images/formula-query.png" alt="formula-query.png" width="441" height="173" />
<p>Once more as text, edited for readability:</p>
<pre>(((((MAIL:from==&quot;*[cC][lL][aA][rR][aA] [bB][oO][tT][tT][eE][rR][sS]*&quot;)
@@ -82,9 +82,9 @@ types.</p></li>
&amp;&amp;(BEOS:TYPE==&quot;text/x-email&quot;))</pre>
<p>What's the use?</p>
<ul>
<li>You could copy and paste the string into an email, forum or IRC for others to use or debug.</li>
<li>You can use this method to construct a query in <i>Attribute</i> mode and then switch to <i>Formula</i> mode, to comfortably generate a search string to use for a query in Terminal or a script.</li>
<li>You can fine tune your query by inserting parenthesis where needed, make parts case-sensitive or negate logical combinations by changing. e.g. "<tt>==</tt>" to "<tt>!=</tt>" for a NOT AND. All you need is a basic understanding of <a href="http://en.wikipedia.org/wiki/Regular_expression" class='external free' title="http://en.wikipedia.org/wiki/Regular expression" rel="nofollow">regular expressions</a> and maybe some scripting basics.</li>
<li><p>You could copy and paste the string into an email, forum or IRC for others to use or debug.</p></li>
<li><p>You can use this method to construct a query in <span class="menu">Attribute</span> mode and then switch to <span class="menu">Formula</span> mode, to comfortably generate a search string to use for a query in Terminal or a script.</p></li>
<li><p>You can fine tune your query by inserting parenthesis where needed, make parts case-sensitive or negate logical combinations by changing. e.g. "<tt>==</tt>" to "<tt>!=</tt>" for a NOT AND. All you need is a basic understanding of <a href="http://en.wikipedia.org/wiki/Regular_expression" class='external free' title="http://en.wikipedia.org/wiki/Regular expression" rel="nofollow">regular expressions</a> and maybe some scripting basics.</p></li>
</ul>
<h2><a id="result-window" name="result-window">The result window</a></h2>
@@ -92,12 +92,12 @@ types.</p></li>
<img src="../images/queries-images/result-window.png" alt="result-window.png" width="704" height="359" />
<p>Besides the grey background, result windows work exactly like any other Tracker window. Some things are worth noting:</p>
<ul>
<li>You can open the folder a file resides in by double clicking on its path attribute.</li>
<li>With <i>File | Edit Query</i> or <tt>ALT+G</tt> you get back to your Find window to refine your query.</li>
<li>A query is live, i.e. if a file that matches your search criteria appears or disappears from your system, this change is reflected in your results in real-time.
<li><p>You can open the folder a file resides in by double clicking on its path attribute.</p></li>
<li><p>With <span class="menu">File | Edit Query</span> or <span class="key">ALT</span>&#160;<span class="key">G</span> you get back to your Find window to refine your query.</p></li>
<li><p>A query is live, i.e. if a file that matches your search criteria appears or disappears from your system, this change is reflected in your results in real-time.</p></li>
</ul>
<p>You can assign a sensible attribute layout for query results of a specific filetype. Open the folder containing files of the filetype you'd like to create a template for and arrange the attributes how you'd like to have query results presented. Copy this layout with <i>Attributes | Copy Attributes</i>.</p>
<p>Open <tt>/boot/home/config/settings/Tracker/DefaultQueryTemplates</tt>, create a new folder and rename it to <i>group/filetype</i>, replacing slashes with underscores, e.g."audio_x-mp3". Open the new folder and paste in the layout with <i>Attributes | Paste Attributes</i>.</p>
<p>You can assign a sensible attribute layout for query results of a specific filetype. Open the folder containing files of the filetype you'd like to create a template for and arrange the attributes how you'd like to have query results presented. Copy this layout with <span class="menu">Attributes | Copy Attributes</span>.</p>
<p>Open <span class="path">/boot/home/config/settings/Tracker/DefaultQueryTemplates</span>, create a new folder and rename it to <i>group/filetype</i>, replacing slashes with underscores, e.g."audio_x-mp3". Open the new folder and paste in the layout with <span class="menu">Attributes | Paste Attributes</span>.</p>
</div>