Skip to content
GitLab
  • Menu
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
    • Switch to GitLab Next
  • Sign in / Register
  • Lazarus Lazarus
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 2,108
    • Issues 2,108
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
  • Merge requests 9
    • Merge requests 9
  • Deployments
    • Deployments
    • Releases
  • Analytics
    • Analytics
    • Value stream
    • Code review
    • Insights
    • Issue
    • Repository
  • External wiki
    • External wiki
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • FPC
  • LazarusLazarus
  • LazarusLazarus
  • Issues
  • #39616
Closed
Open
Issue created Jan 30, 2022 by Frank Freeman@Free_CoderContributor

TBoxAndWhiskerSeries cannot use different color on each point for box border, whiskers and median

  • Lazarus/FPC Version: 2.2.0RC1 r65419 FPC 3.2.2 x86_64-win64-win32/win64
  • Operating System: Windows 7
  • CPU / Bitness: 64

What happens

Each point has the same color for box border, whiskers and median.

What did you expect

Each point can optionally use Source[i]^.Color for BoxPen, WhiskerPen and MedianPen. This is related to #39615 (closed) because if a box is so thin that its BoxBrush.Color is not visible, then BoxPen.Color needs to be (optionally) set to Source[i]^.Color.

Steps to reproduce

Create a TBoxAndWhiskerSeries and fill it with so many points (e.g. 1000) that some (all) boxes become so thin that BoxBrush.Color becomes invisible. If BoxPen.Style <> psClear, then BoxPen.Color is visible but is equal for all points which is not desired. Solution: if (Source[i]^.Color <> clTAColor) and (BoxPen.Color = clTAColor) then set BoxPen.Color to Source[i]^.Color. Do analog for WhiskerPen and MedianPen.

The detailed view of the original shows BoxBrush.Color using Source[i]^.Color and the BoxPen.Color.

original__with_Source.Color_set_and_BoxPen.Color___clDefault__zoom_level_2_

When zooming out, the boxes become so thin that BoxBrush.Color becomes invisible and only BoxPen.Color is visible.

original__with_Source.Color_set_and_BoxPen.Color___clDefault__zoom_level_1_

The fixed version uses BoxPen.Color clDefault which causes it to use Source[i]^.Color (also for BoxBrush.Color).

39615+_39616_applied__with_Source.Color_set_and_BoxPen.Color___clDefault__zoom_level_1

Edited Jan 30, 2022 by Frank Freeman
Assignee
Assign to
Time tracking