'How do I edit CustomTrackShape?

I am designing a custom track shape for a project that looks like this: enter image description here

and I already finished most of the code, I ended up with this result:

enter image description here

aside from the rounded sides (those I'll fix), I need to achieve:

  1. Move the label under
  2. Change the label dimensions if possible
  3. Customize the trackheight to make it smaller on one end and larger on the other.


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source