Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8244979

Imprecise border insets for Regions with Shape

    Details

    • Subcomponent:
    • CPU:
      x86_64
    • OS:
      windows_10

      Description

      ADDITIONAL SYSTEM INFORMATION :
      Microsoft Windows 10 Pro
      Version 10.0.18363 Build 18363


      openjdk version "14.0.1" 2020-04-14
      OpenJDK Runtime Environment AdoptOpenJDK (build 14.0.1+7)
      Eclipse OpenJ9 VM AdoptOpenJDK (build openj9-0.20.0, JRE 14 Windows 10 amd64-64-Bit Compressed References 20200422_50 (JIT enabled, AOT enabled)
      OpenJ9 - 05fa2d361
      OMR - d4365f371
      JCL - 5757187cae based on jdk-14.0.1+7)

      Intel(R) Core(TM) i7-2600K CPU @ 3.40GHz, 3401 MHz, 4 Kern(e), 8 logische(r) Prozessor(en)
      NVIDIA GeForce GT 710


      A DESCRIPTION OF THE PROBLEM :
      Given a Region with any irregular Shape (Polygon) set, and a Border with non-empty Insets, the resulting border strokes "seem wrong".
      The strokes do not seem to always honour the specified insets.

      For context, the goal was to implement multiple borders for any given Shape.
      The attempted solution was to group the Shape in a Group with a Region, that has its inner Shape set to the very same Shape.
      In theory this would mean, that we have a region with the exact same shape and position as the given Shape.
      Any Border applied to the Region would seem to belong to the Shape.

      STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
      Check out the demo at : https://github.com/isp-insoft-gmbh/MultipleBordersDemo

      - Add a border with inset via the "+++ Add stroke +++" button.

      Cycle through different shapes via the combobox in the top right corner.
      Pay special attention to the shapes "TRIA" (Triangle) and "POLY" (Polygon).

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      Borders, that respect the inset for any given shape.
      ACTUAL -
      Borders, that seem unprecise in respect to their inset.

      ---------- BEGIN SOURCE ----------
      https://github.com/isp-insoft-gmbh/MultipleBordersDemo
      ---------- END SOURCE ----------

      CUSTOMER SUBMITTED WORKAROUND :
      None known.

      FREQUENCY : always


        Attachments

          Activity

            People

            • Assignee:
              kcr Kevin Rushforth
              Reporter:
              webbuggrp Webbug Group
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated: