Skip to main content

Bug Tracker

Side navigation

#10877 closed feature (fixed)

Opened November 23, 2011 06:51PM UTC

Closed May 21, 2012 05:46PM UTC

Last modified March 30, 2014 10:19AM UTC

Make outerWidth/Height a setter

Reported by: jzaefferer Owned by: mikesherov
Priority: low Milestone: 1.8
Component: dimensions Version: 1.7.1
Keywords: Cc: scottgonzalez
Blocked by: Blocking:
Description

The math required by the regular boxmodel leaves it traces in a lot of places where we need to set the width or height of an element that has border, padding or margin.

jQuery UI currently extends inner/outer/Width/Height as setters, but we only use the outerXxx methods: https://github.com/jquery/jquery-ui/blob/master/ui/jquery.ui.core.js#L132-L174

By actually integrating that in core, the require code would obviously be a lot less. For consistency it might make sense to make both outerXxx and innerXxx a setter, but really only outer is important.

Attachments (0)
Change History (20)

Changed November 23, 2011 06:52PM UTC by scottgonzalez comment:1

cc: → scott.gonzalez

Changed November 23, 2011 07:08PM UTC by timmywil comment:2

component: unfileddimensions
keywords: → 1.8-discuss
status: newopen
type: enhancementfeature
version: git1.7.1

Changed December 10, 2011 02:11PM UTC by dmethvin comment:3

#10994 is a duplicate of this ticket.

Changed December 13, 2011 02:45PM UTC by jzaefferer comment:4

description: The math required by the regular boxmodel leaves it traces in a lot of places where we need to set the width or height of an element that has border, padding or margin. \ \ jQuery UI currently extends inner/outer/Width/Height as setters, but we only use the outerXxx methods: https://github.com/jquery/jquery-ui/blob/master/ui/jquery.ui.core.js#L132-L174 \ \ By actually integrating that in core, the require code would obviously be a lot less. For consistency it might make sense to make both outerXxx and innerXxx a setter, but really only outer is important.The math required by the regular boxmodel leaves it traces in a lot of places where we need to set the width or height of an element that has border, padding or margin.\ \ jQuery UI currently extends inner/outer/Width/Height as setters, but we only use the outerXxx methods: https://github.com/jquery/jquery-ui/blob/master/ui/jquery.ui.core.js#L132-L174\ \ By actually integrating that in core, the require code would obviously be a lot less. For consistency it might make sense to make both outerXxx and innerXxx a setter, but really only outer is important.

+1

Changed December 13, 2011 04:24PM UTC by jaubourg comment:5

+0, Not sure here, what the cost in size?

Changed December 13, 2011 05:27PM UTC by dmethvin comment:6

description: The math required by the regular boxmodel leaves it traces in a lot of places where we need to set the width or height of an element that has border, padding or margin.\ \ jQuery UI currently extends inner/outer/Width/Height as setters, but we only use the outerXxx methods: https://github.com/jquery/jquery-ui/blob/master/ui/jquery.ui.core.js#L132-L174\ \ By actually integrating that in core, the require code would obviously be a lot less. For consistency it might make sense to make both outerXxx and innerXxx a setter, but really only outer is important.The math required by the regular boxmodel leaves it traces in a lot of places where we need to set the width or height of an element that has border, padding or margin. \ \ jQuery UI currently extends inner/outer/Width/Height as setters, but we only use the outerXxx methods: https://github.com/jquery/jquery-ui/blob/master/ui/jquery.ui.core.js#L132-L174 \ \ By actually integrating that in core, the require code would obviously be a lot less. For consistency it might make sense to make both outerXxx and innerXxx a setter, but really only outer is important.

+1, Yes, but as with everything in 1.8 contingent on final size. This intersects with our box-sizing: border-box issues as well.

Changed December 14, 2011 01:35PM UTC by mikesherov comment:7

description: The math required by the regular boxmodel leaves it traces in a lot of places where we need to set the width or height of an element that has border, padding or margin. \ \ jQuery UI currently extends inner/outer/Width/Height as setters, but we only use the outerXxx methods: https://github.com/jquery/jquery-ui/blob/master/ui/jquery.ui.core.js#L132-L174 \ \ By actually integrating that in core, the require code would obviously be a lot less. For consistency it might make sense to make both outerXxx and innerXxx a setter, but really only outer is important.The math required by the regular boxmodel leaves it traces in a lot of places where we need to set the width or height of an element that has border, padding or margin.\ \ jQuery UI currently extends inner/outer/Width/Height as setters, but we only use the outerXxx methods: https://github.com/jquery/jquery-ui/blob/master/ui/jquery.ui.core.js#L132-L174\ \ By actually integrating that in core, the require code would obviously be a lot less. For consistency it might make sense to make both outerXxx and innerXxx a setter, but really only outer is important.

+1, This is something people would expect jQuery to handle, and I'd love to work on this, so yes. Also, we can pretty much just rip the code straight from jquery ui. I do have some concerns though with code paths for hidden elements, but should be fun to implement.

Changed December 14, 2011 04:12PM UTC by timmywil comment:8

-1

Changed December 19, 2011 05:35PM UTC by rwaldron comment:9

description: The math required by the regular boxmodel leaves it traces in a lot of places where we need to set the width or height of an element that has border, padding or margin.\ \ jQuery UI currently extends inner/outer/Width/Height as setters, but we only use the outerXxx methods: https://github.com/jquery/jquery-ui/blob/master/ui/jquery.ui.core.js#L132-L174\ \ By actually integrating that in core, the require code would obviously be a lot less. For consistency it might make sense to make both outerXxx and innerXxx a setter, but really only outer is important.The math required by the regular boxmodel leaves it traces in a lot of places where we need to set the width or height of an element that has border, padding or margin. \ \ jQuery UI currently extends inner/outer/Width/Height as setters, but we only use the outerXxx methods: https://github.com/jquery/jquery-ui/blob/master/ui/jquery.ui.core.js#L132-L174 \ \ By actually integrating that in core, the require code would obviously be a lot less. For consistency it might make sense to make both outerXxx and innerXxx a setter, but really only outer is important.

+1

Changed April 04, 2012 01:15AM UTC by mikesherov comment:10

owner: → mikesherov
status: openassigned

Changed April 04, 2012 01:16AM UTC by mikesherov comment:11

keywords: 1.8-discuss
milestone: None1.8
priority: undecidedlow

Changed May 05, 2012 11:07PM UTC by ALLPRO comment:12

+1 -- have wondered why this was not done a long time ago

Changed May 19, 2012 06:52PM UTC by mikesherov comment:13

Changed May 19, 2012 09:05PM UTC by timmywil comment:14

I'm still a -1 on this feauture, especially given the added size to core.

Changed May 19, 2012 10:33PM UTC by mikesherov comment:15

@timmywil, I hear the concern. There are strategies for smaller size that I outlined in the PR. Thoughts?

Changed May 21, 2012 05:46PM UTC by Mike Sherov comment:16

resolution: → fixed
status: assignedclosed

Fix #10877. Make outerWidth/Height a setter. Closes gh-783.

Changeset: e0151e5827d7091f311c82d9f951aaaa2688ba8c

Changed August 10, 2012 10:22PM UTC by mikesherov comment:17

keywords: → needsdocs

Changed October 15, 2012 08:02PM UTC by mikesherov comment:18

keywords: needsdocs

Changed March 29, 2014 11:55PM UTC by jlgrall comment:19

Changed March 30, 2014 10:19AM UTC by jzaefferer comment:20