#9025 closed defect (fixed)
gfx splitFontString does not handle valid values for font-size
Reported by: | masnare | Owned by: | Eugene Lazutkin |
---|---|---|---|
Priority: | high | Milestone: | 1.8 |
Component: | DojoX GFX | Version: | 1.1.1 |
Keywords: | gfx splitFontString font | Cc: | |
Blocked By: | Blocking: |
Description
Given a valid css font-size that is not a number, the gfx splitFontString function will return NaN for the size.
Change History (5)
comment:1 Changed 12 years ago by
Component: | General → DojoX GFX |
---|---|
Owner: | changed from anonymous to Eugene Lazutkin |
comment:2 Changed 12 years ago by
Milestone: | tbd → future |
---|---|
Status: | new → assigned |
comment:3 Changed 9 years ago by
Milestone: | future → 1.8 |
---|---|
Resolution: | → fixed |
Status: | assigned → closed |
The problem can be reproduced with the vml or silverlight renderer by *setting* the font returned by splitFontString when the font string contains a non-numeric length (ex: 'small'). In fact, the issue is not in the splitFontString function itself (it parses correctly the font parameters) but happens when such a font is set using the vml or silverlight renderer.
The problem comes from a gfx spec. error: the Font.size property should be a numeric CSS length constant with a unit abbreviation. "12px" or "1.2cm". Reference Manual and API doc updated.
Please add a minimalistic test case to see the problem (before the fix) and make sure that the result is right (after the fix).