Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #20052, comment 24


Ignore:
Timestamp:
07/24/2012 02:19:56 PM (11 years ago)
Author:
bradyvercher
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #20052, comment 24

    initial v1  
    11I came up with a concept for attempting to solve this issue awhile back on a smaller scale, but thought it might be useful here. Basically, the current behavior would continue to work, but if a developer passed an array to `menu_icon` (or even `screen_icon`), then CSS would be generated for a sprite. The array would simply contain the url as it's first argument, then a set of coordinate adjustments as the second argument, and if desired, a third argument would be the coordinate adjustments for a hover state. It'd work with a single sprite or individual sprites for each image.
    22
    3 It's similar to some of the concepts mentioned, but might be a little more flexible than a rigid template. My code is [in this plugin](https://github.com/thelukemcdonald/post-format-menus/blob/master/post-format-menus.php) for anyone interested in taking a look and seeing if it'd be of any use.
     3It's similar to some of the concepts mentioned, but might be a little more flexible than a rigid template. My code is [https://github.com/thelukemcdonald/post-format-menus/blob/master/post-format-menus.php in this plugin] for anyone interested in taking a look and seeing if it'd be of any use.