Beispiel #1
0
        public override void AppendPath(object backend, object otherBackend)
        {
            Cairo.Context dest = ((CairoContextBackend)backend).Context;
            Cairo.Context src  = ((CairoContextBackend)otherBackend).Context;

            using (var path = src.CopyPath())
                dest.AppendPath(path);
        }
        public void Dispose()
        {
            if (this.Path == null)
            {
                Path   = _context.CopyPath();
                Bounds = _context.FillExtents().ToAvalonia();
            }

            _context.Dispose();
            _surf.Dispose();
        }
Beispiel #3
0
        public void EndFigure(bool isClosed)
        {
            if (isClosed)
            {
                _context.ClosePath();
            }

            var extents = _context.StrokeExtents();

            _impl.Bounds = new Rect(extents.X, extents.Y, extents.Width, extents.Height);
            _impl.Path   = _context.CopyPath();
        }
Beispiel #4
0
        public void EndFigure(bool isClosed)
        {
            if (this.Path == null)
            {
                if (isClosed)
                {
                    _context.ClosePath();
                }

                Path   = _context.CopyPath();
                Bounds = _context.FillExtents().ToPerspex();
            }
        }