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

Triangle filling is not working #92

Open
kingelilol opened this issue Feb 28, 2022 · 3 comments
Open

Triangle filling is not working #92

kingelilol opened this issue Feb 28, 2022 · 3 comments

Comments

@kingelilol
Copy link

Hi,

I've tried to fill a triangle, but it does not work.

This is my testcase:

+---+ +-----+ + +---------+ +
|{r}|  \{r}/ / \ \       / / \
+---+   \ / /{r}\ \ {r} / /   \
         + +-----+ \   / / {r} \
+-----+             \ / /       \
|     |              + +---------+
| {r} |
|     |
+-----+

# Legend:
r = {
    fill: red;
}

test

@ivanceras
Copy link
Owner

This is not yet supported, tagged shapes with css is only applied to rectangles and circles for now.

@hfiguiere
Copy link

I guess that the same issue with

 +-----+------+
 |G {g}| B {b}|
 +-----+------+
 | {r} | {g}  |
 +-----+------+

 +---+
 |{g}|
 +---+

# Legend:
r = {
    stroke: red;
    fill: red;
}
g = {
    fill: green;
}
b = {
    fill: blue;
}

Which gives
image

@ivanceras
Copy link
Owner

The tagging is limited only to a detached limited shape primitives such as circle and rect. If it is touching or very close or inside another shape, the algorithm breaks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants