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

[Feature Request] XAML Linear Gradient without Offset #51

Closed
bbenetskyy opened this issue Nov 20, 2019 · 0 comments · Fixed by #52
Closed

[Feature Request] XAML Linear Gradient without Offset #51

bbenetskyy opened this issue Nov 20, 2019 · 0 comments · Fixed by #52
Assignees
Labels
good first issue Good for newcomers 🛠️ enhancement New feature or request 📃 documentation Improvements or additions to documentation
Milestone

Comments

@bbenetskyy
Copy link
Collaborator

We should provide support for XAML Linear Gradients without a defined Offset.

It should work the same as it is for CSS Linear Gradients - divide into equal parts between each color

Mean it should work the same as defined equal Offset between each color

Gradient of next code should have same result after implementation this feature:

<magicGradients:GradientView VerticalOptions="FillAndExpand">
    <magicGradients:GradientView.GradientSource>
        <magicGradients:LinearGradient Angle="352" IsRepeating="False">
            <magicGradients:GradientStop Color="#E91C83" Offset="0"/>
            <magicGradients:GradientStop Color="#E9631C" Offset="0.5"/>
            <magicGradients:GradientStop Color="#C0E91C" Offset="1"/>
        </magicGradients:LinearGradient>
    </magicGradients:GradientView.GradientSource>
</magicGradients:GradientView>
<magicGradients:GradientView VerticalOptions="FillAndExpand">
    <magicGradients:GradientView.GradientSource>
        <magicGradients:LinearGradient Angle="352" IsRepeating="False">
            <magicGradients:GradientStop Color="#E91C83" />
            <magicGradients:GradientStop Color="#E9631C" />
            <magicGradients:GradientStop Color="#C0E91C" />
        </magicGradients:LinearGradient>
    </magicGradients:GradientView.GradientSource>
</magicGradients:GradientView>

And looks like:
image

Now it looks like:
image

@bbenetskyy bbenetskyy added 📃 documentation Improvements or additions to documentation 🛠️ enhancement New feature or request good first issue Good for newcomers labels Nov 20, 2019
@bbenetskyy bbenetskyy added this to the vNext milestone Nov 20, 2019
@mgierlasinski mgierlasinski modified the milestones: vNext, v1.0.1 Nov 22, 2019
@mgierlasinski mgierlasinski self-assigned this Nov 22, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers 🛠️ enhancement New feature or request 📃 documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants