Ceiling() public static method

public static Ceiling ( SKRect value ) : SKRectI
value SKRect
return SKRectI
Beispiel #1
0
        public bool SetPath(SKPath path)
        {
            if (path == null)
            {
                throw new ArgumentNullException(nameof(path));
            }

            using var clip = new SKRegion();
            var rect = SKRectI.Ceiling(path.Bounds);

            if (!rect.IsEmpty)
                clip.SetRect(rect); }
Beispiel #2
0
        public bool SetPath(SKPath path)
        {
            if (path == null)
            {
                throw new ArgumentNullException(nameof(path));
            }

            using (var clip = new SKRegion()) {
                var rect = SKRectI.Ceiling(path.Bounds);
                if (!rect.IsEmpty)
                {
                    clip.SetRect(rect);
                }

                return(SkiaApi.sk_region_set_path(Handle, path.Handle, clip.Handle));
            }
        }
Beispiel #3
0
 public SKRegion(SKPath path)
     : this(SKRectI.Ceiling(path.Bounds))
 {
     SetPath(path);
 }