JDK-8160554 : Wrong unit measure in CornerRadiiConverter
  • Type: Bug
  • Component: javafx
  • Sub-Component: controls
  • Affected Version: 8,9
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • OS: windows_8
  • CPU: x86
  • Submitted: 2016-06-28
  • Updated: 2021-03-30
  • Resolved: 2016-08-01
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 8 JDK 9
8u281Fixed 9Fixed
Related Reports
Blocks :  
Description
FULL PRODUCT VERSION :
java version "1.8.0_31"
Java(TM) SE Runtime Environment (build 1.8.0_31-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.31-b07, mixed mode)

ADDITIONAL OS VERSION INFORMATION :
Windows 8.1

A DESCRIPTION OF THE PROBLEM :
The class CornerRadiiConverter is converting wrong values when using css and the measurement unit "em", but only occurs when the font size is different from default. I'm working on a responsive design to college and this is an important part. Thank you for your help. The fix is simple, in the convert method in javafx.scene.layout.CornerRadiiConverter class, you need only pass the font as a parameter for the methods ".pixels ()" in constructor of the converted CornerRadii. Other conversion classes do this, but I believe this has been forgotten.


REPRODUCIBILITY :
This bug can be reproduced always.


Comments
Mail sent to the bug submitter: ============================================================== For our investigation, we will need a simple test case to reproduce the issue. ==============================================================
20-09-2016

Changeset: http://hg.openjdk.java.net/openjfx/9-dev/rt/rev/a81b22e094d9
01-08-2016

Submitter's response: ================================================================== The project is attached. I made some comments about the bug in the file "Bug.css". I am very happy to contribute with the JavaFX and thank you for making it exists. This is wonderful! And to facilitate your work, do not forget that details on how to fix the bug in the description of bug report. ==================================================================
04-07-2016

Marking as incomplete for now, but please reopen once the details are provided. Thanks!
03-07-2016

Are you able to provide a test case and also more clarification around what you see the fix should be? Thanks!
30-06-2016

Checked this issue for JDK 8,9 And could confirm the issue as reported by the submitter. Result: ********* JDK 8 : Issue found JDK 9 : Issue found
29-06-2016