https://wiki.hydrogenaud.io/api.php?action=feedcontributions&user=NEMO7538&feedformat=atomHydrogenaudio Knowledgebase - User contributions [en]2024-03-28T10:49:36ZUser contributionsMediaWiki 1.22.7https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Playlist_Organizer_(foo_plorg)Foobar2000:Components/Playlist Organizer (foo plorg)2015-10-13T07:43:59Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Playlist Organizer (foo plorg)]]<br />
[[Image:Foo_plorg.png|thumb|right|480px|Playlist Organizer Main view]]<br />
<br />
<br />
<br />
=General=<br />
'''foo_plorg''' is a simple component that will let your organize your playlists in a treeview fashion. It is available as either a Column UI panel or an UI element for the default UI. It enables your to create folders, hierarchies and move around folders and playlists by dragging and dropping them wherever you want in the panel.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_plorg here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1).<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 1.9.1 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Install the toolbar as an UI element (Default UI) or a column UI panel. The commands are available with a right click on the panel.<br />
Folders and Playlists be can selected by a left click, then moved and dropped around.<br />
<br />
=Usage=<br />
==Basic Usage==<br />
The component implements a treeview control, basically made of playlist and folders.<br />
When the component is used for the first time, a "Default" folder will be created and all playlists placed in this folder.<br />
<br />
The basic usage is to create folders (right click anywhere on the panel to access this function) and move your playlists within those newly created folders.<br />
Folders can be nested.<br />
Playlists and folders can be moved (e.g. Drag & Dropped) to their desired location within the hierarchy.<br />
[[Image:Foo_plorg_vis.png|thumb|right|260px|Playlist Organizer Visual status of playlists]]<br />
==Visual Indication for playlists==<br />
<br />
Based on the general or customized color scheme, foo_playlist_organizer will give an indication of Selected, Active and Playing playlists, as well as the source of Drag & Drop operations.<br />
<br />
Please note that Selected and Active playlists will be kept equal (except for instance when selecting folders) when the "Activate on single click" option is chosen.<br />
<br />
==Windows Management==<br />
Using foo_plorg as a standalone (popup) window may lead to losing part of your playlists organization if some changes (addition, deletion, reordering, ...) are applied with other playlist managers while the window is closed. The window startup tries to recognize such situations but it is by nature limited. It is recommended that you use it as a "permanent" panel or UI element rather.<br />
<br />
The last known tree configuration is however memorized and will be recalled when a new panel or UI element instance is created, so that the tree can be somehow rebuilt.<br />
<br />
=Drag & Drop=<br />
==Basic Drag & Drop==<br />
Basic drag & drop is triggered by selecting an item and keeping the left button presssed. A visual indication (dotted line around the item, small square below the mouse pointer) will be given that dragging has taken place.<br />
The selected item can be moved to the desired location and a visual indication (Colored insertion mark or rectangle for folders) of the drop target. Releasing the mouse button will move the dragged item in the requested location.<br />
===Note:===<br />
* During a Drag & Drop operation, folders will expand after a short delay to expand their contents<br />
* Automatic scrolling of the treeview is triggered when the mouse approaches the top or bottom of the treeview.<br />
* Folders cannot be dropped into their childrens<br />
* Drag & Drop can take place across foobar windows (for instance in the playlist view), and also to other applications or windows (See ''Exporting playlists or contents'' below)<br />
* The contents of a playlist can be added to another playlist, when selected as the target of a drop operation. A '''+''' sign will appear under the mouse cursor to indicate that this mode is active. Please note that when the target playlist is locked for some reason (e.g. autoplaylists), no content can be added. A visual indication (small circle) is provided in this case below the mouse cursor.<br />
<br />
==Exporting playlists==<br />
Playlists selected as the source of a drag & drop operations can be exported to windows folder (or potentially other applications). Export uses the .fpl format to create playlists in the dropped location.<br />
Playlist contents (i.e. tracks) can be exported as well but only when the Ctrl key is pressed ''at the start'' of the dragging operation, in which case the files will be copied to the target location.<br />
<br />
==Importing playlists or content==<br />
Similarly, foo_playlist_organizer can act as the target of a drag & drop operation initiated in other foobar windows, windows explorer or other applications. The behavior in this case is similar to the basic drag & drop and a visual indication of the target location will be given, together with an indication in the status bar that content is being imported.<br />
===Note===<br />
* The .fpl format is recognized as a valid source and playlists names will be preserved in this case.For other sources (e.g. other playlists formats, tracks, ...) a new playlist will be generated with some ''intelligent'' name generation based on similar fields (e.g. artist, album, genre, ...) found in the tracks being imported.<br />
<br />
=Context Menu=<br />
[[Image:Foo_plorg_contextmenu.png|thumb|left|240px|Playlist Organizer Context Menu]]<br />
A context menu is available from everywhere in the treeview, from a mouse right click or using the '''Alt+Keydown''' short cut.<br />
Options are the following :<br />
<br />
===Activate===<br />
Will activate the chosen playlist. Note that activation happens automatically when "Activate on single click" is chosen in the preferences page. This option is also available using the '''Enter''' key. <br />
<br />
===Rename===<br />
Will rename the selected playlist or folder. This option is also available using the '''F2''' key.<br />
<br />
===Remove===<br />
Will remove (delete) the selected playlist or folder. This option is also available using the '''Del''' key.<br />
Note that folders cannot be removed while they still contain playlists or other folders.<br />
<br />
===Sort===<br />
<br />
Will sort the content of the selected folder alphabetically.<br />
<br />
===Autoplaylist (or lock) properties===<br />
<br />
Will give access to the properties of an autoplaylist (when selected) or whatever is provided for other playlist locks.<br />
<br />
===Contents===<br />
<br />
Will give access to the standard context menu, based on the content of the selected playlist.<br />
<br />
===Options===<br />
<br />
Enables the customization of the Treeview appearance (Playlist information to show on the right side, Framestyle and Colors).<br />
<br />
The '''Show Playlist''' entry enables to select between Number of items, Duration, Size or Nothing.<br />
<br />
Please note that customizable colors are limited to Text, Background, Background (selected) and Active playlist, in order to remain consistent with the standard DUI color scheme. For CUI, the Active playlist colors defaults to the custom item frame color (See CUI standard color preferences).<br />
<br />
A "Reset" option is available to revert to the standard colors, frame style and item count.<br />
<br />
===Preferences===<br />
<br />
Will link to the general preferences page.<br />
<br />
===Restore===<br />
<br />
This entry will present the list of previously deleted playlists and enable to restore them. A menu entry ("Clear History") is available at the bottom of the list and will permanently delete the playlists. Note that the history is not remembered across session and deleted playlists will be permanently lost if foobar is closed.<br />
<br />
===Create Playlist, Create Folder===<br />
<br />
These options will create new playlist and folders. Note that the newly created playlist or folder will be positioned after a currently selected playlist or as the first child of a currently selected folder.<br />
<br />
==Note==<br />
* When activated with the the '''Alt+Keydown''' shortcut, regular shortcuts are available for each of the menu entries (underlined letter, see picture for details).<br />
<br />
=Preferences=<br />
[[Image:Foo_plorg_preferences.png|right|thumb|484px|Playlist Organizer Preferences]]<br />
The preferences page is available from the preferences dialog (General->Playlist Organizer) and provides with the following options.<br />
==Behavior==<br />
* '''Activate on single click''' will activate (e.g. make visible on the playlist renderer) the selected playlist on a single click. Please note that when this option is selected and a playlist is activated by other means (for example the standard playlist switcher), it will be automatically selected and thus made visible as a result of the standard treeview behavior. <br />
* '''Play on double click''' will play the next item (according to the currently selected playback order) in the selected playlist.<br />
* '''Make playing playlist visible on activation''' will ensure that the playing playlist is visible when activated (for instance when double clicking on the status bar). This option only make sense when "Activate on single click" is unchecked.<br />
==Nodes==<br />
* '''Title formatting''' enables the customization of how playlists and folders are displayed in the treeview. The formatting of nodes uses foobar [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Titleformat_Reference formatting language] and the following variables are available : <br />
**''%node_name%'' is the name of the node, either a playlist or a folder.<br />
**''%is_folder%'' is a boolean value for use in ''$if( ...)'' expressions and is true when the node is a folder.<br />
**''%count%'' will provide the number of children (folders or playlists) for each folder or the number of items for playlists.<br />
**''%playlist_duration%'' will provide the duration of playlists.<br />
**''%playlist_size%'' will provide the size of playlists (in kB, MB or GB).<br />
<br />
<br />
The default formatting string is ''%node_name%$if(%is_folder%,' ['%count%']',)'' and will give an indication of the number of children (folders or playlists) for each folder in the tree.<br />
<br />
Another popular string is ''%node_name%$if($and(%is_folder%,$strcmp(%count%,0)),' []')'' which will not show the children count but just provide an indication of empty folders.<br />
<br />
=Change Log=<br />
* '''Upcoming - tbc'''<br />
** Fixed improper behavior during copy/paste operations by core uie mgt.<br />
* '''V2.6''' [2015-10-13]<br />
** Recompiled with the latest SDK (2015-08-03)<br />
* '''V2.4''' [2011-05-05]<br />
** Changed shared selection type as caller_playlist_manager and revisited shared selection management<br />
* '''V2.3''' [2011-05-03]<br />
** Fixed small cursor glitch after folder expansion<br />
** Fixed some menu entries skipped (standard "contents" menu)during their execution<br />
** Checked behavior for nicer "Library Viewer Selection" playlist management (with Facets)<br />
* '''V2.2''' [2011-04-26]<br />
** Fixed [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705&view=findpost&p=753430 this bug]<br />
* '''V2.1''' [2011-04-25]<br />
** Re-engineering of drag&drop operations, Various bugfix<br />
* '''V2.0''' [2011-04-23]''' Do Not use'''<br />
** Ctrl-key is no longer needed to add tracks to a playlist and it's behavior has been merged with the standard one, depending on the mouse position. <br />
* '''V1.9.1''' [2011-04-16]<br />
** Recompiled with /MD run time library option.<br />
* '''V1.9''' [2011-04-15]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
* '''V1.8''' [2010-10-21]<br />
** Selected playlist is now unchanged after dropping files into a playlist from external source or other panel<br />
** Fixed Alt+F4 Key behavior<br />
* '''V1.7''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
** Implemented shared selection management<br />
* '''V1.6''' [2010-10-03]<br />
** Provide real lock name instead of "Lock Properties"<br />
** Fixed keyboard shortcuts not working in CUI when poo_plorg had focus<br />
* '''V1.5''' [2010-10-01]<br />
** New option in contexte menu to show playlist Duration and Size<br />
** New variables in node titleformatting to show playlist Duration and Size<br />
** Replaced %children_count% with %count% (available for playlists and folders) in node titleformatting<br />
** Included 'Show Playlist' reset to default (item count) in Options->Reset menu<br />
** Fixed erratic behavior of selection after a playlist is removed<br />
* '''V1.4''' [2010-09-26]<br />
** Simple Recompilation<br />
* '''V1.3''' [2010-08-21]<br />
** Fixed preferences appearing in so called "Broken Components" section (in Foobar V1.1)<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.2''' [2010-05-22]<br />
** Fixed bug in standard context menu activation<br />
** Removed selection of target playlist when copying content<br />
* '''V1.1''' [2010-05-20]<br />
** Fixed bug in playing playlist detection<br />
** Hack to replace "Filter Results" playlist (CUI) next to "Filter Results (Playback)" playlist<br />
* '''V1.0''' [2010-05-15]<br />
** '''1.0.1''' Fixed minor bug in colors of active playlist not refreshed after activation when clicking on the status bar.<br />
** Reworked Drag & drop and introduce content copy from one playlist to another (with Ctrl Key), or copy inside a playlist when Drag & Drop is from "external" source<br />
** Introduced titleformatting script for nodes (See Preferences page)<br />
** Memorized last known tree configuration for recall when new instance is initialized<br />
** Eliminated flickering during single click and resize (to be confirmed on Vista/Seven)<br />
** Implemented options to restore deleted playlists<br />
** Fixed Reset function not working in preferences<br />
** Forced playlist activation (after double click) when "Play on double click" option is selected and "Playback follow cursor" is not selected<br />
** Added indication of external drop operations in status bar<br />
** Autonamed newly created playlists and folders<br />
** Ensured active playlist is selected at initialization<br />
** Fixed dialog not getting focus when using Tab key<br />
** Reworked tree display (rectangles mgt.)<br />
** Fixed bug in framestyle setting<br />
** Fixed bug (with potential crash) in accented characters display<br />
** Miscellaneous bug fixes and improvements<br />
* '''V0.9'''<br />
** Implemented external drag & drop support (Thanks kerpondile !)<br />
** Fixed preferences page activated from 1st item of standard context menu<br />
** Fixed improper colors on selection (drop highlight) rectangle<br />
* '''V0.8'''<br />
** '''0.8.3''' Fixed glitch in active item display. Applied theme. Introduced a new option to make playing playlist visible upon activation. Fixed background color of preferences page.<br />
** '''0.8.2''' Fixed crash in debug mode due to resize called before window activation (OnInit).<br />
** '''0.8.1''' CUI colors when not restored properly after unselecting custom background color <br />
** Fixed playback continuation (after double click) happening in same playlist when "Play on double click" option is selected and "Playback follow cursor" is not selected<br />
** Fixed improper display of playlists or folders containing "&"<br />
** Improved look for Vista/seven (Custom Draw for all items, No lines)<br />
** Added visual indication of playing playlist<br />
* '''V0.6'''<br />
** Fixed DUI context menu not appearing in edit mode<br />
** Neutralized selection of first playlist if clicking on an empty region<br />
** Double click now jumps to next track when "Play on double click" option is selected<br />
* '''V0.5'''<br />
** Fixed unwanted column ui context menu<br />
** Neutralized keyboard shortcuts while editing an item<br />
** Various changes on click/double click handling<br />
* '''V0.4'''<br />
** Added options to hide item count (Context Menu-> Options)<br />
** Tentatively introduced Vista / Seven style (to be confirmed)<br />
** Implemented "Preferences" entry in context menu<br />
** Implemented "Activate on single click" option (Preferences)<br />
** Implemented "Play on double click" option (Preferences)<br />
** Fix glitch with drophightlight rectangle (dotted rectangle sometimes breaks and takes on strange colors)<br />
** Re engineered visual appearance + drag & drop operations, fixed some glitches<br />
** Implemented minimum width/height<br />
** Fixed active playlist not appearing at startup<br />
** Fixed "active playlist" status/color lost after move<br />
** Fixed glitch during window scrolling (drag& drop)<br />
** New border drawing to integrate nicely with DUI<br />
* '''V0.3'''<br />
** Fixed item count not refreshing instantaneously<br />
** Fixed double click not working outside of playlist name<br />
* '''V0.2'''<br />
** Link to this page from the preferences page (Help button)<br />
** Fixed bug in managing (Enter/Delete) keys for label editing<br />
** Make the matching (at startup) of tree content vs. actual playlists more intelligent (usefull for utilization of the popup window)<br />
** Fixed panel appearing twice in column UI layout<br />
* '''V0.1''' [2010-05-03] <br />
** Initial release<br />
<br />
=To Do=<br />
* Check panel always made visible inside tabs<br />
* Implement copy/paste settings across instances<br />
* Synchronize playlist order with tree (on request and maybe automatically)<br />
* Generate super set of contained playlists when activating a folder (maybe)<br />
* Add capability to copy a playlist (create a new one) whith Ctrl Key (for internal drop source)<br />
* check this [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705&view=findpost&p=752994 bug]<br />
* check this [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705&view=findpost&p=734630 bug]<br />
* Provide option to focus on target playlist after D&D (maybe)<br />
* Provide Lockname as a variable<br />
* Improve placement of restored playlist<br />
* Make external dropsource return asynchronous (maybe)<br />
* Eliminate drawing of drophighlighted item (source) on click without dragging (maybe)<br />
* Prevent the panel from appearing in the toolbar menu (CUI)</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2015-10-13T07:42:28Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the ''Windows Imaging Component'' which is included in Windows XP '''SP3''' or higher and in .NET 3.0. The WIC can also be downloaded [http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match any''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using current playlist, with the "inline" option (eg restricting the current playlist content according to the search criteria)<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.6''' [2015-10-13]<br />
** Recompiled with the latest SDK (2015-08-03)<br />
* '''V3.4''' [2012-10-29]<br />
** Adjusted panel height to account for selected font (CUI)<br />
* '''V3.3''' [2012-10-28]<br />
** Adjusted panel height to account for selected font (DUI)<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Playlist_Organizer_(foo_plorg)Foobar2000:Components/Playlist Organizer (foo plorg)2012-11-21T20:50:25Z<p>NEMO7538: /* To Do */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Playlist Organizer (foo plorg)]]<br />
[[Image:Foo_plorg.png|thumb|right|480px|Playlist Organizer Main view]]<br />
<br />
<br />
<br />
=General=<br />
'''foo_plorg''' is a simple component that will let your organize your playlists in a treeview fashion. It is available as either a Column UI panel or an UI element for the default UI. It enables your to create folders, hierarchies and move around folders and playlists by dragging and dropping them wherever you want in the panel.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_plorg here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1).<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 1.9.1 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Install the toolbar as an UI element (Default UI) or a column UI panel. The commands are available with a right click on the panel.<br />
Folders and Playlists be can selected by a left click, then moved and dropped around.<br />
<br />
=Usage=<br />
==Basic Usage==<br />
The component implements a treeview control, basically made of playlist and folders.<br />
When the component is used for the first time, a "Default" folder will be created and all playlists placed in this folder.<br />
<br />
The basic usage is to create folders (right click anywhere on the panel to access this function) and move your playlists within those newly created folders.<br />
Folders can be nested.<br />
Playlists and folders can be moved (e.g. Drag & Dropped) to their desired location within the hierarchy.<br />
[[Image:Foo_plorg_vis.png|thumb|right|260px|Playlist Organizer Visual status of playlists]]<br />
==Visual Indication for playlists==<br />
<br />
Based on the general or customized color scheme, foo_playlist_organizer will give an indication of Selected, Active and Playing playlists, as well as the source of Drag & Drop operations.<br />
<br />
Please note that Selected and Active playlists will be kept equal (except for instance when selecting folders) when the "Activate on single click" option is chosen.<br />
<br />
==Windows Management==<br />
Using foo_plorg as a standalone (popup) window may lead to loosing part of your playlists organization if some changes (addition, deletion, reordering, ...) are applied with other playlist managers while the window is closed. The window startup tries to recognize such situations but it is by nature limited. It is recommended that you use it as a "permanent" panel or UI element rather.<br />
<br />
The last known tree configuration is howered memorized and will be recalled when a new panel or UI element instance is created, so that the tree can be somehow rebuilt.<br />
<br />
=Drag & Drop=<br />
==Basic Drag & Drop==<br />
Basic drag & drop is triggered by selecting an item and keeping the left button presssed. A visual indication (dotted line around the item, small square below the mouse pointer) will be given that dragging has taken place.<br />
The selected item can be moved to the desired location and a visual indication (Colored insertion mark or rectangle for folders) of the drop target. Releasing the mouse button will move the dragged item in the requested location.<br />
===Note:===<br />
* During a Drag & Drop operation, folders will expand after a short delay to expand their contents<br />
* Automatic scrolling of the treeview is triggered when the mouse approaches the top or bottom of the treeview.<br />
* Folders cannot be dropped into their childrens<br />
* Drag & Drop can take place across foobar windows (for instance in the playlist view), and also to other applications or windows (See ''Exporting playlists or contents'' below)<br />
* The contents of a playlist can be added to another playlist, when selected as the target of a drop operation. A '''+''' sign will appear under the mouse cursor to indicate that this mode is active. Please note that when the target playlist is locked for some reason (e.g. autoplaylists), no content can be added. A visual indication (small circle) is provided in this case below the mouse cursor.<br />
<br />
==Exporting playlists==<br />
Playlists selected as the source of a drag & drop operations can be exported to windows folder (or potentially other applications). Export uses the .fpl format to create playlists in the dropped location.<br />
Playlist contents (i.e. tracks) can be exported as well but only when the Ctrl key is pressed ''at the start'' of the dragging operation, in which case the files will be copied to the target location.<br />
<br />
==Importing playlists or content==<br />
Similarly, foo_playlist_organizer can act as the target of a drag & drop operation initiated in other foobar windows, windows explorer or other applications. The behavior in this case is similar to the basic drag & drop and a visual indication of the target location will be given, together with an indication in the status bar that content is being imported.<br />
===Note===<br />
* The .fpl format is recognized as a valid source and playlists names will be preserved in this case.For other sources (e.g. other playlists formats, tracks, ...) a new playlist will be generated with some ''intelligent'' name generation based on similar fields (e.g. artist, album, genre, ...) found in the tracks being imported.<br />
<br />
=Context Menu=<br />
[[Image:Foo_plorg_contextmenu.png|thumb|left|240px|Playlist Organizer Context Menu]]<br />
A context menu is available from everywhere in the treeview, from a mouse right click or using the '''Alt+Keydown''' short cut.<br />
Options are the following :<br />
<br />
===Activate===<br />
Will activate the chosen playlist. Note that activation happens automatically when "Activate on single click" is chosen in the preferences page. This option is also available using the '''Enter''' key. <br />
<br />
===Rename===<br />
Will rename the selected playlist or folder. This option is also available using the '''F2''' key.<br />
<br />
===Remove===<br />
Will remove (delete) the selected playlist or folder. This option is also available using the '''Del''' key.<br />
Note that folders cannot be removed while they still contain playlists or other folders.<br />
<br />
===Sort===<br />
<br />
Will sort the content of the selected folder alphabetically.<br />
<br />
===Autoplaylist (or lock) properties===<br />
<br />
Will give access to the properties of an autoplaylist (when selected) or whatever is provided for other playlist locks.<br />
<br />
===Contents===<br />
<br />
Will give access to the standard context menu, based on the content of the selected playlist.<br />
<br />
===Options===<br />
<br />
Enables the customization of the Treeview appearance (Playlist information to show on the right side, Framestyle and Colors).<br />
<br />
The '''Show Playlist''' entry enables to select between Number of items, Duration, Size or Nothing.<br />
<br />
Please note that customizable colors are limited to Text, Background, Background (selected) and Active playlist, in order to remain consistent with the standard DUI color scheme. For CUI, the Active playlist colors defaults to the custom item frame color (See CUI standard color preferences).<br />
<br />
A "Reset" option is available to revert to the standard colors, frame style and item count.<br />
<br />
===Preferences===<br />
<br />
Will link to the general preferences page.<br />
<br />
===Restore===<br />
<br />
This entry will present the list of previously deleted playlists and enable to restore them. A menu entry ("Clear History") is available at the bottom of the list and will permanently delete the playlists. Note that the history is not remembered across session and deleted playlists will be permanently lost if foobar is closed.<br />
<br />
===Create Playlist, Create Folder===<br />
<br />
These options will create new playlist and folders. Note that the newly created playlist or folder will be positioned after a currently selected playlist or as the first child of a currently selected folder.<br />
<br />
==Note==<br />
* When activated with the the '''Alt+Keydown''' shortcut, regular shortcuts are available for each of the menu entries (underlined letter, see picture for details).<br />
<br />
=Preferences=<br />
[[Image:Foo_plorg_preferences.png|right|thumb|484px|Playlist Organizer Preferences]]<br />
The preferences page is available from the preferences dialog (General->Playlist Organizer) and provides with the following options.<br />
==Behavior==<br />
* '''Activate on single click''' will activate (e.g. make visible on the playlist renderer) the selected playlist on a single click. Please note that when this option is selected and a playlist is activated by other means (for example the standard playlist switcher), it will be automatically selected and thus made visible as a result of the standard treeview behavior. <br />
* '''Play on double click''' will play the next item (according to the currently selected playback order) in the selected playlist.<br />
* '''Make playing playlist visible on activation''' will ensure that the playing playlist is visible when activated (for instance when double clicking on the status bar). This option only make sense when "Activate on single click" is unchecked.<br />
==Nodes==<br />
* '''Title formatting''' enables the customization of how playlists and folders are displayed in the treeview. The formatting of nodes uses foobar [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Titleformat_Reference formatting language] and the following variables are available : <br />
**''%node_name%'' is the name of the node, either a playlist or a folder.<br />
**''%is_folder%'' is a boolean value for use in ''$if( ...)'' expressions and is true when the node is a folder.<br />
**''%count%'' will provide the number of children (folders or playlists) for each folder or the number of items for playlists.<br />
**''%playlist_duration%'' will provide the duration of playlists.<br />
**''%playlist_size%'' will provide the size of playlists (in kB, MB or GB).<br />
<br />
<br />
The default formatting string is ''%node_name%$if(%is_folder%,' ['%count%']',)'' and will give an indication of the number of children (folders or playlists) for each folder in the tree.<br />
<br />
Another popular string is ''%node_name%$if($and(%is_folder%,$strcmp(%count%,0)),' []')'' which will not show the children count but just provide an indication of empty folders.<br />
<br />
=Change Log=<br />
* '''Upcoming'''<br />
** Fixed improper behavior during copy/paste operations by core uie mgt.<br />
* '''V2.4''' [2011-05-05]<br />
** Changed shared selection type as caller_playlist_manager and revisited shared selection management<br />
* '''V2.3''' [2011-05-03]<br />
** Fixed small cursor glitch after folder expansion<br />
** Fixed some menu entries skipped (standard "contents" menu)during their execution<br />
** Checked behavior for nicer "Library Viewer Selection" playlist management (with Facets)<br />
* '''V2.2''' [2011-04-26]<br />
** Fixed [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705&view=findpost&p=753430 this bug]<br />
* '''V2.1''' [2011-04-25]<br />
** Re-engineering of drag&drop operations, Various bugfix<br />
* '''V2.0''' [2011-04-23]''' Do Not use'''<br />
** Ctrl-key is no longer needed to add tracks to a playlist and it's behavior has been merged with the standard one, depending on the mouse position. <br />
* '''V1.9.1''' [2011-04-16]<br />
** Recompiled with /MD run time library option.<br />
* '''V1.9''' [2011-04-15]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
* '''V1.8''' [2010-10-21]<br />
** Selected playlist is now unchanged after dropping files into a playlist from external source or other panel<br />
** Fixed Alt+F4 Key behavior<br />
* '''V1.7''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
** Implemented shared selection management<br />
* '''V1.6''' [2010-10-03]<br />
** Provide real lock name instead of "Lock Properties"<br />
** Fixed keyboard shortcuts not working in CUI when poo_plorg had focus<br />
* '''V1.5''' [2010-10-01]<br />
** New option in contexte menu to show playlist Duration and Size<br />
** New variables in node titleformatting to show playlist Duration and Size<br />
** Replaced %children_count% with %count% (available for playlists and folders) in node titleformatting<br />
** Included 'Show Playlist' reset to default (item count) in Options->Reset menu<br />
** Fixed erratic behavior of selection after a playlist is removed<br />
* '''V1.4''' [2010-09-26]<br />
** Simple Recompilation<br />
* '''V1.3''' [2010-08-21]<br />
** Fixed preferences appearing in so called "Broken Components" section (in Foobar V1.1)<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.2''' [2010-05-22]<br />
** Fixed bug in standard context menu activation<br />
** Removed selection of target playlist when copying content<br />
* '''V1.1''' [2010-05-20]<br />
** Fixed bug in playing playlist detection<br />
** Hack to replace "Filter Results" playlist (CUI) next to "Filter Results (Playback)" playlist<br />
* '''V1.0''' [2010-05-15]<br />
** '''1.0.1''' Fixed minor bug in colors of active playlist not refreshed after activation when clicking on the status bar.<br />
** Reworked Drag & drop and introduce content copy from one playlist to another (with Ctrl Key), or copy inside a playlist when Drag & Drop is from "external" source<br />
** Introduced titleformatting script for nodes (See Preferences page)<br />
** Memorized last known tree configuration for recall when new instance is initialized<br />
** Eliminated flickering during single click and resize (to be confirmed on Vista/Seven)<br />
** Implemented options to restore deleted playlists<br />
** Fixed Reset function not working in preferences<br />
** Forced playlist activation (after double click) when "Play on double click" option is selected and "Playback follow cursor" is not selected<br />
** Added indication of external drop operations in status bar<br />
** Autonamed newly created playlists and folders<br />
** Ensured active playlist is selected at initialization<br />
** Fixed dialog not getting focus when using Tab key<br />
** Reworked tree display (rectangles mgt.)<br />
** Fixed bug in framestyle setting<br />
** Fixed bug (with potential crash) in accented characters display<br />
** Miscellaneous bug fixes and improvements<br />
* '''V0.9'''<br />
** Implemented external drag & drop support (Thanks kerpondile !)<br />
** Fixed preferences page activated from 1st item of standard context menu<br />
** Fixed improper colors on selection (drop highlight) rectangle<br />
* '''V0.8'''<br />
** '''0.8.3''' Fixed glitch in active item display. Applied theme. Introduced a new option to make playing playlist visible upon activation. Fixed background color of preferences page.<br />
** '''0.8.2''' Fixed crash in debug mode due to resize called before window activation (OnInit).<br />
** '''0.8.1''' CUI colors when not restored properly after unselecting custom background color <br />
** Fixed playback continuation (after double click) happening in same playlist when "Play on double click" option is selected and "Playback follow cursor" is not selected<br />
** Fixed improper display of playlists or folders containing "&"<br />
** Improved look for Vista/seven (Custom Draw for all items, No lines)<br />
** Added visual indication of playing playlist<br />
* '''V0.6'''<br />
** Fixed DUI context menu not appearing in edit mode<br />
** Neutralized selection of first playlist if clicking on an empty region<br />
** Double click now jumps to next track when "Play on double click" option is selected<br />
* '''V0.5'''<br />
** Fixed unwanted column ui context menu<br />
** Neutralized keyboard shortcuts while editing an item<br />
** Various changes on click/double click handling<br />
* '''V0.4'''<br />
** Added options to hide item count (Context Menu-> Options)<br />
** Tentatively introduced Vista / Seven style (to be confirmed)<br />
** Implemented "Preferences" entry in context menu<br />
** Implemented "Activate on single click" option (Preferences)<br />
** Implemented "Play on double click" option (Preferences)<br />
** Fix glitch with drophightlight rectangle (dotted rectangle sometimes breaks and takes on strange colors)<br />
** Re engineered visual appearance + drag & drop operations, fixed some glitches<br />
** Implemented minimum width/height<br />
** Fixed active playlist not appearing at startup<br />
** Fixed "active playlist" status/color lost after move<br />
** Fixed glitch during window scrolling (drag& drop)<br />
** New border drawing to integrate nicely with DUI<br />
* '''V0.3'''<br />
** Fixed item count not refreshing instantaneously<br />
** Fixed double click not working outside of playlist name<br />
* '''V0.2'''<br />
** Link to this page from the preferences page (Help button)<br />
** Fixed bug in managing (Enter/Delete) keys for label editing<br />
** Make the matching (at startup) of tree content vs. actual playlists more intelligent (usefull for utilization of the popup window)<br />
** Fixed panel appearing twice in column UI layout<br />
* '''V0.1''' [2010-05-03] <br />
** Initial release<br />
<br />
=To Do=<br />
* Check panel always made visible inside tabs<br />
* Implement copy/paste settings across instances<br />
* Synchronize playlist order with tree (on request and maybe automatically)<br />
* Generate super set of contained playlists when activating a folder (maybe)<br />
* Add capability to copy a playlist (create a new one) whith Ctrl Key (for internal drop source)<br />
* check this [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705&view=findpost&p=752994 bug]<br />
* check this [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705&view=findpost&p=734630 bug]<br />
* Provide option to focus on target playlist after D&D (maybe)<br />
* Provide Lockname as a variable<br />
* Improve placement of restored playlist<br />
* Make external dropsource return asynchronous (maybe)<br />
* Eliminate drawing of drophighlighted item (source) on click without dragging (maybe)<br />
* Prevent the panel from appearing in the toolbar menu (CUI)</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2012-10-29T16:50:59Z<p>NEMO7538: /* To do */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the ''Windows Imaging Component'' which is included in Windows XP '''SP3''' or higher and in .NET 3.0. The WIC can also be downloaded [http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using current playlist, with the "inline" option (eg restricting the current playlist content according to the search criteria)<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.4''' [2012-10-29]<br />
** Adjusted panel height to account for selected font (CUI)<br />
* '''V3.3''' [2012-10-28]<br />
** Adjusted panel height to account for selected font (DUI)<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2012-10-29T16:50:46Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the ''Windows Imaging Component'' which is included in Windows XP '''SP3''' or higher and in .NET 3.0. The WIC can also be downloaded [http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using current playlist, with the "inline" option (eg restricting the current playlist content according to the search criteria)<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.4''' [2012-10-29]<br />
** Adjusted panel height to account for selected font (CUI)<br />
* '''V3.3''' [2012-10-28]<br />
** Adjusted panel height to account for selected font (DUI)<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Fix vertical resizing issue (account for container windows height) <-- for CUI (Done for DUI)<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2012-10-29T16:50:36Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the ''Windows Imaging Component'' which is included in Windows XP '''SP3''' or higher and in .NET 3.0. The WIC can also be downloaded [http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using current playlist, with the "inline" option (eg restricting the current playlist content according to the search criteria)<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.3''' [2012-10-29]<br />
** Adjusted panel height to account for selected font (CUI)<br />
* '''V3.3''' [2012-10-28]<br />
** Adjusted panel height to account for selected font (DUI)<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Fix vertical resizing issue (account for container windows height) <-- for CUI (Done for DUI)<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2012-10-29T06:54:59Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the ''Windows Imaging Component'' which is included in Windows XP '''SP3''' or higher and in .NET 3.0. The WIC can also be downloaded [http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using current playlist, with the "inline" option (eg restricting the current playlist content according to the search criteria)<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.3''' [2012-10-28]<br />
** Adjusted panel height to account for selected font<br />
:'''Requires a restart or changes to the layout to take effect in CUI when fonts are changed'''<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Fix vertical resizing issue (account for container windows height) <-- for CUI (Done for DUI)<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2012-10-29T06:53:43Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the ''Windows Imaging Component'' which is included in Windows XP '''SP3''' or higher and in .NET 3.0. The WIC can also be downloaded [http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using current playlist, with the "inline" option (eg restricting the current playlist content according to the search criteria)<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.3''' [2012-10-28]<br />
** Adjusted panel height to account for selected font<br />
'''Requires a restart or changes to the layout to take effect in CUI when fonts are changed'''<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Fix vertical resizing issue (account for container windows height) <-- for CUI (Done for DUI)<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2012-10-28T20:48:42Z<p>NEMO7538: /* To do */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the ''Windows Imaging Component'' which is included in Windows XP '''SP3''' or higher and in .NET 3.0. The WIC can also be downloaded [http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using current playlist, with the "inline" option (eg restricting the current playlist content according to the search criteria)<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.3''' [2012-10-28]<br />
** Adjusted panel height to account for selected font '''(Requires restart in CUI)'''<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Fix vertical resizing issue (account for container windows height) <-- for CUI (Done for DUI)<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2012-10-28T20:48:04Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the ''Windows Imaging Component'' which is included in Windows XP '''SP3''' or higher and in .NET 3.0. The WIC can also be downloaded [http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using current playlist, with the "inline" option (eg restricting the current playlist content according to the search criteria)<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.3''' [2012-10-28]<br />
** Adjusted panel height to account for selected font '''(Requires restart in CUI)'''<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Fix vertical resizing issue (account for container windows height)<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2012-10-13T07:51:39Z<p>NEMO7538: /* To do */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the ''Windows Imaging Component'' which is included in Windows XP '''SP3''' or higher and in .NET 3.0. The WIC can also be downloaded [http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using current playlist, with the "inline" option (eg restricting the current playlist content according to the search criteria)<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Fix vertical resizing issue (account for container windows height)<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2012-08-06T13:18:14Z<p>NEMO7538: </p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the ''Windows Imaging Component'' which is included in Windows XP '''SP3''' or higher and in .NET 3.0. The WIC can also be downloaded [http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using current playlist, with the "inline" option (eg restricting the current playlist content according to the search criteria)<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-06-19T16:27:25Z<p>NEMO7538: /* Requirements */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the ''Windows Imaging Component'' which is included in Windows XP '''SP3''' or higher and in .NET 3.0. The WIC can also be downloaded [http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-06-19T16:27:12Z<p>NEMO7538: /* Requirements */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the ''Windows Imaging Component'' which is included in Windows XP '''SP3''' or higher and in .NET 3.0.The WIC can also be downloaded [http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-06-19T16:26:52Z<p>NEMO7538: /* Requirements */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the ''Windows Imaging Component'' which is included in Windows XP SP[b]3[/b] or higher and in .NET 3.0.The WIC can also be downloaded [http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-06-19T16:26:28Z<p>NEMO7538: /* Requirements */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the [i]Windows Imaging Component[/i] which is included in Windows XP SP[b]3[/b] or higher and in .NET 3.0.The WIC can also be downloaded [http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-06-19T16:26:13Z<p>NEMO7538: /* Requirements */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* Quicksearch utilizes the [i]Windows Imaging Component[/i] which is included in Windows XP SP[b]3[/b] or higher and in .NET 3.0.The WIC can also be downloaded <br />
[http://www.microsoft.com/downloads/en/details.aspx?FamilyId=8E011506-6307-445B-B950-215DEF45DDD8&displaylang=en here] separately.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-29T08:35:16Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows initialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-29T08:34:56Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
** Fixed bug in text selection (only showing last 16 chars) during windows intialization<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-29T07:26:28Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.2''' [2011-05-29]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-28T13:48:10Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.2''' [Not yet released]<br />
** Added font alignment with default font for DUI and Common (list items) for CUI<br />
** Fixed bug in feeding history when same entry already present<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-26T15:49:39Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.2''' [Not yet released]<br />
** Added font alignement with default font for DUI and Common (list items) for CUI<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-25T12:04:30Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.2''' [Not yet released]<br />
** Added font alignement with default font for DUI<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-23T21:44:58Z<p>NEMO7538: /* Search configuration */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option. Please note that wildcards (e.g. '*' or '?') can be used in this mode.<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-23T21:40:20Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.1''' [2011-05-23]<br />
** Fixed crash happening in rare circumstances<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-22T21:09:49Z<p>NEMO7538: /* Requirements */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-22T21:02:14Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-22T20:54:42Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.0''' [Not yet released]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-22T20:46:13Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.0''' [2011-05-22]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-22T20:40:13Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.0''' [Not yet released]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Reworked autoplaylist client, now more robust<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-22T20:38:47Z<p>NEMO7538: /* History and Favorites */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will re-execute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history (or favorites)and will be recalled together with the search criteria, overriding current parameters<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for re-execution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.0''' [Not yet released]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-22T20:37:30Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.0''' [Not yet released]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Changed icon for search in all playlists<br />
** Visual configuration is now saved independently for each autoplaylist client<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=File:QsIcon-AllPlaylists.pngFile:QsIcon-AllPlaylists.png2011-05-22T20:26:00Z<p>NEMO7538: uploaded a new version of "File:QsIcon-AllPlaylists.png"</p>
<hr />
<div></div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-22T20:04:57Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V3.0''' [Not yet released]<br />
** Reworked history recall features, now overrides current search parameters<br />
** Changed icon for search in all playlists<br />
** Various bugs fixed<br />
** General code restructuring<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-20T19:32:10Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-20T19:31:43Z<p>NEMO7538: /* Basic usage */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created ,according to the corresponding toolbar menu options or depending on the special keys used to trigger the search.<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-20T19:30:43Z<p>NEMO7538: /* Toolbar Icon Status */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created (according to the corresponding toolbar menu options or depending on the special keys used to trigger the search).<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon provides an indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Playlist_Organizer_(foo_plorg)Foobar2000:Components/Playlist Organizer (foo plorg)2011-05-19T06:57:06Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Playlist Organizer (foo plorg)]]<br />
[[Image:Foo_plorg.png|thumb|right|480px|Playlist Organizer Main view]]<br />
<br />
<br />
<br />
=General=<br />
'''foo_plorg''' is a simple component that will let your organize your playlists in a treeview fashion. It is available as either a Column UI panel or an UI element for the default UI. It enables your to create folders, hierarchies and move around folders and playlists by dragging and dropping them wherever you want in the panel.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_plorg here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1).<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 1.9.1 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Install the toolbar as an UI element (Default UI) or a column UI panel. The commands are available with a right click on the panel.<br />
Folders and Playlists be can selected by a left click, then moved and dropped around.<br />
<br />
=Usage=<br />
==Basic Usage==<br />
The component implements a treeview control, basically made of playlist and folders.<br />
When the component is used for the first time, a "Default" folder will be created and all playlists placed in this folder.<br />
<br />
The basic usage is to create folders (right click anywhere on the panel to access this function) and move your playlists within those newly created folders.<br />
Folders can be nested.<br />
Playlists and folders can be moved (e.g. Drag & Dropped) to their desired location within the hierarchy.<br />
[[Image:Foo_plorg_vis.png|thumb|right|260px|Playlist Organizer Visual status of playlists]]<br />
==Visual Indication for playlists==<br />
<br />
Based on the general or customized color scheme, foo_playlist_organizer will give an indication of Selected, Active and Playing playlists, as well as the source of Drag & Drop operations.<br />
<br />
Please note that Selected and Active playlists will be kept equal (except for instance when selecting folders) when the "Activate on single click" option is chosen.<br />
<br />
==Windows Management==<br />
Using foo_plorg as a standalone (popup) window may lead to loosing part of your playlists organization if some changes (addition, deletion, reordering, ...) are applied with other playlist managers while the window is closed. The window startup tries to recognize such situations but it is by nature limited. It is recommended that you use it as a "permanent" panel or UI element rather.<br />
<br />
The last known tree configuration is howered memorized and will be recalled when a new panel or UI element instance is created, so that the tree can be somehow rebuilt.<br />
<br />
=Drag & Drop=<br />
==Basic Drag & Drop==<br />
Basic drag & drop is triggered by selecting an item and keeping the left button presssed. A visual indication (dotted line around the item, small square below the mouse pointer) will be given that dragging has taken place.<br />
The selected item can be moved to the desired location and a visual indication (Colored insertion mark or rectangle for folders) of the drop target. Releasing the mouse button will move the dragged item in the requested location.<br />
===Note:===<br />
* During a Drag & Drop operation, folders will expand after a short delay to expand their contents<br />
* Automatic scrolling of the treeview is triggered when the mouse approaches the top or bottom of the treeview.<br />
* Folders cannot be dropped into their childrens<br />
* Drag & Drop can take place across foobar windows (for instance in the playlist view), and also to other applications or windows (See ''Exporting playlists or contents'' below)<br />
* The contents of a playlist can be added to another playlist, when selected as the target of a drop operation. A '''+''' sign will appear under the mouse cursor to indicate that this mode is active. Please note that when the target playlist is locked for some reason (e.g. autoplaylists), no content can be added. A visual indication (small circle) is provided in this case below the mouse cursor.<br />
<br />
==Exporting playlists==<br />
Playlists selected as the source of a drag & drop operations can be exported to windows folder (or potentially other applications). Export uses the .fpl format to create playlists in the dropped location.<br />
Playlist contents (i.e. tracks) can be exported as well but only when the Ctrl key is pressed ''at the start'' of the dragging operation, in which case the files will be copied to the target location.<br />
<br />
==Importing playlists or content==<br />
Similarly, foo_playlist_organizer can act as the target of a drag & drop operation initiated in other foobar windows, windows explorer or other applications. The behavior in this case is similar to the basic drag & drop and a visual indication of the target location will be given, together with an indication in the status bar that content is being imported.<br />
===Note===<br />
* The .fpl format is recognized as a valid source and playlists names will be preserved in this case.For other sources (e.g. other playlists formats, tracks, ...) a new playlist will be generated with some ''intelligent'' name generation based on similar fields (e.g. artist, album, genre, ...) found in the tracks being imported.<br />
<br />
=Context Menu=<br />
[[Image:Foo_plorg_contextmenu.png|thumb|left|240px|Playlist Organizer Context Menu]]<br />
A context menu is available from everywhere in the treeview, from a mouse right click or using the '''Alt+Keydown''' short cut.<br />
Options are the following :<br />
<br />
===Activate===<br />
Will activate the chosen playlist. Note that activation happens automatically when "Activate on single click" is chosen in the preferences page. This option is also available using the '''Enter''' key. <br />
<br />
===Rename===<br />
Will rename the selected playlist or folder. This option is also available using the '''F2''' key.<br />
<br />
===Remove===<br />
Will remove (delete) the selected playlist or folder. This option is also available using the '''Del''' key.<br />
Note that folders cannot be removed while they still contain playlists or other folders.<br />
<br />
===Sort===<br />
<br />
Will sort the content of the selected folder alphabetically.<br />
<br />
===Autoplaylist (or lock) properties===<br />
<br />
Will give access to the properties of an autoplaylist (when selected) or whatever is provided for other playlist locks.<br />
<br />
===Contents===<br />
<br />
Will give access to the standard context menu, based on the content of the selected playlist.<br />
<br />
===Options===<br />
<br />
Enables the customization of the Treeview appearance (Playlist information to show on the right side, Framestyle and Colors).<br />
<br />
The '''Show Playlist''' entry enables to select between Number of items, Duration, Size or Nothing.<br />
<br />
Please note that customizable colors are limited to Text, Background, Background (selected) and Active playlist, in order to remain consistent with the standard DUI color scheme. For CUI, the Active playlist colors defaults to the custom item frame color (See CUI standard color preferences).<br />
<br />
A "Reset" option is available to revert to the standard colors, frame style and item count.<br />
<br />
===Preferences===<br />
<br />
Will link to the general preferences page.<br />
<br />
===Restore===<br />
<br />
This entry will present the list of previously deleted playlists and enable to restore them. A menu entry ("Clear History") is available at the bottom of the list and will permanently delete the playlists. Note that the history is not remembered across session and deleted playlists will be permanently lost if foobar is closed.<br />
<br />
===Create Playlist, Create Folder===<br />
<br />
These options will create new playlist and folders. Note that the newly created playlist or folder will be positioned after a currently selected playlist or as the first child of a currently selected folder.<br />
<br />
==Note==<br />
* When activated with the the '''Alt+Keydown''' shortcut, regular shortcuts are available for each of the menu entries (underlined letter, see picture for details).<br />
<br />
=Preferences=<br />
[[Image:Foo_plorg_preferences.png|right|thumb|484px|Playlist Organizer Preferences]]<br />
The preferences page is available from the preferences dialog (General->Playlist Organizer) and provides with the following options.<br />
==Behavior==<br />
* '''Activate on single click''' will activate (e.g. make visible on the playlist renderer) the selected playlist on a single click. Please note that when this option is selected and a playlist is activated by other means (for example the standard playlist switcher), it will be automatically selected and thus made visible as a result of the standard treeview behavior. <br />
* '''Play on double click''' will play the next item (according to the currently selected playback order) in the selected playlist.<br />
* '''Make playing playlist visible on activation''' will ensure that the playing playlist is visible when activated (for instance when double clicking on the status bar). This option only make sense when "Activate on single click" is unchecked.<br />
==Nodes==<br />
* '''Title formatting''' enables the customization of how playlists and folders are displayed in the treeview. The formatting of nodes uses foobar [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Titleformat_Reference formatting language] and the following variables are available : <br />
**''%node_name%'' is the name of the node, either a playlist or a folder.<br />
**''%is_folder%'' is a boolean value for use in ''$if( ...)'' expressions and is true when the node is a folder.<br />
**''%count%'' will provide the number of children (folders or playlists) for each folder or the number of items for playlists.<br />
**''%playlist_duration%'' will provide the duration of playlists.<br />
**''%playlist_size%'' will provide the size of playlists (in kB, MB or GB).<br />
<br />
<br />
The default formatting string is ''%node_name%$if(%is_folder%,' ['%count%']',)'' and will give an indication of the number of children (folders or playlists) for each folder in the tree.<br />
<br />
Another popular string is ''%node_name%$if($and(%is_folder%,$strcmp(%count%,0)),' []')'' which will not show the children count but just provide an indication of empty folders.<br />
<br />
=Change Log=<br />
* '''Upcoming'''<br />
** Fixed improper behavior during copy/paste operations by core uie mgt.<br />
* '''V2.4''' [2011-05-05]<br />
** Changed shared selection type as caller_playlist_manager and revisited shared selection management<br />
* '''V2.3''' [2011-05-03]<br />
** Fixed small cursor glitch after folder expansion<br />
** Fixed some menu entries skipped (standard "contents" menu)during their execution<br />
** Checked behavior for nicer "Library Viewer Selection" playlist management (with Facets)<br />
* '''V2.2''' [2011-04-26]<br />
** Fixed [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705&view=findpost&p=753430 this bug]<br />
* '''V2.1''' [2011-04-25]<br />
** Re-engineering of drag&drop operations, Various bugfix<br />
* '''V2.0''' [2011-04-23]''' Do Not use'''<br />
** Ctrl-key is no longer needed to add tracks to a playlist and it's behavior has been merged with the standard one, depending on the mouse position. <br />
* '''V1.9.1''' [2011-04-16]<br />
** Recompiled with /MD run time library option.<br />
* '''V1.9''' [2011-04-15]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
* '''V1.8''' [2010-10-21]<br />
** Selected playlist is now unchanged after dropping files into a playlist from external source or other panel<br />
** Fixed Alt+F4 Key behavior<br />
* '''V1.7''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
** Implemented shared selection management<br />
* '''V1.6''' [2010-10-03]<br />
** Provide real lock name instead of "Lock Properties"<br />
** Fixed keyboard shortcuts not working in CUI when poo_plorg had focus<br />
* '''V1.5''' [2010-10-01]<br />
** New option in contexte menu to show playlist Duration and Size<br />
** New variables in node titleformatting to show playlist Duration and Size<br />
** Replaced %children_count% with %count% (available for playlists and folders) in node titleformatting<br />
** Included 'Show Playlist' reset to default (item count) in Options->Reset menu<br />
** Fixed erratic behavior of selection after a playlist is removed<br />
* '''V1.4''' [2010-09-26]<br />
** Simple Recompilation<br />
* '''V1.3''' [2010-08-21]<br />
** Fixed preferences appearing in so called "Broken Components" section (in Foobar V1.1)<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.2''' [2010-05-22]<br />
** Fixed bug in standard context menu activation<br />
** Removed selection of target playlist when copying content<br />
* '''V1.1''' [2010-05-20]<br />
** Fixed bug in playing playlist detection<br />
** Hack to replace "Filter Results" playlist (CUI) next to "Filter Results (Playback)" playlist<br />
* '''V1.0''' [2010-05-15]<br />
** '''1.0.1''' Fixed minor bug in colors of active playlist not refreshed after activation when clicking on the status bar.<br />
** Reworked Drag & drop and introduce content copy from one playlist to another (with Ctrl Key), or copy inside a playlist when Drag & Drop is from "external" source<br />
** Introduced titleformatting script for nodes (See Preferences page)<br />
** Memorized last known tree configuration for recall when new instance is initialized<br />
** Eliminated flickering during single click and resize (to be confirmed on Vista/Seven)<br />
** Implemented options to restore deleted playlists<br />
** Fixed Reset function not working in preferences<br />
** Forced playlist activation (after double click) when "Play on double click" option is selected and "Playback follow cursor" is not selected<br />
** Added indication of external drop operations in status bar<br />
** Autonamed newly created playlists and folders<br />
** Ensured active playlist is selected at initialization<br />
** Fixed dialog not getting focus when using Tab key<br />
** Reworked tree display (rectangles mgt.)<br />
** Fixed bug in framestyle setting<br />
** Fixed bug (with potential crash) in accented characters display<br />
** Miscellaneous bug fixes and improvements<br />
* '''V0.9'''<br />
** Implemented external drag & drop support (Thanks kerpondile !)<br />
** Fixed preferences page activated from 1st item of standard context menu<br />
** Fixed improper colors on selection (drop highlight) rectangle<br />
* '''V0.8'''<br />
** '''0.8.3''' Fixed glitch in active item display. Applied theme. Introduced a new option to make playing playlist visible upon activation. Fixed background color of preferences page.<br />
** '''0.8.2''' Fixed crash in debug mode due to resize called before window activation (OnInit).<br />
** '''0.8.1''' CUI colors when not restored properly after unselecting custom background color <br />
** Fixed playback continuation (after double click) happening in same playlist when "Play on double click" option is selected and "Playback follow cursor" is not selected<br />
** Fixed improper display of playlists or folders containing "&"<br />
** Improved look for Vista/seven (Custom Draw for all items, No lines)<br />
** Added visual indication of playing playlist<br />
* '''V0.6'''<br />
** Fixed DUI context menu not appearing in edit mode<br />
** Neutralized selection of first playlist if clicking on an empty region<br />
** Double click now jumps to next track when "Play on double click" option is selected<br />
* '''V0.5'''<br />
** Fixed unwanted column ui context menu<br />
** Neutralized keyboard shortcuts while editing an item<br />
** Various changes on click/double click handling<br />
* '''V0.4'''<br />
** Added options to hide item count (Context Menu-> Options)<br />
** Tentatively introduced Vista / Seven style (to be confirmed)<br />
** Implemented "Preferences" entry in context menu<br />
** Implemented "Activate on single click" option (Preferences)<br />
** Implemented "Play on double click" option (Preferences)<br />
** Fix glitch with drophightlight rectangle (dotted rectangle sometimes breaks and takes on strange colors)<br />
** Re engineered visual appearance + drag & drop operations, fixed some glitches<br />
** Implemented minimum width/height<br />
** Fixed active playlist not appearing at startup<br />
** Fixed "active playlist" status/color lost after move<br />
** Fixed glitch during window scrolling (drag& drop)<br />
** New border drawing to integrate nicely with DUI<br />
* '''V0.3'''<br />
** Fixed item count not refreshing instantaneously<br />
** Fixed double click not working outside of playlist name<br />
* '''V0.2'''<br />
** Link to this page from the preferences page (Help button)<br />
** Fixed bug in managing (Enter/Delete) keys for label editing<br />
** Make the matching (at startup) of tree content vs. actual playlists more intelligent (usefull for utilization of the popup window)<br />
** Fixed panel appearing twice in column UI layout<br />
* '''V0.1''' [2010-05-03] <br />
** Initial release<br />
<br />
=To Do=<br />
* Implement copy/paste settings across instances<br />
* Synchronize playlist order with tree (on request and maybe automatically)<br />
* Generate super set of contained playlists when activating a folder (maybe)<br />
* Add capability to copy a playlist (create a new one) whith Ctrl Key (for internal drop source)<br />
* check this [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705&view=findpost&p=752994 bug]<br />
* check this [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705&view=findpost&p=734630 bug]<br />
* Provide option to focus on target playlist after D&D (maybe)<br />
* Provide Lockname as a variable<br />
* Improve placement of restored playlist<br />
* Make external dropsource return asynchronous (maybe)<br />
* Eliminate drawing of drophighlighted item (source) on click without dragging (maybe)<br />
* Prevent the panel from appearing in the toolbar menu (CUI)</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Playlist_Organizer_(foo_plorg)Foobar2000:Components/Playlist Organizer (foo plorg)2011-05-19T06:56:44Z<p>NEMO7538: /* To Do */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Playlist Organizer (foo plorg)]]<br />
[[Image:Foo_plorg.png|thumb|right|480px|Playlist Organizer Main view]]<br />
<br />
<br />
<br />
=General=<br />
'''foo_plorg''' is a simple component that will let your organize your playlists in a treeview fashion. It is available as either a Column UI panel or an UI element for the default UI. It enables your to create folders, hierarchies and move around folders and playlists by dragging and dropping them wherever you want in the panel.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_plorg here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1).<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 1.9.1 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Install the toolbar as an UI element (Default UI) or a column UI panel. The commands are available with a right click on the panel.<br />
Folders and Playlists be can selected by a left click, then moved and dropped around.<br />
<br />
=Usage=<br />
==Basic Usage==<br />
The component implements a treeview control, basically made of playlist and folders.<br />
When the component is used for the first time, a "Default" folder will be created and all playlists placed in this folder.<br />
<br />
The basic usage is to create folders (right click anywhere on the panel to access this function) and move your playlists within those newly created folders.<br />
Folders can be nested.<br />
Playlists and folders can be moved (e.g. Drag & Dropped) to their desired location within the hierarchy.<br />
[[Image:Foo_plorg_vis.png|thumb|right|260px|Playlist Organizer Visual status of playlists]]<br />
==Visual Indication for playlists==<br />
<br />
Based on the general or customized color scheme, foo_playlist_organizer will give an indication of Selected, Active and Playing playlists, as well as the source of Drag & Drop operations.<br />
<br />
Please note that Selected and Active playlists will be kept equal (except for instance when selecting folders) when the "Activate on single click" option is chosen.<br />
<br />
==Windows Management==<br />
Using foo_plorg as a standalone (popup) window may lead to loosing part of your playlists organization if some changes (addition, deletion, reordering, ...) are applied with other playlist managers while the window is closed. The window startup tries to recognize such situations but it is by nature limited. It is recommended that you use it as a "permanent" panel or UI element rather.<br />
<br />
The last known tree configuration is howered memorized and will be recalled when a new panel or UI element instance is created, so that the tree can be somehow rebuilt.<br />
<br />
=Drag & Drop=<br />
==Basic Drag & Drop==<br />
Basic drag & drop is triggered by selecting an item and keeping the left button presssed. A visual indication (dotted line around the item, small square below the mouse pointer) will be given that dragging has taken place.<br />
The selected item can be moved to the desired location and a visual indication (Colored insertion mark or rectangle for folders) of the drop target. Releasing the mouse button will move the dragged item in the requested location.<br />
===Note:===<br />
* During a Drag & Drop operation, folders will expand after a short delay to expand their contents<br />
* Automatic scrolling of the treeview is triggered when the mouse approaches the top or bottom of the treeview.<br />
* Folders cannot be dropped into their childrens<br />
* Drag & Drop can take place across foobar windows (for instance in the playlist view), and also to other applications or windows (See ''Exporting playlists or contents'' below)<br />
* The contents of a playlist can be added to another playlist, when selected as the target of a drop operation. A '''+''' sign will appear under the mouse cursor to indicate that this mode is active. Please note that when the target playlist is locked for some reason (e.g. autoplaylists), no content can be added. A visual indication (small circle) is provided in this case below the mouse cursor.<br />
<br />
==Exporting playlists==<br />
Playlists selected as the source of a drag & drop operations can be exported to windows folder (or potentially other applications). Export uses the .fpl format to create playlists in the dropped location.<br />
Playlist contents (i.e. tracks) can be exported as well but only when the Ctrl key is pressed ''at the start'' of the dragging operation, in which case the files will be copied to the target location.<br />
<br />
==Importing playlists or content==<br />
Similarly, foo_playlist_organizer can act as the target of a drag & drop operation initiated in other foobar windows, windows explorer or other applications. The behavior in this case is similar to the basic drag & drop and a visual indication of the target location will be given, together with an indication in the status bar that content is being imported.<br />
===Note===<br />
* The .fpl format is recognized as a valid source and playlists names will be preserved in this case.For other sources (e.g. other playlists formats, tracks, ...) a new playlist will be generated with some ''intelligent'' name generation based on similar fields (e.g. artist, album, genre, ...) found in the tracks being imported.<br />
<br />
=Context Menu=<br />
[[Image:Foo_plorg_contextmenu.png|thumb|left|240px|Playlist Organizer Context Menu]]<br />
A context menu is available from everywhere in the treeview, from a mouse right click or using the '''Alt+Keydown''' short cut.<br />
Options are the following :<br />
<br />
===Activate===<br />
Will activate the chosen playlist. Note that activation happens automatically when "Activate on single click" is chosen in the preferences page. This option is also available using the '''Enter''' key. <br />
<br />
===Rename===<br />
Will rename the selected playlist or folder. This option is also available using the '''F2''' key.<br />
<br />
===Remove===<br />
Will remove (delete) the selected playlist or folder. This option is also available using the '''Del''' key.<br />
Note that folders cannot be removed while they still contain playlists or other folders.<br />
<br />
===Sort===<br />
<br />
Will sort the content of the selected folder alphabetically.<br />
<br />
===Autoplaylist (or lock) properties===<br />
<br />
Will give access to the properties of an autoplaylist (when selected) or whatever is provided for other playlist locks.<br />
<br />
===Contents===<br />
<br />
Will give access to the standard context menu, based on the content of the selected playlist.<br />
<br />
===Options===<br />
<br />
Enables the customization of the Treeview appearance (Playlist information to show on the right side, Framestyle and Colors).<br />
<br />
The '''Show Playlist''' entry enables to select between Number of items, Duration, Size or Nothing.<br />
<br />
Please note that customizable colors are limited to Text, Background, Background (selected) and Active playlist, in order to remain consistent with the standard DUI color scheme. For CUI, the Active playlist colors defaults to the custom item frame color (See CUI standard color preferences).<br />
<br />
A "Reset" option is available to revert to the standard colors, frame style and item count.<br />
<br />
===Preferences===<br />
<br />
Will link to the general preferences page.<br />
<br />
===Restore===<br />
<br />
This entry will present the list of previously deleted playlists and enable to restore them. A menu entry ("Clear History") is available at the bottom of the list and will permanently delete the playlists. Note that the history is not remembered across session and deleted playlists will be permanently lost if foobar is closed.<br />
<br />
===Create Playlist, Create Folder===<br />
<br />
These options will create new playlist and folders. Note that the newly created playlist or folder will be positioned after a currently selected playlist or as the first child of a currently selected folder.<br />
<br />
==Note==<br />
* When activated with the the '''Alt+Keydown''' shortcut, regular shortcuts are available for each of the menu entries (underlined letter, see picture for details).<br />
<br />
=Preferences=<br />
[[Image:Foo_plorg_preferences.png|right|thumb|484px|Playlist Organizer Preferences]]<br />
The preferences page is available from the preferences dialog (General->Playlist Organizer) and provides with the following options.<br />
==Behavior==<br />
* '''Activate on single click''' will activate (e.g. make visible on the playlist renderer) the selected playlist on a single click. Please note that when this option is selected and a playlist is activated by other means (for example the standard playlist switcher), it will be automatically selected and thus made visible as a result of the standard treeview behavior. <br />
* '''Play on double click''' will play the next item (according to the currently selected playback order) in the selected playlist.<br />
* '''Make playing playlist visible on activation''' will ensure that the playing playlist is visible when activated (for instance when double clicking on the status bar). This option only make sense when "Activate on single click" is unchecked.<br />
==Nodes==<br />
* '''Title formatting''' enables the customization of how playlists and folders are displayed in the treeview. The formatting of nodes uses foobar [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Titleformat_Reference formatting language] and the following variables are available : <br />
**''%node_name%'' is the name of the node, either a playlist or a folder.<br />
**''%is_folder%'' is a boolean value for use in ''$if( ...)'' expressions and is true when the node is a folder.<br />
**''%count%'' will provide the number of children (folders or playlists) for each folder or the number of items for playlists.<br />
**''%playlist_duration%'' will provide the duration of playlists.<br />
**''%playlist_size%'' will provide the size of playlists (in kB, MB or GB).<br />
<br />
<br />
The default formatting string is ''%node_name%$if(%is_folder%,' ['%count%']',)'' and will give an indication of the number of children (folders or playlists) for each folder in the tree.<br />
<br />
Another popular string is ''%node_name%$if($and(%is_folder%,$strcmp(%count%,0)),' []')'' which will not show the children count but just provide an indication of empty folders.<br />
<br />
=Change Log=<br />
* '''Upcoming'''<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
* '''V2.4''' [2011-05-05]<br />
** Changed shared selection type as caller_playlist_manager and revisited shared selection management<br />
* '''V2.3''' [2011-05-03]<br />
** Fixed small cursor glitch after folder expansion<br />
** Fixed some menu entries skipped (standard "contents" menu)during their execution<br />
** Checked behavior for nicer "Library Viewer Selection" playlist management (with Facets)<br />
* '''V2.2''' [2011-04-26]<br />
** Fixed [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705&view=findpost&p=753430 this bug]<br />
* '''V2.1''' [2011-04-25]<br />
** Re-engineering of drag&drop operations, Various bugfix<br />
* '''V2.0''' [2011-04-23]''' Do Not use'''<br />
** Ctrl-key is no longer needed to add tracks to a playlist and it's behavior has been merged with the standard one, depending on the mouse position. <br />
* '''V1.9.1''' [2011-04-16]<br />
** Recompiled with /MD run time library option.<br />
* '''V1.9''' [2011-04-15]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
* '''V1.8''' [2010-10-21]<br />
** Selected playlist is now unchanged after dropping files into a playlist from external source or other panel<br />
** Fixed Alt+F4 Key behavior<br />
* '''V1.7''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
** Implemented shared selection management<br />
* '''V1.6''' [2010-10-03]<br />
** Provide real lock name instead of "Lock Properties"<br />
** Fixed keyboard shortcuts not working in CUI when poo_plorg had focus<br />
* '''V1.5''' [2010-10-01]<br />
** New option in contexte menu to show playlist Duration and Size<br />
** New variables in node titleformatting to show playlist Duration and Size<br />
** Replaced %children_count% with %count% (available for playlists and folders) in node titleformatting<br />
** Included 'Show Playlist' reset to default (item count) in Options->Reset menu<br />
** Fixed erratic behavior of selection after a playlist is removed<br />
* '''V1.4''' [2010-09-26]<br />
** Simple Recompilation<br />
* '''V1.3''' [2010-08-21]<br />
** Fixed preferences appearing in so called "Broken Components" section (in Foobar V1.1)<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.2''' [2010-05-22]<br />
** Fixed bug in standard context menu activation<br />
** Removed selection of target playlist when copying content<br />
* '''V1.1''' [2010-05-20]<br />
** Fixed bug in playing playlist detection<br />
** Hack to replace "Filter Results" playlist (CUI) next to "Filter Results (Playback)" playlist<br />
* '''V1.0''' [2010-05-15]<br />
** '''1.0.1''' Fixed minor bug in colors of active playlist not refreshed after activation when clicking on the status bar.<br />
** Reworked Drag & drop and introduce content copy from one playlist to another (with Ctrl Key), or copy inside a playlist when Drag & Drop is from "external" source<br />
** Introduced titleformatting script for nodes (See Preferences page)<br />
** Memorized last known tree configuration for recall when new instance is initialized<br />
** Eliminated flickering during single click and resize (to be confirmed on Vista/Seven)<br />
** Implemented options to restore deleted playlists<br />
** Fixed Reset function not working in preferences<br />
** Forced playlist activation (after double click) when "Play on double click" option is selected and "Playback follow cursor" is not selected<br />
** Added indication of external drop operations in status bar<br />
** Autonamed newly created playlists and folders<br />
** Ensured active playlist is selected at initialization<br />
** Fixed dialog not getting focus when using Tab key<br />
** Reworked tree display (rectangles mgt.)<br />
** Fixed bug in framestyle setting<br />
** Fixed bug (with potential crash) in accented characters display<br />
** Miscellaneous bug fixes and improvements<br />
* '''V0.9'''<br />
** Implemented external drag & drop support (Thanks kerpondile !)<br />
** Fixed preferences page activated from 1st item of standard context menu<br />
** Fixed improper colors on selection (drop highlight) rectangle<br />
* '''V0.8'''<br />
** '''0.8.3''' Fixed glitch in active item display. Applied theme. Introduced a new option to make playing playlist visible upon activation. Fixed background color of preferences page.<br />
** '''0.8.2''' Fixed crash in debug mode due to resize called before window activation (OnInit).<br />
** '''0.8.1''' CUI colors when not restored properly after unselecting custom background color <br />
** Fixed playback continuation (after double click) happening in same playlist when "Play on double click" option is selected and "Playback follow cursor" is not selected<br />
** Fixed improper display of playlists or folders containing "&"<br />
** Improved look for Vista/seven (Custom Draw for all items, No lines)<br />
** Added visual indication of playing playlist<br />
* '''V0.6'''<br />
** Fixed DUI context menu not appearing in edit mode<br />
** Neutralized selection of first playlist if clicking on an empty region<br />
** Double click now jumps to next track when "Play on double click" option is selected<br />
* '''V0.5'''<br />
** Fixed unwanted column ui context menu<br />
** Neutralized keyboard shortcuts while editing an item<br />
** Various changes on click/double click handling<br />
* '''V0.4'''<br />
** Added options to hide item count (Context Menu-> Options)<br />
** Tentatively introduced Vista / Seven style (to be confirmed)<br />
** Implemented "Preferences" entry in context menu<br />
** Implemented "Activate on single click" option (Preferences)<br />
** Implemented "Play on double click" option (Preferences)<br />
** Fix glitch with drophightlight rectangle (dotted rectangle sometimes breaks and takes on strange colors)<br />
** Re engineered visual appearance + drag & drop operations, fixed some glitches<br />
** Implemented minimum width/height<br />
** Fixed active playlist not appearing at startup<br />
** Fixed "active playlist" status/color lost after move<br />
** Fixed glitch during window scrolling (drag& drop)<br />
** New border drawing to integrate nicely with DUI<br />
* '''V0.3'''<br />
** Fixed item count not refreshing instantaneously<br />
** Fixed double click not working outside of playlist name<br />
* '''V0.2'''<br />
** Link to this page from the preferences page (Help button)<br />
** Fixed bug in managing (Enter/Delete) keys for label editing<br />
** Make the matching (at startup) of tree content vs. actual playlists more intelligent (usefull for utilization of the popup window)<br />
** Fixed panel appearing twice in column UI layout<br />
* '''V0.1''' [2010-05-03] <br />
** Initial release<br />
<br />
=To Do=<br />
* Implement copy/paste settings across instances<br />
* Synchronize playlist order with tree (on request and maybe automatically)<br />
* Generate super set of contained playlists when activating a folder (maybe)<br />
* Add capability to copy a playlist (create a new one) whith Ctrl Key (for internal drop source)<br />
* check this [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705&view=findpost&p=752994 bug]<br />
* check this [http://www.hydrogenaudio.org/forums/index.php?showtopic=80705&view=findpost&p=734630 bug]<br />
* Provide option to focus on target playlist after D&D (maybe)<br />
* Provide Lockname as a variable<br />
* Improve placement of restored playlist<br />
* Make external dropsource return asynchronous (maybe)<br />
* Eliminate drawing of drophighlighted item (source) on click without dragging (maybe)<br />
* Prevent the panel from appearing in the toolbar menu (CUI)</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-18T22:33:51Z<p>NEMO7538: /* To do */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created (according to the corresponding toolbar menu options or depending on the special keys used to trigger the search).<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon gives and indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-18T22:33:22Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created (according to the corresponding toolbar menu options or depending on the special keys used to trigger the search).<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon gives and indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V2.14''' [2011-05-19]<br />
** Implemented auto-complete in search pattern based on the content of history<<br />
** Various bugs fixed<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Implement history dropdown<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-18T22:14:39Z<p>NEMO7538: /* Preferences */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created (according to the corresponding toolbar menu options or depending on the special keys used to trigger the search).<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon gives and indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the search history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Implement history dropdown<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-18T22:14:07Z<p>NEMO7538: /* Search ... */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created (according to the corresponding toolbar menu options or depending on the special keys used to trigger the search).<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon gives and indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
'''Autocomplete from history'''<br />
<br />
Enable the appearance of a drop-down list while typing a search string, in order to select the string among previous searches, based on the content of the history.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Implement history dropdown<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=File:QsPreferences.pngFile:QsPreferences.png2011-05-18T22:11:23Z<p>NEMO7538: uploaded a new version of "File:QsPreferences.png"</p>
<hr />
<div></div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-16T15:54:27Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created (according to the corresponding toolbar menu options or depending on the special keys used to trigger the search).<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon gives and indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V2.13''' [2011-05-16]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Implement history dropdown<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-16T14:09:16Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created (according to the corresponding toolbar menu options or depending on the special keys used to trigger the search).<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon gives and indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V2.13''' [not yet released]<br />
** Fixed improper display of dynamic icon, now using 32bpp<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Implement history dropdown<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-16T09:53:16Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created (according to the corresponding toolbar menu options or depending on the special keys used to trigger the search).<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon gives and indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V2.12''' [2011-05-16]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Implement history dropdown<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-16T08:11:42Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created (according to the corresponding toolbar menu options or depending on the special keys used to trigger the search).<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon gives and indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V2.12''' [Not yet released]<br />
** Fixed GDI leak<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Implement history dropdown<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-16T08:10:59Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created (according to the corresponding toolbar menu options or depending on the special keys used to trigger the search).<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon gives and indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V2.11''' [2011-05-15]<br />
** Restored custom bitmap option<br />
** Modified menu style (use bullet for alternative selection)<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Implement history dropdown<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-15T11:14:30Z<p>NEMO7538: /* To do */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created (according to the corresponding toolbar menu options or depending on the special keys used to trigger the search).<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon gives and indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Implement history dropdown<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Implement (playing) backup playlist and related switches<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538https://wiki.hydrogenaud.io/index.php?title=Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)Foobar2000:Components/Quicksearch UI Element (foo quicksearch)2011-05-15T10:12:32Z<p>NEMO7538: /* Change Log */</p>
<hr />
<div>{{fb2k}}<br />
[[Category:foobar2000 3rd-Party Components|Quicksearch UI Element (foo quicksearch)]]<br />
[[Image:QuickSearch3.png|thumb|right|405px|Quick Search]]<br />
=General=<br />
'''foo_quicksearch''' is derived from [http://www.hydrogenaudio.org/forums/index.php?showtopic=44012 foo_uie_quicksearch] and ported to foobar2000 V1.0.x. It is now available as either a Column UI panel or an UI element for the default UI. The version has been rewritten (almost) from scratch to benefit from the new SDK and introduce new features such as autoplaylist generation, full customization of the context menu, ....<br />
<br />
Configuration has also been simplified with separation of general and toolbar customization, and performances have been improved thanks to new features in the SDK.<br />
<br />
===Download link===<br />
The component is available from [http://www.foobar2000.org/components/view/foo_quicksearch here]. Download an place in your foobar components directory (or use the automatic updater with foobar V1.1)<br />
<br />
===Discussion===<br />
Please use [http://www.hydrogenaudio.org/forums/index.php?showtopic=80259 this thread] to provide feedback or report any bug.<br />
<br />
===Requirements===<br />
As of version 2.4 [2011-04-16]:<br />
* Foobar 1.1 (or newer) is required and Column UI 0.3.8.x (Optional). The component will not work with previous versions of Foobar.<br />
* [[http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c32f406a-f8fc-4164-b6eb-5328b8578f03 Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system Microsoft Visual C++ 2010 Redistributable Package] may also be needed if not already present on your system<br />
<br />
===Getting started===<br />
Although the toolbar is highly configurable, the recommended scenario is to just install the toolbar as an UI element (Default UI) or a column UI panel, then type a string and press the enter key to visualize the results. A popup instance of the toolbar can also be activated from the main Menu (Library->Quicksearch).<br />
<br />
If you are using column UI, it is recommended that your remove 'foo_uie_quicksearch' from your components directory.<br />
<br />
=Usage=<br />
<br />
===Basic usage===<br />
A search is triggered by the enter key, using the string typed in the toolbar as the basic criteria.<br />
<br />
The target playlist (as set in the Preferences page) will be fed with the results of the search ... or a new playlist (or autoplaylist) will be created (according to the corresponding toolbar menu options or depending on the special keys used to trigger the search).<br />
<br />
The toolbar is highlighted when the search is not successful.<br />
<br />
===Special Keys===<br />
Pressing "Crtl", "Alt" or "Shift" keys (together with the enter key) will trigger the following processings, regardless of the search parameters that are currently selected :<br />
* Ctrl: Force the creation of a new results playlist<br />
* Ctrl+Shift: Force the creation of a new (results) autoplaylist<br />
* Alt: Force search in the current playlist<br />
* Alt+Shift: Force search in all playlist(except the last search results) <br />
* Shift: Force inline playlist search<br />
* Ctrl+Alt: Force the creation of a new results playlist and use the current playlist as the search source<br />
* Ctrl+Alt+Shift: Force the creation of a new results playlist and use all playlists (except the last search results) as the search source<br />
<br />
===About playlists created with the toolbar===<br />
You can do whatever you want with the playlists that are created when the "New Playlist" or "New Autoplaylist" options are checked in the toolbar menu, except for the restrictions that apply to autoplaylists.<br />
<br />
The "standard" results playlist behaves slightly differently. You can add or remove items or even delete it (it will be recreated automatically). As its contents is controlled by the toolbar,it cannot be renamed in order to avoid the situation where it would have been renamed and its contents changed by the next search.<br />
<br />
===Main menu entry===<br />
A menu entry (Library-->Quicksearch) is available to launch the toolbar in standalone pop-up mode, when the toolbar is not already available (DUI). This entry can be mapped to a keyboard shortcut.<br />
===Main keyboard shortcuts===<br />
Three additional entries are available to be mapped as (main) keyboard shortcuts :<br />
* '''Activate toolbar''' will set focus to the toolbar<br />
* '''Create playlist from last search''' will re execute the last search and create a new playlist<br />
* '''Create autoplaylist from last search''' will re execute the last search and create a new autoplaylist. If the last search was not from the media library, a simple playlist is created instead.<br />
<br />
Note that generated autoplaylists can later be edited to change their content and underlying query (See [[Foobar2000:Components/Quicksearch_UI_Element_(foo_quicksearch)#Autoplaylist_Client|Autoplaylist Client]] below).<br />
<br />
===Context menu===<br />
[[Image:QsContextMenu.png|thumb|right|405px|Quicksearch Context Menu]]<br />
<br />
A context menu is available from the playlist view (Search for same) and will list some tags to be used in order to search in the media library for similar entries. <br />
<br />
The content of the context menu is now fully customizable. Please refer to the "Tagz strings" area of the preferences page for details.<br />
<br />
These context menu entries can be mapped to keyboard shortcuts.<br />
<br />
Please note that the context menu is not available (and grayed) when several entries are selected in the playlist view.<br />
<br />
=Configuration=<br />
==Toolbar Menu==<br />
A toolbar menu is available by (left) clicking on the toolbar icon and provides with the ability to customize search parameters or the look of the toolbar. Options are divided into sections which are described below :<br />
[[Image:QsToolbarMenu.PNG|thumb|left|405px|Quicksearch Toolbar Menu]]<br />
===Search configuration===<br />
'''Search in :'''<br />
<br />
Indicates where to search : <br />
* '''Database''' Will search in the media library<br />
* '''Playlist''' will search in the currently selected playlist<br />
* '''Playlist (inline) ''' will search in the currently selected playlist but will highlight the results in the currently selected playlist. If "Set Focus to search results" is not selected in the preferences page, navigation in the selected results is available through the "Up" and "Down" arrow keys.<br />
* '''All Playlists ''' will search in the contents of all playlist. Please note that the playlist containing the previous search results will be skipped when searching in all playlists.<br />
<br />
'''Tags'''<br />
<br />
Provides with the ability to select in which tags the search will be performed. The contents of this option is customizable in the general preferences page (See "Tagz strings" section).<br />
<br />
'''Match :'''<br />
<br />
Determines what kind of processing will be performed to produce the results, in particular when several keywords are typed :<br />
* '''Match all''' will select tracks if all keywords are found in the tags determined by the "Search in ..." option<br />
* '''Match all''' will select tracks if one of the keywords is found in the tags determined by the "Search ins" option<br />
* '''Exact''' will select tracks if the typed string exactly matches the contents of the tags determined by the "Search in ..." option<br />
* '''Prefix''' will select tracks if when the contents of the tags determined by the "Search in ..." option are starting with the typed string<br />
* '''Extended''' will use the foobar query syntax. Look [http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Query_syntax here] for further details.<br />
<br />
'''Autosearch'''<br />
<br />
Enables automatic searching. The toolbar will automatically (e.g. without the need to press the enter key) trigger a search when this option is selected. The launch of the search is control by a delay that can be tuned in the general Preferences page.<br />
Autosearch is mutually exclusive with "New playlist" and "New autoplaylist" options.<br />
<br />
Please note that the autosearch is not triggered when the searched string has only one character.<br />
<br />
===Results Playlist Management===<br />
These options are mutually exclusive with "Autosearch ..." option. Thee are not available as well for autoplaylist clients.<br />
<br />
'''New Playlist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page. Please note this option is deactivated when "Playlist (inline)" is selected as the source. <br />
<br />
'''New Autoplaylist'''<br />
<br />
Will generate a new playlist instead of sending the results to the "Target Playlist" indicated in the preferences page, and set up this new playlist as an autopaylist, using the transformed search criteria. Please note this option is deactivated when anything else than "Database" is selected as the source and is mutually exclusive with the "New Playlist" option.<br />
<br />
===History and Favorites===<br />
<br />
'''History'''<br />
<br />
This menu entry provides with the list of recent queries. Selecting one of them will reexecute the corresponding search. A visual indication of the source of each search appears in history (From DB=Noting, Playlist=[P], All Playlist=[A], Inline=[I]) after the searched pattern.<br />
<br />
Please note that parameters (Search in ..., Tags ..., Match ...) are saved within the history and will be recalled together with the search criteria.<br />
<br />
An option ("Clear") is provided to clear the history below the list.<br />
<br />
'''Favorites'''<br />
<br />
The search history can be used to flag some entries as favorites. The menu entry provides options :<br />
* to add history items to favorites<br />
* to delete favorites<br />
* to recall one of the favorites searches for reexecution<br />
<br />
===Options and Preferences===<br />
<br />
'''Options'''<br />
<br />
This option enable to customize the look of the toolbar, including :<br />
* Loading a custom bitmap (Must be 2 x 16x20, e.g. hight=16, width=40 with the second part used as the mouseover image. The top left pixel of each part will be used as the transparent color). Selecting this option when a custombitmap is loaded will revert to the standard image.<br />
* Customizing the frame style (None Grey, Sunken).<br />
* Customizing the colors. Default toolbar colors are those set in DUI or CUI preferences, and a custom color can be set for each category (Text and Background ... for normal and errors state). When customized, these options will revert to the default colors if selected.<br />
<br />
'''Options->Reset configuration'''<br />
<br />
This option will revert to the default toolbar configuration, for all the toolbar menu options.<br />
<br />
'''Preferences'''<br />
<br />
Will give access to the general preferences.<br />
<br />
===Notes===<br />
* "New playlist" and "New autoplaylist" options are not compatible with "Inline playlist search" and will be deactivated accordingly.<br />
* "New autoplaylist" cannot be used when searching from an other source than the media library and will be deactivated accordingly.<br />
* You are not allowed to rename the results playlist. It is automatically managed by the plugin.<br />
* Sorting (Foobar Query syntax) is not currently supported.<br />
<br />
==Toolbar Icon Status==<br />
The toolbar icon gives and indication of currently selected options and can take the following appearance :<br />
* [[File:QsIcon-Normal.png]] Standard search in Media Library<br />
* [[File:QsIcon-Autosearch.png]] Autosearch (e.g. search as you type)<br />
* [[File:QsIcon-NewPlaylist.png]] A new playlist will be created<br />
* [[File:QsIcon-NewAutoPlaylist.png]] A new autoplaylist will be created<br />
<br />
* [[File:QsIcon-InPlaylist.png]] Search will take place in the current playlist<br />
* [[File:QsIcon-Error.png]] Autosearch takes place in the current playlist, but there is no active selection. Selecting a playlist different from the search results playlist and reactivating the toolbar will revert to normal search in playlist<br />
* [[File:QsIcon-PlaylistInline.png]] Search will take place using all playlists<br />
* [[File:QsIcon-AllPlaylists.png]] Search will take place using all playlists<br />
<br />
Please note that the corresponding situations may be combined in a single icon to reflect the actual selected search parameters.<br />
<br />
==Preferences==<br />
The general configuration is available from the Preferences menu (under Media Library/Quicksearch) or by selecting "Preferences" from the toolbar Menu. <br />
<br />
Note that the general configuration is now consistent with the standard foobar behavior for preference pages (OK, Cancel and Apply buttons). Changes (including any change made in the Tagz list) are '''not''' taken into account until the OK or Apply buttons are hit. <br />
[[Image:QsPreferences.png|thumb|right|600px|Quick Search Preferences Page]]<br />
Options are divided into sections as follows :<br />
===Search ...===<br />
'''Reset searchstring when successfull'''<br />
<br />
Will blank the string you have typed after a successfull search.<br />
<br />
'''Reset "New Playlist" after execution'''<br />
<br />
Will unselect "New Playlist" or "New Autoplaylist" after execution.<br />
<br />
'''Remove parenthesis from search tags (context menu)'''<br />
<br />
Will automatically remove parenthesis found in tags from the selected track before building the query. Can be usefull to search more globally (e.g. excluding "(Disc 1 ... n)" from the search criteria).<br />
<br />
'''Automatic switch to extended search'''<br />
<br />
Will automatically force the "Match ..." option in the toolbar to "Extended" when a "%" character is typed in the toolbar. Enables easier usage of extended queries.<br />
The "Match ..." option will revert to its previous value if only normal characters are present or if the typing area is cleared.<br />
<br />
'''Autosearch delay'''<br />
<br />
Enables to fine tune the delay which triggers the search when the "Autosearch" option is selected in the toolbar. It is recommended that you set this option to "Slow" if your system is Slow or if you have a large library.<br />
<br />
===Tagz strings===<br />
Enables the customization of strings to look for during a search. The list can be manipulated using the "Add", "Change", "Delete", "Reset", "Up" and "Down" buttons and the fields below the list :<br />
* '''Name''' is the human readable index of the list and will appear in the "Tagz strings ..." menu of the toolbar and in the context menu options<br />
* '''Value''' contains the Tagz language strings used for the search<br />
* '''Context Menu''' will enable the entry in the context menu and keyboard shortcuts mapping.<br />
'''Please note :'''<br />
* The status of the "Add", "Change" and "Delete" buttons is managed to avoid duplicates in the list. Rules are the following :<br />
** You cannot have the same value with two different name<br />
** You cannot have several entries with the same name<br />
* For the strings to appear in Keyboards shortcuts preferences, the "OK" button needs to be hit in Quicksearch Preferences page before moving to the keyboard shortcuts preference pages.<br />
<br />
===Search Results===<br />
'''Target Playlist'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results.<br />
<br />
'''Target Playlist (New)'''<br />
<br />
Indicates the name of the playlist that will be fed with the search results when generating a new playlist or a new autoplaylist.<br />
<br />
'''Append searchstring to playlist name'''<br />
<br />
When selected, the string used for the search will be appended (between brackets) to the playlist name.<br />
<br />
'''Set focus to search results'''<br />
<br />
Will set the focus to the main foobar window after a successful search. Please note that this option is irrelevant when Autosearch is activated.<br />
<br />
'''History size'''<br />
<br />
Indicates the desired length for the search history. Setting this parameter to zero will clear the search history.<br />
<br />
'''Manage Favorites'''<br />
<br />
Indicates whether the management of favorites is desired.<br />
<br />
==Autoplaylist Client==<br />
[[File:PlContextMenu.png|thumb|right|450px|Playlist Context Menu]]<br />
Autoplaylists created with foo_quicksearch can be edited from the context menu (right click) of the playlist manager. <br />
<br />
Activating this entry will pop-up a new instance of the quicksearch toolbar, in order to modify the search parameters. Results are directly fed into the selected playlist.<br />
<br />
Please note that autoplaylists can only lookup in foobar's media library (and not playlists). Some options in the toolbar menu of autoplaylist clients are grayed out accordingly.<br />
<br />
The "New playlist" and "New Autoplaylist" entries are not available in this context, as the results will only be updated in the selected autoplaylist.<br />
<br />
=Change Log=<br />
* '''V2.10''' [2011-05-15]<br />
** Use png icons for better visual effet [(c) Yusuke Kamiyamane]<br />
** Fixed some bugs in autosearch + "in playlist" filer mode<br />
* '''V2.9''' [2011-05-14]<br />
** Reviewed history management in case of recall to acccount for forced parameters<br />
** Provided visual indication of source in history (From DB=Noting, Playlist=[P], All Playlist=[A],Inline=[I]<br />
** Complete Rework of autosearch (as you type ...) from within a playlist with quicksearch toolbar now acting as a filter to the current playlist<br />
** Dynamic icon to provide visual feedback of selected options <br />
* '''V2.8''' [2011-05-11]<br />
** Invalidated Shift and Alt key in autoplaylist clients<br />
** Fixed bug :Alt+Enter, Alt+Shift+Enter not working (since V2.3)<br />
* '''V2.7''' [2011-05-10]<br />
** Fixed behavior during copy/paste operations by core uie mgt.<br />
** Implemented autoplaylist client (to easily edit previously generated autoplaylist)<br />
** Various bugs fixed and code reorganized<br />
** Implemented Quicksearch as a referenced media library viewer (Prefs pages->Media Library)<br />
** Automatic refresh when in Autosearch mode when search criterias (e.g. Search in ..., Tags ..., Match ...) are changed<br />
* '''V2.6''' [2011-05-05]<br />
** Integrated Quicksearch in media library preferences page<br />
** Implemented "bump" on activation request (From media library preferences page OR "Quicksearch" playlist lock OR menu command: activate toolbar)<br />
* '''V2.5''' [2011-04-29]<br />
** Removed default selection of first item after a search<br />
* '''V2.4''' [2011-04-16]<br />
** Compiled with the latest SDK [2011-03-11] & VS2010<br />
** Fixed Alt+F4 Key behavior<br />
* '''V2.3''' [2010-10-19]<br />
** Fixed Alt Key behavior<br />
* '''V2.2''' [2010-10-07]<br />
** Reworked context menu management<br />
** Branch to toolbar instead of preferences when invoking show_ui() from playlist lock in playlist managers<br />
** Fixed GDI leak<br />
* '''V2.1''' [2010-09-26]<br />
** Reworked the removal of leading/trailing blanks in "search for same ..." query string when parenthesis removal is active (suspected crash)<br />
* '''V2.0''' [2010-09-02]<br />
** Eliminated leading/trailing blanks in "search for same ..." pattern when parenthesis removal is active<br />
** Updated to latest SDK version [2010-05-21]<br />
* '''V1.9''' [2010-05-14]<br />
** Eliminated flickering<br />
* '''V1.8'''<br />
** Augmented max history and favorites size<br />
** Fixed background color of preferences page<br />
* '''V1.7'''<br />
** ''V1.7.1 Quickfix'' : Removed setting the search results playlist as the playing playlist<br />
** Invalidated "Tags ..." in toolbar Menu when "Extended" is selected<br />
** Fixed small glitch in preferences display<br />
** Fixed ''DURING LAST'' queries not working properly<br />
* '''V1.6'''<br />
** Fixed improper management of favorites<br />
* '''V1.5'''<br />
** Various minor bugfix in toolbar menus and playlist generation<br />
** Revisited keyboard shortcut recalls to generate new playlist (instead of simply recalling the last search) and added autoplaylist option<br />
* '''V1.4'''<br />
** New keyboard shortcut to recall last search<br />
** Separate field for target "new" playlist name (Preferences)<br />
** Various labels changed in toolbar menu<br />
** Permanent alignment of playlist name with preferences<br />
** (Internal) re engineering of the playlist lock management (now in Init section)<br />
* '''V1.3'''<br />
** Results Playlist can be removed<br />
** Implemented max favorites size (32)<br />
* '''V1.2'''<br />
** Implemented a new keyboard shortcut to focus on the toolbar<br />
** Implemented a minmax size option for CUI<br />
* '''V1.1'''<br />
** CUI: Now available as a toolbar, not only a panel<br />
** Renamed menu entries to "Quicksearch ..."<br />
** Fixed (tbc) context menu option label glitch<br />
** Invalidated "Set focus to search results" when Autosearch is active<br />
** Updated help page address<br />
* '''V1.0'''<br />
** Initial version<br />
<br />
=To do=<br />
* Implement history dropdown<br />
* Feed the shared selection instead of target playlist (maybe)<br />
* Check "Set focus to search results" (improve focus mgt to focus on playlist manager, through service_enum ??)<br />
* Add an option to play the results after a search<br />
* Think about multi valued fields</div>NEMO7538