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

Creating a large cursor can lead to "invalid hotspot" exception on Windows

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P4 P4
    • None
    • 1.2.2
    • client-libs
    • Fix Understood
    • generic
    • windows_xp

      The test case attached to bug 6564923 includes a test case that attempts to
      create a large cross-hair cursor. The code gets an "invalid hotspot" exception
      even though the hotspot is defined to be at the center of the supplied image.

      Examining the code in CustomCursor it appears that if the image is too large
      then it is scaled to fit the platform's desired cursor size. Unfortunately,
      the hotspot location is not modified when this happens so that a hotspot that
      was formerly inside the source image may now be outside the scaled version of
      the image.

      If the cursor image needs to be scaled then the hotspot location should be
      scaled accordingly to match the same relative location in the image.

            volk Konstantin Voloshin (Inactive)
            flar Jim Graham
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Imported:
              Indexed: