[wp-trac] [WordPress Trac] #20036: A custom post type icon?

WordPress Trac wp-trac at lists.automattic.com
Tue Feb 14 10:58:57 UTC 2012


#20036: A custom post type icon?
--------------------------------------------+------------------------------
 Reporter:  empireoflight                   |       Owner:
     Type:  enhancement                     |      Status:  new
 Priority:  normal                          |   Milestone:  Awaiting Review
Component:  General                         |     Version:
 Severity:  normal                          |  Resolution:
 Keywords:  has-patch 2nd-opinion needs-ui  |
--------------------------------------------+------------------------------
Changes (by DrewAPicture):

 * keywords:   => has-patch 2nd-opinion needs-ui


Comment:

 I'd say the obvious question would be what to change the icon to. I agree
 that it would be nice to have something to set CPTs apart from Posts,
 especially if no `menu_icon` is specified.

 As for a patch, the switch was much simpler than I originally thought. In
 [http://core.trac.wordpress.org/browser/trunk/wp-admin/menu.php#L97 wp-
 admin/menu.php#L97] there's already a _builtin = false check as well as an
 is_string check on $ptype_obj->menu_icon.

 The attached diff introduces the `menu-icon-custom` class. All that would
 be left to do would to add the icon(s) to the end of the menu sprites (wp-
 admin/images/menu.png and menu-vs.png).

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/20036#comment:3>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list