c# - Crop stroked region as Bitmap from InkCanvas Container -
i started working in wpf application. here, need signature user. using inkcanvas
control implement feature.
i curious on knowing there way in inkcanvas control crop stroked region alone outer margin. don't want empty space of inkcanvas container in output bitmap image. if signature in small, want crop region , stretch particular size(300x200).
ok, first need determine rectangle crop (the "stroked region"), save image.
inkcanvas has strokes
property collection of ink strokes, can bounds of each stroke calling stroke.getbound method. can left property of "stroked region", left property of leftmost bounds. , right, top , bottom in same way. hope can understand explanation.
resizing cropped image 300x200 should quite easy, can find plenty of answers on stackoverflow.
Comments
Post a Comment