[wp-trac] [WordPress Trac] #23161: Filters for the image crop position

WordPress Trac noreply at wordpress.org
Wed Jan 9 20:45:08 UTC 2013


#23161: Filters for the image crop position
-----------------------------+-----------------------------
 Reporter:  sergej.mueller   |       Type:  feature request
   Status:  new              |   Priority:  normal
Milestone:  Awaiting Review  |  Component:  Media
  Version:  trunk            |   Severity:  normal
 Keywords:  has-patch        |
-----------------------------+-----------------------------
 For a adjustable assignment of the crop start position.

 Usage to make all crops start at (0,0):


 {{{
 add_action(
         'init',
         'set_image_crop_starts'
 );
 function set_image_crop_starts() {
         add_filter(
                 'image_resize_dimensions_crop_start_x',
                 function() {
                         return 0;
                 }
         );
         add_filter(
                 'image_resize_dimensions_crop_start_y',
                 function() {
                         return 0;
                 }
         );
 }
 }}}

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/23161>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list