{"id":13835057,"url":"https://github.com/CogentRedTester/mpv-search-page","last_synced_at":"2025-07-10T07:31:15.378Z","repository":{"id":52108636,"uuid":"267990275","full_name":"CogentRedTester/mpv-search-page","owner":"CogentRedTester","description":"An in-window search page for mpv player","archived":false,"fork":false,"pushed_at":"2023-01-16T11:00:13.000Z","size":26900,"stargazers_count":54,"open_issues_count":5,"forks_count":7,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-04-03T20:11:15.219Z","etag":null,"topics":["keybinds-page","mpv","mpv-player","mpv-script","options-page","search-interface"],"latest_commit_sha":null,"homepage":"","language":"Lua","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CogentRedTester.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-05-30T01:50:24.000Z","updated_at":"2025-02-04T00:26:03.000Z","dependencies_parsed_at":"2023-02-10T02:46:27.548Z","dependency_job_id":null,"html_url":"https://github.com/CogentRedTester/mpv-search-page","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/CogentRedTester/mpv-search-page","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CogentRedTester%2Fmpv-search-page","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CogentRedTester%2Fmpv-search-page/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CogentRedTester%2Fmpv-search-page/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CogentRedTester%2Fmpv-search-page/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CogentRedTester","download_url":"https://codeload.github.com/CogentRedTester/mpv-search-page/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CogentRedTester%2Fmpv-search-page/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264545160,"owners_count":23625404,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["keybinds-page","mpv","mpv-player","mpv-script","options-page","search-interface"],"created_at":"2024-08-04T14:00:55.769Z","updated_at":"2025-07-10T07:31:10.370Z","avatar_url":"https://github.com/CogentRedTester.png","language":"Lua","funding_links":[],"categories":["Menu"],"sub_categories":[],"readme":"# mpv-search-page\n\n![image](screenshots/front.png)\n\nThis script allows you to search for keybinds, properties, options and commands and have matching entries display on the OSD.\nThe search is case insensitive by default, and the script sends the filter directly to a lua string match function, so you can use patterns to get more complex filtering. For options and limitations see the [Queries](#queries) and [Flags](#flags) sections.\n\nThis script requires [mpv-scroll-list](https://github.com/CogentRedTester/mpv-scroll-list) and [mpv-user-input](https://github.com/CogentRedTester/mpv-user-input) to work.\nSimply place `scroll-list.lua` and `user-input-module.lua` into the `~~/script-modules` folder, and `user-input.lua` into the `~~/scripts` folder.\n\n## Pages\n\nThe search pages will remain open until the esc key is pressed. When the page is open the up and down arrow can be used to scroll through the results, and the left and right arrows can be used to pan horizontally to see any cut off values.\n\nThere are 4 main search pages, each page has its own independant state, and while open one can cycle between them in the below order:\n\n### Keybinds\n\n![keybinds_page](screenshots/keybinds_page.png)\n\nThe keybind page is for searching keybindings. By default the script searches the name of the key; the command the key runs; the input section the key is part of; the owner of the key (typically the script that creates it); and any comments on the same line as the key in input.conf.\n\nThe search page shows the key name in lavendar on the left, then the command in cyan, and finally the comment in green, preceeded by a `#`. In addition, if the keybinding is part of a section other than the default, the section will be printed in yellow brackets between the key name and the command.\n\nKeybinds which are disabled or overridden will be shown at 50% opacity.\n\nPressing ENTER on an entry will run the command for that entry.\n\n### Commands\n\n![commands_page](screenshots/command_page.png)\n\nThe command page displays input commands that can be used in input.conf or the console, as well as their arguments. The script only searches the name of the commands.\n\nThe search page shows all of the command names in lavendar on the left. The following words are arguments that the command takes, green arguments are compulsory, while cyan are optional. Each argument contains its type in small yellow brackets. Note that the type, and colour-coding is taken straight from the lua API, so it may not always be correct.\n\nPressing ENTER on an entry will load the command into console.lua, and print the arguments and their types to the console for reference.\n\n### Options\n\n![option_page](screenshots/option_page.png)\n\nThe options page is for searching options that can be set on the commandline or through mpv.conf. Most of these options have matching properties. The script searches the option name, as well as any choices that are available.\n\nThe option page contains the option name in lavendar, directly followed by the option type in yellow. The cyan entry is the current value of the option, if available, and the yellow is the default option value. The green value shows different information depending on the option type; if the option is a float, integer, double, aspect, or bytesize, then the valid option range is displayed; if the option is a choice, then the valid choices are listed.\n\n### Properties\n\n![property_page](screenshots/property_page.png)\n\nThe properties page shows all of the properties, and their current values, for the current file. Only the property name is included in the search. Note that the property list contains most options as well.\n\nThe search page simply contains the property name on the left, followed by it's current value (if it has one).\n\n## Default Keybinds\n\nThe default keybinds are listed below, these can be overwritten using input.conf:\n\n    f12         script-binding open-search-page\n    Shift+f12   script-binding open-search-page/advanced\n                script-message open-page [page]\n                script-message open-page/advanced [page]\n\nThe default `f12` bindings open the last open page. The advanced commands open a second input to add search flags.\nThe script messages allow you to specify which page to open, valid values are `keybinds`, `commands`, `options`, and `properties`.\n\n### Dynamic Keybinds\n\nIn addition the following keybinds are dynamically created when the search page is open, these cannot currently be changed:\n\n    f12             opens search input\n    Shift+f12       opens advanced search input\n    esc             closes the search page\n    down            scrolls the page down\n    up              scrolls the page up\n    left            pans the whole search page left\n    right           pans the whole search page right\n    Shift+left      open prev page\n    Shift+right     open next page\n    Ctrl+left       open prev page and run latest search\n    Ctrl+right      open next page and run latest search\n    Ctrl+enter      re-run latest search on current page\n    enter           perform action (see pages for details)\n\n## Queries\n\n![query_example](screenshots/search_input.png)\n\nSearch Queries are done through `mpv-user-input`. A search input will be opened automatically the first time a specific page is opened, and can be opened again at any time using one of the `f12` keybinds.\n\nAdvanced searches will open a second input after the main search query where you can enter a series of search [flags](#flags).\n\nSending a query with an empty string (pressing ENTER with nothing in the input) will show all results for the selected category.\n\n## Flags\n\nBy default the script will convert both the search query, and all the strings it scans into lower case to maximise the number of results, as well as escaping special pattern characters. It returns any result that contains the full query somewhere in its values. Flags can be used to modify this behaviour. Flags are values you can enter into the advanced search input, currently there are 3:\n\n    wrap        search for a whole word only (may not work with some symbols)\n    pattern     don't convert the query to lowercase and don't escape pattern characters\n    exact       don't convert anything into lowercase\n\nMultiple flags can be used at once by separating them with spaces.\n\n## Lua Patterns\n\nThis script sends queries into the Lua string find function, the find function supports something called [patterns](http://lua-users.org/wiki/PatternsTutorial) to help make more complex searches. In order to facilitate this there are a number of symbols (`^$()%.[]*+-?`), which are reserved for pattern creation.\nBy default the script will escape these special characters to make searches more convenient, however this can be disabled with the `pattern` [flag](#flags).\n\n## Configuration\n\nThe full list of options, and their defaults are shown in [search_page.conf](search_page.conf).\n\n## Future Plans\n\nSome ideas for future functionality:\n\n* ~~Implement scrolling~~\n* Json options file to configure jumplist behaviour/commands\n  * ~~Add jumplists for properties and options~~\n  * Add multiple commands for each item using Ctrl,Alt, etc\n  * ~~Implement a cursor to select items for commands (same as jumplist)~~\n* Search multiple queries at once (may already be possible with lua patterns)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FCogentRedTester%2Fmpv-search-page","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FCogentRedTester%2Fmpv-search-page","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FCogentRedTester%2Fmpv-search-page/lists"}