Opened 12 years ago

Closed 7 years ago

#4356 closed defect (wontfix)

dojo.style: return values

Reported by: guest Owned by: guest
Priority: low Milestone: future
Component: HTML Version: 0.9
Keywords: Cc:
Blocked By: Blocking:

Description (last modified by sjmiles)

If top/left is "auto", dojo.style returns 0. Same with lineHeight when "normal".

Not sure whether this is a good idea.

If no border attributes were set, dojo.style returns "". Maybe 0 was better in this case?

Change History (6)

comment:1 Changed 11 years ago by dylan

Milestone: 1.2

comment:2 Changed 11 years ago by sjmiles

Description: modified (diff)
Milestone: 1.2future

I'm not sure how to balance raw-values vs. heurisitics vs. complicated calculations in dojo.style. Personally, I've advocated more explicit functions so we aren't in the business of trying to solve the general case problem.

I am going to defer this ticket until there is some consensus towards a particular solution.

comment:3 Changed 7 years ago by ben hockey

Owner: changed from sjmiles to guest
Status: newpending

this seems to no longer be relevant. dojo.style is returning "auto" and "normal" for the cases mentioned in the description.

do we need to keep this ticket open?

if there's no response within 14 days the ticket will automatically close.

comment:4 Changed 7 years ago by trac-o-bot

Resolution: invalid
Status: pendingclosed

Because we get so many tickets, we often need to return them to the initial reporter for more information. If that person does not reply within 14 days, the ticket will automatically be closed, and that has happened in this case. If you still are interested in pursuing this issue, feel free to add a comment with the requested information and we will be happy to reopen the ticket if it is still valid. Thanks!

comment:5 in reply to:  3 Changed 7 years ago by bill

Resolution: invalid
Status: closedreopened

Replying to neonstalwart:

If top/left is "auto", dojo.style returns 0.

this seems to no longer be relevant. dojo.style is returning "auto" and "normal" for the cases mentioned in the description.

I tested and it's still returning 0 for me:

>>> dojo.style(dojo.query(".heading")[0], "left")
0
>>> dojo.style(dojo.query(".heading")[0], "lineheight")
0

This is on FF11/mac running against dojox/grid/tests/test_data_grid.html. Which test did you run?

Anyway, maybe we should close as "wontfix" but "invalid" doesn't seem fair.

comment:6 Changed 7 years ago by ben hockey

Priority: highlow
Resolution: wontfix
Status: reopenedclosed

"invalid" is just what trac-o-bot uses to close tickets - i didn't set it.

however, i can't seem to find a way to reproduce my results where i was seeing "auto" and "normal" (maybe i never saw them?) but i'll close as wontfix since the code explicitly converts these to 0 so i'm assuming it's intentional.

Note: See TracTickets for help on using tickets.