diff --git a/src/doc/user/usermanual.sgml b/src/doc/user/usermanual.sgml index 791ff28b..0d6631ef 100644 --- a/src/doc/user/usermanual.sgml +++ b/src/doc/user/usermanual.sgml @@ -888,7 +888,7 @@ fvwm The format of the result list entries is entirely configurable by using the preference dialog to - edit an HTML + edit an HTML fragment. You can click on the Query details link @@ -988,10 +988,10 @@ fvwm Hovering over a table row will update the detail area at the bottom of the window with the corresponding values. You can click the row to freeze the display. The bottom area is equivalent to a - classical result list paragraph, with links for - starting a preview or a native application, and an equivalent - right-click menu. Typing Esc (the Escape key) will - unfreeze the display. + result list paragraph, with links for starting a preview or a + native application, and an equivalent right-click menu. Typing + Esc (the Escape key) will unfreeze the + display. @@ -1624,10 +1624,18 @@ fvwm - Result paragraph format string: + Edit result list paragraph format string: allows you to change the presentation of each result list - entry. This is - described in its own section. + entry. See the + result list customisation section. + + + + Edit result page html header insert: + allows you to define text inserted at the end of the result + page html header. + More detail in the + result list customisation section. @@ -1739,16 +1747,38 @@ fvwm need to implement a way of purging the index from stale data, - - The result list paragraph format + + The result list format - The presentation of each result inside the result list can be - customized by setting the result list paragraph format inside the - User Interface tab of the Query - configuration. + The result list presentation can be exhaustively customized + by adjusting two elements: + + The paragraph format + Html code inside the header + section + - This is a Qt HTML string where the following printf-like - % substitutions will be performed: + These can be edited from the Result list + tab of the Query configuration. + + Newer versions of Recoll (from 1.17) use a WebKit HTML + object by default (this may be disabled at build time), and + total customisation is possible with full support for CSS and + Javascript. Conversely, there are limits to what you can do with + the older Qt QTextBrowser, but still, it is possible to decide + what data each result will contain, and how it will be + displayed. + + No more detail will be given about the header part (only + useful with the WebKit build), if there are restrictions to + what you can do, they are beyond this author's HTML/CSS/Javascript + abilities... + + + The paragraph format + + This is an arbitrary HTML string where the following printf-like + % substitutions will be performed: @@ -1756,23 +1786,29 @@ fvwm %DDate - %IIcon image name - + %IIcon image + name. This is normally determined from the mime type. The + associations are defined inside the + + mimeconf configuration file. + If a thumbnail for the file is found at + the standard Freedesktop location, this will be displayed + instead. %KKeywords (if any) - %LPreview and - Edit links + %LPrecooked Preview and + Edit links %MMime type - %Nresult Number - + %Nresult Number inside + the result page %RRelevance - percentage + percentage %SSize information @@ -1788,8 +1824,8 @@ fvwm <a href="P%N"> and <a href="E%N"> - where docnum (%N expands to the document - number inside the result list). + where docnum (%N) expands to the document + number inside the result page). In addition to the predefined values above, all strings like %(fieldname) will be replaced by the value of @@ -2432,7 +2468,7 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r The association of files to mime types is mostly based on name suffixes. The types are defined inside the - + mimemap file. Example: diff --git a/website/custom.html b/website/custom.html index fb62cb21..0108d516 100644 --- a/website/custom.html +++ b/website/custom.html @@ -2,7 +2,7 @@ - RECOLL: contributed result list formata + RECOLL: result list customisation tips @@ -16,6 +16,52 @@ + + + + + @@ -29,8 +75,85 @@
  • Support
  • +
    + +

    The Recoll result list is actually made of html text + displayed inside a Qt Widget. In all Recoll versions, you + can specify the format for the list entries: what data is + displayed for each hit document and how. This used to include + "almost full" support for HTML capabilities, with a few + restrictions due to the Qt QTextBrowser object.

    + +

    As of Recoll 1.17, the result list can be built as a WebKit + object (WebKit is the basis for several major browsers), which + yields full CSS and even Javascript support.

    + +

    New in Recoll 1.17: the WebKit result list

    + +

    With WebKit, things that used to not work are now possible.

    + +

    For example, you can make the list icons links that activate the + preview or open action (or the document url which you can then + drag/drop to other windows).

    + +

    A more interesting example: recoll 1.17 will display document + thumbnails instead of the type icon if the thumbnail exists in + the standard Freedesktop location. The icons/thumbnails are + 64x64 pixels in size, which is a bit small. The standard + thumbnail files are actually 128x128, which is much more + detailed. Using them statically would consume too much list + space though. Using CSS, you can get them to expand when the + mouse is over them. Recipee:

    + +
    +

    Retrieve the CSS code + from randsco + pure CSS photo-caption zoom, and include it inside the + result list html header by using the "Edit result page html + header insert" from the GUI preferences. Don't forget to + enclose the CSS code between <style type="text/css"> + </style> tags.

    + +

    Use something like the following result paragraph format + (only the code around the img tag is relevant, the rest can be + what you want):

    + +
    +
    +<table><tr><td>
    +
    + <div class="PZ3zoom PZ3-l noBdr noCap noLnk" style="width:64px;height:64px;">
    + <a href="%U"> <img src='%I' width='64'></a>
    +</div>
    +
    +</td><td>
    +%R %S %L &nbsp;&nbsp;<b>%T</b><br>%M&nbsp;%D&nbsp;&nbsp;&nbsp;<i>%U</i>&nbsp;%i<br>%A %K
    +</td></tr></table>
    +
    + +
    +
    + + hover zoom + +
    + +

    Et voilą! The icons will grow to their full size when the mouse is + over them.

    + + + +

    Result list paragraph format samples

    The format for paragraphs inside the Recoll GUI result list is diff --git a/website/resparpics/pz3.png b/website/resparpics/pz3.png new file mode 100644 index 00000000..c6157527 Binary files /dev/null and b/website/resparpics/pz3.png differ