This commit is contained in:
Laurent Le Goff 2015-04-17 17:03:50 +02:00
parent 5990ba619c
commit 8b0d5d5048
2 changed files with 0 additions and 55 deletions

View file

@ -1,41 +0,0 @@
package main
import "github.com/llgcode/draw2d/draw2d/curve"
import "testing"
import __os__ "os"
import __regexp__ "regexp"
var tests = []testing.InternalTest{
{"curve.TestCubicCurveRec", curve.TestCubicCurveRec},
{"curve.TestCubicCurve", curve.TestCubicCurve},
{"curve.TestCubicCurveAdaptiveRec", curve.TestCubicCurveAdaptiveRec},
{"curve.TestCubicCurveAdaptive", curve.TestCubicCurveAdaptive},
{"curve.TestCubicCurveParabolic", curve.TestCubicCurveParabolic},
{"curve.TestQuadCurve", curve.TestQuadCurve},
}
var benchmarks = []testing.InternalBenchmark{{"curve.BenchmarkCubicCurveRec", curve.BenchmarkCubicCurveRec},
{"curve.BenchmarkCubicCurve", curve.BenchmarkCubicCurve},
{"curve.BenchmarkCubicCurveAdaptiveRec", curve.BenchmarkCubicCurveAdaptiveRec},
{"curve.BenchmarkCubicCurveAdaptive", curve.BenchmarkCubicCurveAdaptive},
{"curve.BenchmarkCubicCurveParabolic", curve.BenchmarkCubicCurveParabolic},
{"curve.BenchmarkQuadCurve", curve.BenchmarkQuadCurve},
}
var matchPat string
var matchRe *__regexp__.Regexp
func matchString(pat, str string) (result bool, err __os__.Error) {
if matchRe == nil || matchPat != pat {
matchPat = pat
matchRe, err = __regexp__.Compile(matchPat)
if err != nil {
return
}
}
return matchRe.MatchString(str), nil
}
func main() {
testing.Main(matchString, tests, benchmarks)
}

View file

@ -214,20 +214,6 @@ func (gc *GraphicContext) Fill(paths ...*draw2d.PathStorage) {
gc.Current.Path.Clear()
}
/*
func (gc *GraphicContext) Fill(paths ...*draw2d.PathStorage) {
paths = append(paths, gc.Current.Path)
gc.fillRasterizer.UseNonZeroWinding = gc.Current.FillRule.UseNonZeroWinding()
pathConverter := draw2d.NewPathAdder(draw2d.NewMatrixTransformAdder(gc.Current.Tr, gc.fillRasterizer))
pathConverter.ApproximationScale = gc.Current.Tr.GetScale()
pathConverter.Convert(paths...)
gc.paint(gc.fillRasterizer, gc.Current.FillColor)
gc.Current.Path.Clear()
}
*/
func (gc *GraphicContext) FillStroke(paths ...*draw2d.PathStorage) {
gc.fillRasterizer.UseNonZeroWinding = gc.Current.FillRule.UseNonZeroWinding()
gc.strokeRasterizer.UseNonZeroWinding = true