Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draw pointer above CustomCurve #250

Closed
higaski opened this issue Sep 22, 2023 · 1 comment · Fixed by #251
Closed

Draw pointer above CustomCurve #250

higaski opened this issue Sep 22, 2023 · 1 comment · Fixed by #251
Assignees
Labels
bug Something isn't working good first issue Good for newcomers has reproducible steps

Comments

@higaski
Copy link

higaski commented Sep 22, 2023

Hey

I think it would be great if users could specify whether a LinearGauge's CustomCurve should mask a Pointer or the other way round.

Take the following snippet for example which draws a CustomCurve to the left of a LinearGauge:

    return LinearGauge(
      end: 126,
      gaugeOrientation: GaugeOrientation.vertical,
      rulers: RulerStyle(
        rulerPosition: RulerPosition.right,
      ),
      pointers: [
        Pointer(
          value: 0,
          height: 20,
          color: Theme.of(context).dividerColor,
          width: 20,
          shape: PointerShape.triangle,
          isInteractive: true,
          onChanged: null,
          pointerPosition: PointerPosition.left,
        ),
      ],
      curves: const [
        CustomCurve(
          startHeight: 4,
          endHeight: 50,
          midHeight: 5,
          curvePosition: CurvePosition.left,
          end: 126,
          midPoint: 50 * 0.8,
        ),
      ],
    );

This slider looks great as long as the Pointer remains at 0, but once it gets moved it gets drawn beneath the CustomCurve:
pointers

Thanks for the package so far, its really powerful and allows creating nice looking sliders and gauges with ease. 😄

@hasnentai
Copy link
Contributor

Hi @higaski Thanks for creating this issue.
@Afroz-Shaikh will take this up and resolve it soon

@hasnentai hasnentai added bug Something isn't working good first issue Good for newcomers has reproducible steps labels Sep 22, 2023
@Afroz-Shaikh Afroz-Shaikh linked a pull request Sep 29, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers has reproducible steps
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants