/// <summary> /// Prepares a <see cref="Graphics"/> object for drawing a specified <see cref="LcdGdiObject"/>, /// by setting the appropriate properties (clip, interpolation, etc) on the <see cref="Graphics"/>. /// </summary> /// <param name="graphics"><see cref="Graphics"/> to prepare for drawing <paramref name="child"/>.</param> /// <param name="child"><see cref="LcdGdiObject"/> that will be drawn on <paramref name="graphics"/>.</param> internal protected static void PrepareGraphicsForChild(Graphics graphics, LcdGdiObject child) { if (graphics == null) { throw new ArgumentNullException("graphics"); } if (child == null) { throw new ArgumentNullException("child"); } graphics.Transform = child.Transform; if (child.Clip != null) { graphics.Clip = child.Clip; } graphics.InterpolationMode = child.InterpolationMode; graphics.PixelOffsetMode = child.PixelOffsetMode; graphics.RenderingOrigin = child.RenderingOrigin; graphics.SmoothingMode = child.SmoothingMode; }
/// <summary> /// Creates a new <see cref="LcdGdiScrollViewer"/> with the specified child. /// </summary> /// <param name="child">Child to add into the scroll viewer.</param> public LcdGdiScrollViewer(LcdGdiObject child) { _child = child; }