You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
but currently this does not work, since stroke is defined as stroke' def, and stroke' takes a record of options including a fill rule, which it uses to create the proper Query as well as set a FillRule attribute. So (stroke p) results in the FillRule attribute being implicitly set to the default fill rule, and subsequent calls to fillRule do not affect it.
The problem is that if we want the fill rule to affect the Query, it must be done at the time that stroke' is called. I can think of several options:
stroke' uses the provided FillRule to create the Query only, and does not call fillRule to set a FillRule attribute. However, this leads to unintuitive behavior: calling stroke' with a FillRule won't cause it to be drawn using that FillRule, and conversely using (# fillRule blah) won't affect the Query.
make the type of the stroke' record field (Maybe FillRule) and have Nothing be the default. But this is also somewhat unintuitive, since the Query has to be created (using some default) anyway.
another possibility is to make the fill rule an inherent property of the Path type itself. But it would be strange to have this particular attribute singled out; and abstractly, Paths have nothing to do with fill rules. Fill rules don't even make sense for paths in dimensions other than 2 anyway.
Other suggestions welcome...
The text was updated successfully, but these errors were encountered:
(Imported. Original comment by byor...@gmail.com on March 12, 2012, 03:02:45 AM UTC)
Closing this, since it doesn't correspond to a concrete action that needs to be taken. If we ever want to revisit this we can reopen it, or open a new ticket and link back to this one.
(Imported from http://code.google.com/p/diagrams/issues/detail?id=52. Original issue from byor...@gmail.com on September 8, 2011, 12:37:25 AM UTC)
One might expect to be able to say something like
stroke p # fillRule EvenOdd
but currently this does not work, since stroke is defined as stroke' def, and stroke' takes a record of options including a fill rule, which it uses to create the proper Query as well as set a FillRule attribute. So (stroke p) results in the FillRule attribute being implicitly set to the default fill rule, and subsequent calls to fillRule do not affect it.
The problem is that if we want the fill rule to affect the Query, it must be done at the time that stroke' is called. I can think of several options:
Other suggestions welcome...
The text was updated successfully, but these errors were encountered: