Ticket #9184 (closed task (blessed): fixed)

Opened 3 years ago

Last modified 3 years ago

Add documentation lookup shortcuts to Theme and Plugin Editors

Reported by: beaulebens Owned by:
Priority: normal Milestone: 2.8
Component: UI Version: 2.7
Severity: normal Keywords: has-patch needs-testing blessed
Cc:

Description

This patch adds a SELECT box underneath the main editing window for the Theme and Plugin Editors that lists functions used in the current file (PHP files only). If you select a function from the list and click the "Lookup" button, it launches a new window that uses the new documentation API to load the appropriate page for that function.

Includes: Native PHP functions, All user-space functions used in the current file (except those specifically excluded)

Excludes: any classes/functions defined in the current file (since it assumes they are plugin/theme-specific and therefore won't have documentation available via the docs API),

Allows users to filter the list of function names to "ignore" via the new 'documentation_ignore_functions' filter.

The way tokenizer works is a bit funky, so please keep an eye out for things being included in the list that shouldn't be there and let me know so I can clean them up. Could use some testing by loading various plugin/theme files.

Attachments

9184.diff Download (5.8 KB) - added by beaulebens 3 years ago.
Made the for() loop more efficient. Props jacobsantos

Change History

Made the for() loop more efficient. Props jacobsantos

comment:1   matt3 years ago

  • Keywords blessed added

comment:2   ryan3 years ago

  • Status changed from new to closed
  • Resolution set to fixed

(In [10607]) Add documentation lookup shortcuts to Theme and Plugin Editors. Props beaulebens. fixes #9184

Note: See TracTickets for help on using tickets.